Struct NatsMemoryOwner<T>
An IMemoryOwner<T> implementation with an embedded length and a fast Span<T> accessor.
public struct NatsMemoryOwner<T> : IMemoryOwner<T>, IDisposableType Parameters
- T
- The type of items to store in the current instance. 
- Implements
- 
      IMemoryOwner<T>
- Inherited Members
Properties
- Empty
- Gets an empty NatsMemoryOwner<T> instance. 
- Length
- Gets the number of items in the current instance 
Methods
- Allocate(int)
- Creates a new NatsMemoryOwner<T> instance with the specified parameters. 
- Allocate(int, NatsMemoryOwnerAllocationMode)
- Creates a new NatsMemoryOwner<T> instance with the specified parameters. 
- Allocate(int, ArrayPool<T>)
- Creates a new NatsMemoryOwner<T> instance with the specified parameters. 
- Allocate(int, ArrayPool<T>, NatsMemoryOwnerAllocationMode)
- Creates a new NatsMemoryOwner<T> instance with the specified parameters. 
- DangerousGetArray()
- Gets an ArraySegment<T> instance wrapping the underlying - Tarray in use.
- Slice(int, int)
- Slices the buffer currently in use and returns a new NatsMemoryOwner<T> instance.