internal void Write(RailBitBuffer buffer) { uint first = FixedByteBuffer8.Pack(this.val0, this.val1, this.val2, this.val3); uint second = FixedByteBuffer8.Pack(this.val4, this.val5, this.val6, this.val7); bool writeSecond = (second > 0); buffer.WriteUInt(first); buffer.WriteBool(writeSecond); if (writeSecond) { buffer.WriteUInt(second); } }
private FixedByteBuffer8(uint first, uint second) { FixedByteBuffer8.Unpack( first, out this.val0, out this.val1, out this.val2, out this.val3); FixedByteBuffer8.Unpack( second, out this.val4, out this.val5, out this.val6, out this.val7); }
public static void WriteFixedByteBuffer8( this RailBitBuffer buffer, FixedByteBuffer8 array) { array.Write(buffer); }
public static FixedByteBuffer8 ReadFixedByteBuffer8( this RailBitBuffer buffer) { return(FixedByteBuffer8.Read(buffer)); }