C# Class CqlSharp.Memory.MemoryPool

Pool of memory buffers
Exibir arquivo Open project: reuzel/CqlSharp

Public Methods

Method Description
Return ( byte buffer ) : void

Returns the specified buffer.

Take ( int size ) : byte[]

Takes a buffer from the pool, or creates one if the pool is empty, or requested size is larger than BufferSize

ToString ( ) : string

Protected Methods

Method Description
MemoryPool ( ) : System

Initializes a new instance of the MemoryPool class.

Method Details

MemoryPool() protected method

Initializes a new instance of the MemoryPool class.
protected MemoryPool ( ) : System
return System

Return() public method

Returns the specified buffer.
public Return ( byte buffer ) : void
buffer byte The buffer.
return void

Take() public method

Takes a buffer from the pool, or creates one if the pool is empty, or requested size is larger than BufferSize
public Take ( int size ) : byte[]
size int
return byte[]

ToString() public method

public ToString ( ) : string
return string