public override void Encode() { encodeBuf.Clear(); encodeBuf.AddRange(AddString(TxnType, 2)); encodeBuf.AddRange(AddString(StationId, 4)); encodeBuf.AddRange(AddString(DeviceId, 8)); encodeBuf.AddRange(AddString(ReportDate, 8)); encodeBuf.AddRange(AddString(TestFlag, 1)); encodeBuf.AddRange(AddString(SerialNo.PadLeft(3, '0'), 3)); encodeBuf.AddRange(AddString(PutInOperatorId, 6)); encodeBuf.AddRange(AddString(GetOutOperatorId, 6)); encodeBuf.AddRange(AddString(PutInTime, 14)); encodeBuf.AddRange(AddString(GetOutTime, 14)); encodeBuf.AddRange(AddString(CashBoxId.PadLeft(10, '0'), 10)); encodeBuf.AddRange(AddString(CashBoxType, 1)); encodeBuf.AddRange(AddString(Coin1Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Coin2Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Coin3Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note1Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note2Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note3Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note4Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note5Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note6Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note7Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Note8Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Spare.PadLeft(8, '0'), 8)); }
public override void Encode() { encodeBuf.Clear(); encodeBuf.AddRange(AddString(TxnType, 2)); encodeBuf.AddRange(AddString(StationId, 4)); encodeBuf.AddRange(AddString(DeviceId, 8)); encodeBuf.AddRange(AddString(ReportDate, 8)); encodeBuf.AddRange(AddString(TestFlag, 1)); encodeBuf.AddRange(AddString(SerialNo.PadLeft(3, '0'), 3)); encodeBuf.AddRange(AddString(OperatorId, 6)); encodeBuf.AddRange(AddString(CashBoxId.PadLeft(10, '0'), 10)); encodeBuf.AddRange(AddString(Coin1Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Coin2Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(Coin3Qty.PadLeft(5, '0'), 5)); encodeBuf.AddRange(AddString(CoinAddTime, 14)); encodeBuf.AddRange(AddString(Spare.PadLeft(7, '0'), 7)); }