Interface IUnmanagedMemory
Represents common interface for the wrapper of the unmanaged memory.
Namespace: DotNext.Runtime.InteropServices
Assembly: DotNext.Unsafe.dll
Syntax
public interface IUnmanagedMemory : IDisposable
Properties
| Improve this Doc View SourceBytes
Gets a span of bytes from the current instance.
Declaration
Span<byte> Bytes { get; }
Property Value
Type | Description |
---|---|
Span<Byte> |
Pointer
Gets a pointer to the allocated unmanaged memory.
Declaration
Pointer<byte> Pointer { get; }
Property Value
Type | Description |
---|---|
Pointer<Byte> |
Size
Gets size of referenced unmanaged memory, in bytes.
Declaration
long Size { get; }
Property Value
Type | Description |
---|---|
Int64 |
Methods
| Improve this Doc View SourceAsStream()
Represents unmanaged memory as stream.
Declaration
Stream AsStream()
Returns
Type | Description |
---|---|
Stream | The stream of unmanaged memory. |
Clear()
Sets all bits of allocated memory to zero.
Declaration
void Clear()