public ArraySegment<byte> Get(int index, byte[] buffer) { lock (mReadStream) { DataRecord dr = new DataRecord(index, mRecordSize); return dr.GetData(mReadStream, buffer); } }
public void Set(ArraySegment<byte> data, int index) { lock (mWriteStream) { DataRecord dr = new DataRecord(index, mRecordSize); dr.SetData(data, mWriteStream); } }