コード例 #1
0
 /// <summary>
 /// Reads a bit field from the stream.
 /// </summary>
 /// <param name="sizeInBytes">The size of the bit field in bytes.</param>
 /// <param name="value">The bit field that was read.</param>
 /// <returns></returns>
 public EasyReader ReadBitField(int sizeInBytes, out BitField value)
 {
     value = new BitField(new byte[sizeInBytes]);
     _stream.Read(value._field, 0, sizeInBytes);
     return(this);
 }
コード例 #2
0
 /// <summary>
 /// Write a bit field to the stream.
 /// </summary>
 /// <param name="value">The bit field to write.</param>
 /// <returns></returns>
 public EasyWriter Write(BitField value)
 {
     BaseStream.Write(value._field, 0, value._field.Length);
     return(this);
 }