48 #define DEFAULT_STRING_LENGTH 8
51 #define ION_STRING_INIT(x) (x)->length = 0; (x)->value = NULL
52 #define ION_STRING_ASSIGN(dst, src) (dst)->length = (src)->length; (dst)->value = (src)->value
53 #define ION_STRING_IS_NULL(x) ((x) == NULL || ((x)->value == NULL))
54 #define ION_STRING_EQUALS(x, y) (((x) == (y)) || (((x)->length == (y)->length) && (memcmp((x)->value, (y)->value, (x)->length) == 0)))
55 #define ION_STRING_CHAR_AT(str, ii) ((ii) < (str)->length ? (str)->value[ii] : -1)
57 ION_API_EXPORT
void ion_string_init (
ION_STRING *str);
60 ION_API_EXPORT
char *ion_string_strdup (
ION_STRING *p_ionstring);
88 ION_API_EXPORT BOOL ion_string_is_null (
ION_STRING *str);
ION_API_EXPORT int ion_string_get_length(ION_STRING *str)
ION_API_EXPORT BYTE ion_string_get_byte(ION_STRING *str, int idx)
ION_API_EXPORT BYTE * ion_string_get_bytes(ION_STRING *str)
Definition: ion_string.h:40
int32_t length
Definition: ion_string.h:42
BYTE * value
Definition: ion_string.h:45