-
Notifications
You must be signed in to change notification settings - Fork 0
mdz_utf32_attachData
Maksym Dzyubenko edited this page Feb 7, 2024
·
1 revision
Attach pre-allocated data to UTF-32
string, assigning pData
to m_pData
. If attached, m_pData
will not be destroyed in mdz_utf32_destroy()
mdz_bool mdz_utf32_attachData(
struct mdz_Utf32* pUtf32,
uint32_t* pData,
size_t nOffsetFromStart,
size_t nCapacity,
enum mdz_attach_type enAttachType,
enum mdz_endianness enEndianness);
Parameter | Description |
---|---|
pUtf32 |
pointer to string returned by mdz_utf32_create() or mdz_utf32_create_attached()
|
pData |
pointer to pre-allocated data to attach |
nOffsetFromStart |
position in pre-allocated data to attach from. Can be > 0 |
nCapacity |
full capacity pre-allocated data in items |
enAttachType |
type of attachment. 0 is expected at position pData [nOffsetFromStart ] if MDZ_ATTACH_ZEROSIZE . 0 is expected at position pData [nCapacity ] if MDZ_ATTACH_SIZE_TERMINATOR . MDZ_ATTACH_SIZE_NO_TERMINATOR is not allowed |
enEndianness |
endianness of UTF-32 characters in pData . Can be MDZ_ENDIAN_LITTLE for "little-endian" or MDZ_ENDIAN_BIG for "big-endian" |
Return | Description |
---|---|
mdz_false | if pUtf32 == NULL
|
mdz_false | if pData == NULL (MDZ_ERROR_DATA), or nOffsetFromStart >= nCapacity (MDZ_ERROR_OFFSET), or invalid enAttachType (MDZ_ERROR_ATTACHTYPE), or invalid pData endianness (MDZ_ERROR_ENDIANNESS) |
mdz_false | if enAttachType is MDZ_ATTACH_ZEROSIZE or MDZ_ATTACH_SIZE_TERMINATOR but 0 is not found at expected position (MDZ_ERROR_ATTACH_TERMINATOR) |
mdz_true | operation succeeded |
mdz_utf32 API Reference is generated using mdzApiRefGenerator.
mdz_string functions
- Init functions
mdz_ansi functions
- Init and destroy functions
- Reserve capacity functions
- Insert/remove functions
- Find functions
- Miscellaneous functions
mdz_utf8 functions
- Init and destroy functions
- Reserve capacity functions
- Insert/remove functions
- mdz_utf8_insertUtf8_async
- mdz_utf8_insertUtf8_string_async
- mdz_utf8_insertAnsi_async
- mdz_utf8_insertAnsi_string_async
- mdz_utf8_insertWchar_async
- mdz_utf8_insertWchar_string_async
- mdz_utf8_insertUtf16_async
- mdz_utf8_insertUtf16_string_async
- mdz_utf8_insertUtf32_async
- mdz_utf8_insertUtf32_string_async
mdz_wchar functions
- Init and destroy functions
- Reserve capacity functions
- Insert/remove functions
- mdz_wchar_insertWchar_async
- mdz_wchar_insertWchar_string_async
- mdz_wchar_insertAnsi_async
- mdz_wchar_insertAnsi_string_async
- mdz_wchar_insertUtf8_async
- mdz_wchar_insertUtf8_string_async
- mdz_wchar_insertUtf16_async
- mdz_wchar_insertUtf16_string_async
- mdz_wchar_insertUtf32_async
- mdz_wchar_insertUtf32_string_async
mdz_utf16 functions
- Init and destroy functions
- Reserve capacity functions
- Insert/remove functions
- mdz_utf16_insertUtf16_async
- mdz_utf16_insertUtf16_string_async
- mdz_utf16_insertAnsi_async
- mdz_utf16_insertAnsi_string_async
- mdz_utf16_insertWchar_async
- mdz_utf16_insertWchar_string_async
- mdz_utf16_insertUtf8_async
- mdz_utf16_insertUtf8_string_async
- mdz_utf16_insertUtf32_async
- mdz_utf16_insertUtf32_string_async
mdz_utf32 functions
- Init and destroy functions
- Reserve capacity functions
- Insert/remove functions
- mdz_utf32_insertUtf32_async
- mdz_utf32_insertUtf32_string_async
- mdz_utf32_insertAnsi_async
- mdz_utf32_insertAnsi_string_async
- mdz_utf32_insertWchar_async
- mdz_utf32_insertWchar_string_async
- mdz_utf32_insertUtf8_async
- mdz_utf32_insertUtf8_string_async
- mdz_utf32_insertUtf16_async
- mdz_utf32_insertUtf16_string_async