Method FromManaged
- Namespace
- Ubiquity.NET.InteropHelpers
- Assembly
- Ubiquity.NET.InteropHelpers.dll
FromManaged(string?, Span<byte>)
Initializes the marshaller with a managed string and requested buffer.
public void FromManaged(string? managed, Span<byte> buffer)
Parameters
managed
stringThe managed string to initialize the marshaller with.
buffer
Span<byte>A request buffer of at least size BufferSize.
Remarks
If the buffer is not large enough to handle a native representation of managed
then a new buffer is allocated and is not released until Free() is called to release
it.