#include <string_api.h>
|
JUNO_STATUS_T(* | Init )(JUNO_STRING_T *ptString, JUNO_MEMORY_ALLOC_T *ptAlloc, const char *pcStr, size_t zLen, JUNO_FAILURE_HANDLER_T pfcnFailureHandler, JUNO_USER_DATA_T *pvUserData) |
| Creates a JUNO string from a C string.
|
|
JUNO_STATUS_T(* | SetAlloc )(JUNO_STRING_T *ptString, JUNO_MEMORY_ALLOC_T *ptAlloc) |
| Sets a new memory allocator for a JUNO string.
|
|
JUNO_STATUS_T(* | Length )(JUNO_STRING_T *ptString, size_t *pzRetSize) |
| Retrieves the size of the JUNO string.
|
|
JUNO_STATUS_T(* | Concat )(JUNO_STRING_T *ptString1, JUNO_STRING_T *ptString2) |
|
JUNO_STATUS_T(* | Append )(JUNO_STRING_T *ptString, const char *pcCstr, size_t zLen) |
|
JUNO_STATUS_T(* | Free )(JUNO_STRING_T *ptString) |
| Frees resources associated with the JUNO string.
|
|
◆ Append
Writes a C-String to the Juno String
- Parameters
-
ptString | The juno string to write to |
pcCstr | The C string |
zLen | The length of the C string |
- Returns
- JUNO_STATUS_T result status
◆ Concat
Concat two strings together
- Parameters
-
ptString1 | The first string |
ptString2 | The second string |
zNewSize | The size of the new string. If the size is 0, the new size will be inferred |
◆ Free
Frees resources associated with the JUNO string.
- Parameters
-
ptString | Pointer to the JUNO string structure. |
- Returns
- JUNO_STATUS_T result status.
◆ Init
Creates a JUNO string from a C string.
- Parameters
-
ptString | Pointer to the JUNO string structure. |
ptAlloc | Memory allocator. |
pcStr | C-string input. |
zLen | Length of the input string. |
pfcnFailureHandler | Failure handler callback. |
pvUserData | User data pointer. |
- Returns
- JUNO_STATUS_T result status.
◆ Length
Retrieves the size of the JUNO string.
- Parameters
-
ptString | Pointer to the JUNO string structure. |
pzRetSize | Pointer to variable to store the string size. |
- Returns
- JUNO_STATUS_T result status.
◆ SetAlloc
Sets a new memory allocator for a JUNO string.
- Parameters
-
ptString | Pointer to the JUNO string structure. |
ptAlloc | New memory allocator. |
- Returns
- JUNO_STATUS_T result status.
The documentation for this struct was generated from the following file:
- /home/runner/work/libjuno/libjuno/include/juno/string/string_api.h