public ushort ReadUInt16() { byte[] buffer = new byte[2]; this.Read(buffer, 0, buffer.Length); return BitConverter.ToUInt16(buffer, 0); }
/// <summary> /// Parse from a stream. /// </summary> /// <param name="stream">A stream contains CN.</param> public void Parse(FastTransferStream stream) { this.replicaId = stream.ReadUInt16(); this.globalCounter = BitConverter.ToUInt64(stream.ReadBlock(6), 0); }