using Edge.Core.Parser.BinaryParser.Attributes;
using HengshanPaymentTerminal.Support;
using System;
using System.Collections.Generic;
using System.Text;

namespace  HengshanPaymentTerminal.MessageEntity.Incoming
{
    /// <summary>
    /// Result of the lock/unlock operation.
    /// 加油机回复锁定/解锁操作。
    /// </summary>
    public class LockOrUnlockPumpAck : CardMessageBase
    {
        #region Constructor

        /// <summary>
        /// Constructor
        /// </summary>
        public LockOrUnlockPumpAck() : base(Command.LockOrUnlockPumpAck)
        {

        }

        #endregion

        #region Properties

        /// <summary>
        /// Id of the payment terminal.
        /// 终端号。
        /// </summary>
        [Format(4, EncodingType.BcdString, -90)]
        public string TerminalId { get; set; }

        /// <summary>
        /// Fueling point.
        /// 加油点。
        /// </summary>
        [Format(2, EncodingType.HexString, -89)]
        public string FPCode { get; set; }

        /// <summary>
        /// Dispenser state.
        /// 加油机状态。
        /// </summary>
        [Format(1, EncodingType.BIN, -88)]
        public DispenserState DispenserState { get; set; }

        /// <summary>
        /// Lock or unlock pump operation.
        /// 锁定/解锁操作。
        /// </summary>
        [Format(1, EncodingType.BIN, -87)]
        public LockUnlockOperation OperationType { get; set; }

        #endregion
    }
}
