internal void Get(ref PoolBufferFull buffer) { Get(ref buffer.PoolBuffer); uint index = buffer.PoolBuffer.Index; buffer.Set(Buffers[(int)(index >> arrayBits)], (int)(index & ArrayIndexMark) << sizeBits); }
internal void CopyToClear(ref PoolBufferFull buffer) { buffer.Buffer = Buffer; buffer.StartIndex = StartIndex; PoolBuffer.CopyToClear(ref buffer.PoolBuffer); Buffer = null; }
internal static void GetBuffer(ref PoolBufferFull buffer, int size) { Pool pool = GetPool(size); if (pool == null) { buffer.Set(new byte[size], 0); } else { pool.Get(ref buffer); } }
internal static void GetSingleBuffer(ref PoolBufferFull buffer, int size) { GetBuffer(ref buffer, Math.Max(size, bufferSize)); }
internal void Push(ref PoolBufferFull buffer) { Push(ref buffer.PoolBuffer); buffer.Buffer = null; }
internal void CopyTo(ref PoolBufferFull buffer, int count) { System.Buffer.BlockCopy(Buffer, StartIndex, buffer.Buffer, buffer.StartIndex, count); }