StringMem extension

Simplifies writing / reading strings to / from native memory.

Strings that are to be placed in native memory buffers are always converted to UTF-8 representation, and then stored byte by byte. The other way around, bytes from a native buffer are treated as UTF-8 code points and converted back to a Unicode string.

on

Methods

writeToBuffer(Pointer<Uint8> buffer, int offset, {bool includeNullTerm = true, int? maxLength}) → void

Available on String, provided by the StringMem extension

Puts a string into the buffer, starting at offset.