示例#1
0
 public static int ReadLength(Stream stream)
 {
     return((int)VarInt.ReadUInt32(stream));
 }
示例#2
0
 public static void WriteLength(Stream stream, int lenght)
 {
     VarInt.WriteUInt32(stream, (uint)lenght);
 }
示例#3
0
 private void WriteSignedVarInt(int value, Stream stream)
 {
     VarInt.WriteSInt32(stream, value);
 }
示例#4
0
 private int ReadSignedVarInt(Stream buffer)
 {
     return(VarInt.ReadSInt32(buffer));
 }
示例#5
0
 public override void WriteTo(BinaryWriter stream)
 {
     VarInt.WriteSInt32(stream.BaseStream, Value);
 }
示例#6
0
 public override void FromStream(BinaryReader reader)
 {
     Value = VarInt.ReadSInt32(reader.BaseStream);
 }