#include "beastapitypes.h"
Beast strings is objects encapsulating strings returned from Beast API functions.
Functions | |
ILBStatus | ILBCopy (ILBStringHandle string, ILBString target, int32 length) |
ILBStatus | ILBGetLength (ILBStringHandle string, int32 *length) |
ILBStatus | ILBReleaseString (ILBStringHandle string) |
ILBStatus ILBCopy | ( | ILBStringHandle | string, |
ILBString | target, | ||
int32 | length | ||
) |
Copies the contained string to a buffer.
The length is defined in the same way as in ILBGetLength
string | the string to copy from |
target | a buffer to copy the string to. |
length | the size of the buffer. Specified as the number of characters (that may be different for different encodings) as opposed to number of bytes. |
ILBStatus ILBGetLength | ( | ILBStringHandle | string, |
int32 * | length | ||
) |
Returns the length of the string in number of characters.
The size of each character is specified by the currently used string encoding. I.E if you get 5 as length and use utf 16 your string should be 10 bytes large. Note the length includes the terminating 0. This method shall never return 0, an empty string is returned as a single termination character
string | the string to query length from |
length | a pointer to an integer receiving the length |
ILBStatus ILBReleaseString | ( | ILBStringHandle | string | ) |
Releases a string object.
Note that strings are not managed through the Beast Manager so it must be released manually or it will be a memory leak.
string | the string to release. |