public static long PeekInt64(this RailBitBuffer buffer, RailInt64Compressor compressor) { if (compressor.RequiredBits > RailConfig.VARINT_FALLBACK_SIZE) { return(compressor.Unpack(buffer.PeekUInt64())); } return(compressor.Unpack(buffer.Peek(compressor.RequiredBits))); }
public static float PeekFloat(this RailBitBuffer buffer, RailFloatCompressor compressor) { if (compressor.RequiredBits > RailConfig.VARINT_FALLBACK_SIZE) { return(compressor.Unpack(buffer.PeekUInt())); } return(compressor.Unpack(buffer.Peek(compressor.RequiredBits))); }
public static SequenceId Peek(RailBitBuffer buffer) { return(new SequenceId(buffer.Peek(BITS_USED))); }