示例#1
0
 public static int ReadInt(this BitBuffer buffer, Int32Compressor compressor)
 {
     if (compressor.RequiredBits > Config.VARINT_FALLBACK_SIZE)
     {
         return(compressor.Unpack(buffer.ReadUInt()));
     }
     else
     {
         return(compressor.Unpack(buffer.Read(compressor.RequiredBits)));
     }
 }
示例#2
0
 public static SequenceId ReadSequenceId(this BitBuffer buffer)
 {
     return(new SequenceId(buffer.Read(SequenceId.BITS_USED)));
 }