Esempio n. 1
0
 public void WriteBinaryDataBuffer(BinaryDataBuffer buffer, int positionInBuffer = 0, int number = 0)
 {
     if (positionInBuffer == 0 && number == 0)
     {
         _binaryWriter.Write(buffer.Bytes, 0, buffer.Count());
     }
     else
     {
         _binaryWriter.Write(buffer.Bytes, positionInBuffer, number);
     }
 }
Esempio n. 2
0
 public long Read(BinaryDataBuffer buffer, int positionInBuffer, int number)
 {
     return(_commonImpl.Read(buffer, positionInBuffer, number));
 }
Esempio n. 3
0
 public void Write(BinaryDataBuffer buffer, int positionInBuffer, int number)
 {
     _commonImpl.Write(buffer, positionInBuffer, number);
 }
Esempio n. 4
0
 public long Read(BinaryDataBuffer buffer, int positionInBuffer, int number)
 {
     return _underlyingStream.Read(buffer.Bytes, positionInBuffer, number);
 }
Esempio n. 5
0
 public void Write(BinaryDataBuffer buffer, int positionInBuffer, int number)
 {
     buffer.ThrowIfReadonly();
     _underlyingStream.Write(buffer.Bytes, positionInBuffer, number);
 }
Esempio n. 6
0
 MemoryStreamContext(BinaryDataBuffer bytes)
 {
     _underlyingStream      = new MemoryStream(bytes.Bytes);
     _shouldBeCopiedOnClose = !bytes.ReadOnly;
     _commonImpl            = new GenericStreamImpl(_underlyingStream);
 }