Coconut Framework
beta
|
Define CNStringElement class. More...
Go to the source code of this file.
Classes | |
struct | CNStringElement |
Functions | |
struct CNStringElement * | CNAllocateStringElement (size_t len, const unsigned char *str, struct CNResource *resource) |
Allocate string element. More... | |
struct CNStringElement * | CNCopyStringElement (const struct CNStringElement *src, struct CNResource *resource) |
Allocate a copy of source string element. More... | |
static void | CNRetainStringElement (struct CNStringElement *dst) |
Retain the reference count of string element. More... | |
void | CNReleaseStringElement (struct CNResource *resource, struct CNStringElement *dst) |
Release the reference count of string element. More... | |
unsigned char * | CNContextOfStringElement (const struct CNStringElement *src) |
Get context of the string element. More... | |
static size_t | CNContextLengthOfStringElement (const struct CNStringElement *src) |
Get context length of the string element. More... | |
static size_t | CNMaxContextSizeOfStringElement (const struct CNStringElement *src) |
Get max context size of string elemnet. More... | |
struct CNMemoryProfile | CNProfileOfStringElement (const struct CNStringElement *src) |
Get memory profile of string element. More... | |
Define CNStringElement class.
struct CNStringElement* CNAllocateStringElement | ( | size_t | len, |
const unsigned char * | str, | ||
struct CNResource * | resource | ||
) |
Allocate string element.
len | Length of source string |
str | Source string |
resource | Resource to allocate this element |
struct CNStringElement* CNCopyStringElement | ( | const struct CNStringElement * | src, |
struct CNResource * | resource | ||
) |
Allocate a copy of source string element.
src | Source string element |
resource | Resource to allocate the string element |
|
inlinestatic |
Retain the reference count of string element.
dst | Destination string element |
References CNStringElement::referenceCount.
void CNReleaseStringElement | ( | struct CNResource * | resource, |
struct CNStringElement * | dst | ||
) |
Release the reference count of string element.
resource | Resource to release the element |
dst | Destination string element |
unsigned char* CNContextOfStringElement | ( | const struct CNStringElement * | src | ) |
Get context of the string element.
src | Source string element |
|
inlinestatic |
Get context length of the string element.
src | Source string element |
References CNStringElement::currentContextLength.
|
inlinestatic |
Get max context size of string elemnet.
src | Source string element |
References CNStringElement::maxContextSize.
struct CNMemoryProfile CNProfileOfStringElement | ( | const struct CNStringElement * | src | ) |
Get memory profile of string element.
src | Source string element |