using System;
using System.Collections.Generic;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;

namespace UnifiedPOS.PINPad.V1_4
{
    [ServiceContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public interface PINPad
    {
        #region Version 1.1

        //
        // Common Properties
        //

        // [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAutoDisable", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAutoDisableResponse")]
        // [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        // int GetAutoDisable(string ConsumerID);

        // [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAutoDisable", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAutoDisableResponse")]
        // [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        // void SetAutoDisable(string ConsumerID, int AutoDisable);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapCompareFirmwareVersion", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapCompareFirmwareVersionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapCompareFirmwareVersion(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapPowerReporting", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapPowerReportingResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PowerReporting GetCapPowerReporting(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapStatisticsReporting", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapStatisticsReportingResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapStatisticsReporting(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapUpdateFirmware", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapUpdateFirmwareResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapUpdateFirmware(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapUpdateStatistics", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapUpdateStatisticsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapUpdateStatistics(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCheckHealthText", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCheckHealthTextResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetCheckHealthText(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetClaimed", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetClaimedResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetClaimed(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDataCount", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDataCountResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        int GetDataCount(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDataEventEnabled", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDataEventEnabledResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetDataEventEnabled(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetDataEventEnabled", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetDataEventEnabledResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetDataEventEnabled(string ConsumerID, bool DataEventEnabled);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceEnabled", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceEnabledResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetDeviceEnabled(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetDeviceEnabled", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetDeviceEnabledResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetDeviceEnabled(string ConsumerID, bool DeviceEnabled);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetFreezeEvents", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetFreezeEventsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetFreezeEvents(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetFreezeEvents", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetFreezeEventsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetFreezeEvents(string ConsumerID, bool FreezeEvents);

        // [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetOutputID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetOutputIDResponse")]
        // [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        // int GetOutputID(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPowerNotify", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPowerNotifyResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PowerNotification GetPowerNotify(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPowerNotify", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPowerNotifyResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetPowerNotify(string ConsumerID, PowerNotification PowerNotify);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPowerState", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPowerStateResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PowerState GetPowerState(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetState", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetStateResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        ControlState GetState(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceControlDescription", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceControlDescriptionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetDeviceControlDescription(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceControlVersion", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceControlVersionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        UposVersion GetDeviceControlVersion(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceServiceDescription", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceServiceDescriptionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetDeviceServiceDescription(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceServiceVersion", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetDeviceServiceVersionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        UposVersion GetDeviceServiceVersion(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPhysicalDeviceDescription", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPhysicalDeviceDescriptionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetPhysicalDeviceDescription(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPhysicalDeviceName", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPhysicalDeviceNameResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetPhysicalDeviceName(string ConsumerID);

        //
        // Specific Properties
        //

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapDisplay", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapDisplayResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PINPadDisplay GetCapDisplay(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapKeyboard", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapKeyboardResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapKeyboard(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapLanguage", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapLanguageResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PINPadLanguage GetCapLanguage(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapMACCalculation", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapMACCalculationResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapMACCalculation(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapTone", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetCapToneResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetCapTone(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAccountNumber", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAccountNumberResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetAccountNumber(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAccountNumber", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAccountNumberResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetAccountNumber(string ConsumerID, string AccountNumber);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAdditionalSecurityInformation", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAdditionalSecurityInformationResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetAdditionalSecurityInformation(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAmount", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAmountResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        decimal GetAmount(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAmount", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetAmountResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetAmount(string ConsumerID, decimal Amount);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAvailableLanguagesList", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAvailableLanguagesListResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        LanguageList GetAvailableLanguagesList(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAvailablePromptsList", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetAvailablePromptsListResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PINPadMessageList GetAvailablePromptsList(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetEncryptedPIN", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetEncryptedPINResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetEncryptedPIN(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMaximumPINLength", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMaximumPINLengthResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        int GetMaximumPINLength(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMaximumPINLength", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMaximumPINLengthResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetMaximumPINLength(string ConsumerID, int MaximumPINLength);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMerchantID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMerchantIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetMerchantID(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMerchantID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMerchantIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetMerchantID(string ConsumerID, string MerchantID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMinimumPINLength", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetMinimumPINLengthResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        int GetMinimumPINLength(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMinimumPINLength", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetMinimumPINLengthResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetMinimumPINLength(string ConsumerID, int MinimumPINLength);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPINEntryEnabled", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPINEntryEnabledResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        bool GetPINEntryEnabled(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPrompt", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPromptResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        int GetPrompt(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPrompt", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPromptResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetPrompt(string ConsumerID, int Prompt);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPromptLanguage", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetPromptLanguageResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetPromptLanguage(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPromptLanguage", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetPromptLanguageResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetPromptLanguage(string ConsumerID, string PromptLanguage);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTerminalID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTerminalIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetTerminalID(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTerminalID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTerminalIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTerminalID(string ConsumerID, string TerminalID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack1Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack1DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        byte[] GetTrack1Data(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack1Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack1DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTrack1Data(string ConsumerID, byte[] Track1Data);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack2Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack2DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        byte[] GetTrack2Data(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack2Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack2DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTrack2Data(string ConsumerID, byte[] Track2Data);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack3Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack3DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        byte[] GetTrack3Data(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack3Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack3DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTrack3Data(string ConsumerID, byte[] Track3Data);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack4Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTrack4DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        byte[] GetTrack4Data(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack4Data", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTrack4DataResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTrack4Data(string ConsumerID, byte[] Track4Data);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTransactionType", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetTransactionTypeResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        EFTTransactionType GetTransactionType(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTransactionType", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetTransactionTypeResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetTransactionType(string ConsumerID, EFTTransactionType TransactionType);

        //
        // Common Methods
        //

        //[OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/Open", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/OpenResponse")]
        //[FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        //void Open(string ConsumerID, string EndpointAddress);

        //[OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/Close", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CloseResponse")]
        //[FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        //void Close(string ConsumerID, string EndpointAddress);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/Claim", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClaimResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void Claim(string ConsumerID, int Timeout);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/Release", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ReleaseResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void Release(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CheckHealth", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CheckHealthResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void CheckHealth(string ConsumerID, HealthCheckLevel Level);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearInput", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearInputResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void ClearInput(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearInputProperties", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearInputPropertiesResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void ClearInputProperties(string ConsumerID);

        // [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearOutput", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ClearOutputResponse")]
        // [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        // void ClearOutput(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/DirectIO", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/DirectIOResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        DirectIOData DirectIO(string ConsumerID, int Command, int Data, object Obj);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CompareFirmwareVersion", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CompareFirmwareVersionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        CompareFirmwareResult CompareFirmwareVersion(string ConsumerID, string FirmwareFileName);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ResetStatistics", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ResetStatisticsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void ResetStatistics(string ConsumerID, StatisticList StatisticsBuffer);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/RetrieveStatistics", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/RetrieveStatisticsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string RetrieveStatistics(string ConsumerID, StatisticList StatisticsBuffer);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateFirmware", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateFirmwareResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void UpdateFirmware(string ConsumerID, string FirmwareFileName);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateStatistics", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateStatisticsResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void UpdateStatistics(string ConsumerID, StatisticList StatisticsBuffer);

        //
        // Specific Methods
        //

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/BeginEFTTransaction", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/BeginEFTTransactionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void BeginEFTTransaction(string ConsumerID, string PINPadSystem, int TransactionHost);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ComputeMAC", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/ComputeMACResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string ComputeMAC(string ConsumerID, string InMsg);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/EnablePINEntry", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/EnablePINEntryResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void EnablePINEntry(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/EndEFTTransaction", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/EndEFTTransactionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void EndEFTTransaction(string ConsumerID, EFTTransactionCompletion CompletionCode);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateKey", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UpdateKeyResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void UpdateKey(string ConsumerID, int KeyNum, string Key);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/VerifyMAC", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/VerifyMACResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void VerifyMAC(string ConsumerID, string Message);

        #endregion

        #region Version 1.2

        //
        // Session Management
        //

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetWSPOSVersion", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetWSPOSVersionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        UposVersion GetWSPOSVersion();

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GenerateConsumerID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GenerateConsumerIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GenerateConsumerID();

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/OpenSession", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/OpenSessionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void OpenSession(string ConsumerID, string EndpointAddress);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CloseSession", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CloseSessionResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void CloseSession(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetProviderSessionTimeout", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetProviderSessionTimeoutResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        int GetProviderSessionTimeout(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/KeepAlive", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/KeepAliveResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void KeepAlive(string ConsumerID);

        //
        // Device Control
        // 

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/OpenDevice", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/OpenDeviceResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void OpenDevice(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CloseDevice", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/CloseDeviceResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void CloseDevice(string ConsumerID);

        //
        // Event Polling
        //

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/PollForUPOSEvent", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/PollForUPOSEventResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        PINPadEvent PollForUPOSEvent(string ConsumerID);

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetEventResponse", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetEventResponseResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetEventResponse(string ConsumerID, PINPadEventResponse EventResponse);

        #endregion

        #region Version 1.3

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetEncryptedClaimedConsumerID", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/GetEncryptedClaimedConsumerIDResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        string GetEncryptedClaimedConsumerID();

        [OperationContract(Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetEventRequestProperties", ReplyAction = "http://www.nrf-arts.org/UnifiedPOS/PINPad/SetEventRequestPropertiesResponse")]
        [FaultContract(typeof(UposException), Action = "http://www.nrf-arts.org/UnifiedPOS/PINPad/UposException", Name = "UposException")]
        void SetEventRequestProperties(string ConsumerID, PropertyNameList list);

        #endregion

    }

    #region Version 1.1

    //
    // Common Data Types
    //

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DirectIOData
    {
        [DataMember]
        public int Data { get; set; }
        [DataMember]
        public object Obj { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class UposException
    {
        [DataMember]
        public ErrorCode ErrorCode { get; set; }
        [DataMember]
        public int ErrorCodeExtended { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class UposVersion
    {
        [DataMember]
        public int Major { get; set; }
        [DataMember]
        public int Minor { get; set; }
        [DataMember]
        public int Build { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class Statistic
    {
        [DataMember]
        public string Name { get; set; }
        [DataMember]
        public string Value { get; set; }
    }

    [CollectionDataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/", ItemName = "Statistic")]
    public class StatisticList : List<Statistic>
    {
    }

    //
    // Common Enumerations
    //

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum CompareFirmwareResult
    {
        [EnumMember]
        CFV_FIRMWARE_OLDER,
        [EnumMember]
        CFV_FIRMWARE_SAME,
        [EnumMember]
        CFV_FIRMWARE_NEWER,
        [EnumMember]
        CFV_FIRMWARE_DIFFERENT,
        [EnumMember]
        CFV_FIRMWARE_UNKNOWN,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum ControlState
    {
        [EnumMember]
        S_CLOSED,
        [EnumMember]
        S_IDLE,
        [EnumMember]
        S_BUSY,
        [EnumMember]
        S_ERROR,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum ErrorCode
    {
        [EnumMember]
        E_CLOSED,
        [EnumMember]
        E_CLAIMED,
        [EnumMember]
        E_NOTCLAIMED,
        [EnumMember]
        E_NOSERVICE,
        [EnumMember]
        E_DISABLED,
        [EnumMember]
        E_ILLEGAL,
        [EnumMember]
        E_NOHARDWARE,
        [EnumMember]
        E_OFFLINE,
        [EnumMember]
        E_NOEXIST,
        [EnumMember]
        E_EXISTS,
        [EnumMember]
        E_FAILURE,
        [EnumMember]
        E_TIMEOUT,
        [EnumMember]
        E_BUSY,
        [EnumMember]
        E_EXTENDED,
        [EnumMember]
        E_DEPRECATED,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum HealthCheckLevel
    {
        [EnumMember]
        CH_INTERNAL,
        [EnumMember]
        CH_EXTERNAL,
        [EnumMember]
        CH_INTERACTIVE,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PowerNotification
    {
        [EnumMember]
        PN_DISABLED,
        [EnumMember]
        PN_ENABLED,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PowerReporting
    {
        [EnumMember]
        PR_NONE,
        [EnumMember]
        PR_STANDARD,
        [EnumMember]
        PR_ADVANCED,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PowerState
    {
        [EnumMember]
        PS_UNKNOWN,
        [EnumMember]
        PS_ONLINE,
        [EnumMember]
        PS_OFF,
        [EnumMember]
        PS_OFFLINE,
        [EnumMember]
        PS_OFF_OFFLINE,
    }

    /*
    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum StatisticCategories
    {
        [EnumMember]
        All,
        [EnumMember]
        Manufacturer,
        [EnumMember]
        Upos,
    }
    */
    public class StatisticCategories
    {
        public const string All = "";
        public const string Manufacturer = "M_";
        public const string Upos = "U_";
    }

    [CollectionDataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/", ItemName = "Language")]
    public class LanguageList : List<string>
    {
    }

    [CollectionDataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/", ItemName = "PINPadMessage")]
    public class PINPadMessageList : List<int>
    {
    }

    //
    // Specific Enumerations
    //

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum EFTTransactionCompletion
    {
        [EnumMember]
        PPAD_EFT_NORMAL,
        [EnumMember]
        PPAD_EFT_ABNORMAL,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum EFTTransactionType
    {
        [EnumMember]
        PPAD_TRANS_DEBIT,
        [EnumMember]
        PPAD_TRANS_CREDIT,
        [EnumMember]
        PPAD_TRANS_INQ,
        [EnumMember]
        PPAD_TRANS_RECONCILE,
        [EnumMember]
        PPAD_TRANS_ADMIN,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PINPadDisplay
    {
        [EnumMember]
        None,
        [EnumMember]
        PPAD_DISP_UNRESTRICTED,
        [EnumMember]
        PPAD_DISP_PINRESTRICTED,
        [EnumMember]
        PPAD_DISP_RESTRICTED_LIST,
        [EnumMember]
        PPAD_DISP_RESTRICTED_ORDER,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PINPadLanguage
    {
        [EnumMember]
        PPAD_LANG_NONE,
        [EnumMember]
        PPAD_LANG_ONE,
        [EnumMember]
        PPAD_LANG_PINRESTRICTED,
        [EnumMember]
        PPAD_LANG_UNRESTRICTED,
    }

    /*
    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum PINPadMessage
    {
        [EnumMember]
        AmountOK,
        [EnumMember]
        Approved,
        [EnumMember]
        Canceled,
        [EnumMember]
        Declined,
        [EnumMember]
        EnterPin,
        [EnumMember]
        EnterValidPin,
        [EnumMember]
        Idle,
        [EnumMember]
        InsertCard,
        [EnumMember]
        NotReady,
        [EnumMember]
        PleaseWait,
        [EnumMember]
        RetriesExceeded,
        [EnumMember]
        SelectCardType,
        [EnumMember]
        SlideCard,
    }
    */
    public class PINPadMessage
    {
        public const int PPAD_MSG_ENTERPIN = 1;
        public const int PPAD_MSG_PLEASEWAIT = 2;
        public const int PPAD_MSG_ENTERVALIDPIN = 3;
        public const int PPAD_MSG_RETRIESEXCEEDED = 4;
        public const int PPAD_MSG_APPROVED = 5;
        public const int PPAD_MSG_DECLINED = 6;
        public const int PPAD_MSG_CANCELED = 7;
        public const int PPAD_MSG_AMOUNTOK = 8;
        public const int PPAD_MSG_NOTREADY = 9;
        public const int PPAD_MSG_IDLE = 10;
        public const int PPAD_MSG_SLIDE_CARD = 11;
        public const int PPAD_MSG_INSERTCARD = 12;
        public const int PPAD_MSG_SELECTCARDTYPE = 13;
    }

    //
    // Constants
    //

    /*
    public class Constants
    {
        public const int ExtendedErrorBadKey = 201;
        public const int ExtendedErrorFirmwareBadFile = 281;
        public const int ExtendedErrorStatistics = 280;
        public const int ExtendedErrorStatisticsDependency = 282;
        public const string StatisticCommunicationErrorCount = "CommunicationErrorCount";
        public const string StatisticDeviceCategory = "DeviceCategory";
        public const string StatisticFirmwareRevision = "FirmwareRevision";
        public const string StatisticHoursPoweredCount = "HoursPoweredCount";
        public const string StatisticInstallationDate = "InstallationDate";
        public const string StatisticInterface = "Interface";
        public const string StatisticInvalidPINEntryCount = "InvalidPINEntryCount";
        public const string StatisticManufactureDate = "ManufactureDate";
        public const string StatisticManufacturerName = "ManufacturerName";
        public const string StatisticMechanicalRevision = "MechanicalRevision";
        public const string StatisticModelName = "ModelName";
        public const string StatisticSerialNumber = "SerialNumber";
        public const string StatisticUnifiedPOSVersion = "UnifiedPOSVersion";
        public const string StatisticValidPINEntryCount = "ValidPINEntryCount";
        public const int WaitForever = -1;
    }
    */

    public class ExtendedError
    {
        public const int EPPAD_BADKEY = 201;
        public const int EFIRMWARE_BAD_FILE = 281;
        public const int ESTATS_ERROR = 280;
        public const int ESTATS_DEPENDENCY = 282;
    }

    public class StatisticProperties
    {
        public const string CommunicationErrorCount = "CommunicationErrorCount";
        public const string DeviceCategory = "DeviceCategory";
        public const string FirmwareRevision = "FirmwareRevision";
        public const string HoursPoweredCount = "HoursPoweredCount";
        public const string InstallationDate = "InstallationDate";
        public const string Interface = "Interface";
        public const string InvalidPINEntryCount = "InvalidPINEntryCount";
        public const string ManufactureDate = "ManufactureDate";
        public const string ManufacturerName = "ManufacturerName";
        public const string MechanicalRevision = "MechanicalRevision";
        public const string ModelName = "ModelName";
        public const string SerialNumber = "SerialNumber";
        public const string UnifiedPOSVersion = "UnifiedPOSVersion";
        public const string ValidPINEntryCount = "ValidPINEntryCount";
    }

    public class Wait
    {
        public const int FOREVER = -1;
    }

    #endregion

    #region Version 1.2

    //
    // Event Polling
    //

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class PINPadEvent
    {
        [DataMember]
        public DataEvent DataEvent { get; set; }
        [DataMember]
        public DirectIOEvent DirectIOEvent { get; set; }
        [DataMember]
        public ErrorEvent ErrorEvent { get; set; }
        //[DataMember]
        //public OutputCompleteEvent OutputCompleteEvent { get; set; }
        [DataMember]
        public StatusUpdateEvent StatusUpdateEvent { get; set; }
        [DataMember]
        public DataContainedEvent DataContainedEvent { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class PINPadEventResponse
    {
        [DataMember]
        public DataEventResponse DataEventResponse { get; set; }
        [DataMember]
        public DataContainedEventResponse DataContainedEventResponse { get; set; }
        [DataMember]
        public DirectIOEventResponse DirectIOEventResponse { get; set; }
        [DataMember]
        public ErrorEventResponse ErrorEventResponse { get; set; }
        //[DataMember]
        //public OutputCompleteEventResponse OutputCompleteEventResponse { get; set; }
        [DataMember]
        public StatusUpdateEventResponse StatusUpdateEventResponse { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DataEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        public int Status { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DataEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DirectIOEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        public int EventNumber { get; set; }
        [DataMember]
        public int Data { get; set; }
        [DataMember]
        public object Obj { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DirectIOEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DirectIOData DirectIOData { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class ErrorEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        public ErrorCode ErrorCode { get; set; }
        [DataMember]
        public int ErrorCodeExtended { get; set; }
        [DataMember]
        public ErrorLocus ErrorLocus { get; set; }
        [DataMember]
        public ErrorResponse ErrorResponse { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class ErrorEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public ErrorResponse ErrorResponse { get; set; }
    }
    /*
    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class OutputCompleteEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        int OutputID { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class OutputCompleteEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
    }
    */
    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class StatusUpdateEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        public int Status { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class StatusUpdateEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum ErrorLocus
    {
        [EnumMember]
        EL_INPUT,
        [EnumMember]
        EL_INPUT_DATA,
        [EnumMember]
        EL_OUTPUT,
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public enum ErrorResponse
    {
        [EnumMember]
        ER_CLEAR,
        [EnumMember]
        ER_CONTINUEINPUT,
        [EnumMember]
        ER_RETRY,
    }

    #endregion

    #region Version 1.3

    [CollectionDataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/", ItemName = "PropertyName")]
    public class PropertyNameList : List<string>
    {
    }



    [CollectionDataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/", ItemName = "Parameter")]
    public class ParameterList : Dictionary<string, object>
    {
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DataContainedEvent
    {
        [DataMember]
        public string Source { get; set; }
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public DateTime TimeStamp { get; set; }
        [DataMember]
        public int Status { get; set; }
        [DataMember]
        public ParameterList Parameters { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DataContainedEventData
    {
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public bool SetDataEventEnabled { get; set; }
        [DataMember]
        public bool CallClearInputProperties { get; set; }
    }

    [DataContract(Namespace = "http://www.nrf-arts.org/UnifiedPOS/PINPad/")]
    public class DataContainedEventResponse
    {
        [DataMember]
        public int EventID { get; set; }
        [DataMember]
        public bool SetDataEventEnabled { get; set; }
        [DataMember]
        public bool CallClearInputProperties { get; set; }
    }

    #endregion
}
