Class BufferManager
A BufferManager class manages pooled buffers (byte arrays) with different sizes. It provides an implementation of the IBufferManager interface.
Inheritance
System.Object
BufferManager
Implements
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Amqp
Assembly: Amqp.Net.dll
Syntax
public class BufferManager : IBufferManager
Constructors
BufferManager(Int32, Int32, Int64)
Initializes a new instance of the BufferManager class.
Declaration
public BufferManager(int minBufferSize, int maxBufferSize, long maxMemorySize)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | minBufferSize | The minimum size in bytes of pooled buffers. |
System.Int32 | maxBufferSize | The maximum size in bytes of pooled buffers. |
System.Int64 | maxMemorySize | The maximum total size in bytes of pooled buffers. |
Explicit Interface Implementations
IBufferManager.ReturnBuffer(ArraySegment<Byte>)
Declaration
void IBufferManager.ReturnBuffer(ArraySegment<byte> buffer)
Parameters
Type | Name | Description |
---|---|---|
System.ArraySegment<System.Byte> | buffer |
IBufferManager.TakeBuffer(Int32)
Declaration
ArraySegment<byte> IBufferManager.TakeBuffer(int bufferSize)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | bufferSize |
Returns
Type | Description |
---|---|
System.ArraySegment<System.Byte> |