public static PooledNetworkReader GetReader(ArraySegment <byte> segment) { // grab from pool & set buffer PooledNetworkReader reader = Pool.Take(); reader.SetBuffer(segment); return(reader); }
public static PooledNetworkReader GetReader(byte[] bytes) { // grab from pool & set buffer PooledNetworkReader reader = Pool.Take(); reader.SetBuffer(bytes); return(reader); }