/* 
 * GK application - OmniPOS Service API
 *
 * No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
 *
 * OpenAPI spec version: 5.21.1-b03
 * 
 * Generated by: https://github.com/swagger-api/swagger-codegen.git
 */

using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.ComponentModel.DataAnnotations;
using SwaggerDateConverter = IO.Swagger.Client.SwaggerDateConverter;

namespace IO.Swagger.Model
{
    /// <summary>
    /// TenderLineItem &lt;emph&gt;undocumented&lt;/emph&gt;
    /// </summary>
    [DataContract]
    public partial class ComGkSoftwareGkrApiTxpoolDtoTenderLineItem :  IEquatable<ComGkSoftwareGkrApiTxpoolDtoTenderLineItem>, IValidatableObject
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="ComGkSoftwareGkrApiTxpoolDtoTenderLineItem" /> class.
        /// </summary>
        [JsonConstructorAttribute]
        protected ComGkSoftwareGkrApiTxpoolDtoTenderLineItem() { }
        /// <summary>
        /// Initializes a new instance of the <see cref="ComGkSoftwareGkrApiTxpoolDtoTenderLineItem" /> class.
        /// </summary>
        /// <param name="key">&lt;p&gt;Getter for inner key class.&lt;/p&gt; (required).</param>
        /// <param name="isChangeFlag">If true, denotes that the Tender is returned by the retailer to the Customer. .</param>
        /// <param name="tenderTypeCode">A code which uniquely identifies the tenderCorresponds to Tender.TenderTypeCode.</param>
        /// <param name="tenderAccountNumber">The tender account number.</param>
        /// <param name="foreignCurrencyAmount">The monetary value (in the currency submitted by the Customer) of the tender submitted by the Customer.  (required).</param>
        /// <param name="exchangeRate">The exchange rate used to convert the tendered amount into the default currency of the retail enterprise. &lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!.</param>
        /// <param name="tenderAmount">The monetary value (in the default currency of the retail enterprise) of the tender submitted by the Customer.  (required).</param>
        /// <param name="tenderGroupCode">The grouping of tenders with similar (technical) handling on POS side. Corresponds to TenderHandlingRule.TenderGroupCode .</param>
        /// <param name="tenderCount">The count of the media for the given tender  (required).</param>
        /// <param name="tenderDescription">Text to be printed on the receipt..</param>
        /// <param name="cashbackFlag">Boolean identifier for cash back (required).</param>
        /// <param name="foreignISOCurrencyCode">Currency code designated by ISO to identify the currency of the tender.</param>
        /// <param name="exchangeRateMultiplyFlag">Determines whether inside the calculation FromCurrencyID -&gt; ToCurrencyID the amount is to be multiplied with (true) or divided by (false) the factor (ExchangeRate) (required).</param>
        /// <param name="currencySymbol">Currency symbol of the tender.</param>
        /// <param name="tipAmount">The monetary amount (in the default currency of the retail enterprise) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!.</param>
        /// <param name="tipForeignCurrencyAmount">The monetary amount (in the tendered currency) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!.</param>
        /// <param name="xxcustom08">Customizable information.</param>
        /// <param name="xxcustom10">Customizable information.</param>
        /// <param name="xxcustom09">Customizable information.</param>
        /// <param name="xxcustom07">Customizable information.</param>
        /// <param name="xxcustom05">Customizable information.</param>
        /// <param name="xxcustom06">Customizable information.</param>
        /// <param name="xxcustom11">Customizable information.</param>
        /// <param name="xxcustom12">Customizable information.</param>
        /// <param name="xxcustom13">Customizable information.</param>
        /// <param name="xxcustom14">Customizable information.</param>
        /// <param name="xxcustom15">Customizable information.</param>
        /// <param name="xxcustom03">Customizable information.</param>
        /// <param name="checkTenderLineItemList">Check data for check tender line items.</param>
        /// <param name="xxcustom02">Customizable information.</param>
        /// <param name="xxcustom04">Customizable information.</param>
        /// <param name="xxcustom01">Customizable information.</param>
        public ComGkSoftwareGkrApiTxpoolDtoTenderLineItem(ComGkSoftwareGkrApiTxpoolDtoTenderLineItemKey key = default(ComGkSoftwareGkrApiTxpoolDtoTenderLineItemKey), bool? isChangeFlag = default(bool?), string tenderTypeCode = default(string), string tenderAccountNumber = default(string), double? foreignCurrencyAmount = default(double?), double? exchangeRate = default(double?), double? tenderAmount = default(double?), string tenderGroupCode = default(string), int? tenderCount = default(int?), string tenderDescription = default(string), bool? cashbackFlag = default(bool?), string foreignISOCurrencyCode = default(string), bool? exchangeRateMultiplyFlag = default(bool?), string currencySymbol = default(string), double? tipAmount = default(double?), double? tipForeignCurrencyAmount = default(double?), string xxcustom08 = default(string), string xxcustom10 = default(string), string xxcustom09 = default(string), string xxcustom07 = default(string), string xxcustom05 = default(string), string xxcustom06 = default(string), string xxcustom11 = default(string), string xxcustom12 = default(string), string xxcustom13 = default(string), string xxcustom14 = default(string), string xxcustom15 = default(string), string xxcustom03 = default(string), List<ComGkSoftwareGkrApiTxpoolDtoCheckTenderLineItem> checkTenderLineItemList = default(List<ComGkSoftwareGkrApiTxpoolDtoCheckTenderLineItem>), string xxcustom02 = default(string), string xxcustom04 = default(string), string xxcustom01 = default(string))
        {
            // to ensure "key" is required (not null)
            if (key == null)
            {
                throw new InvalidDataException("key is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.Key = key;
            }
            // to ensure "foreignCurrencyAmount" is required (not null)
            if (foreignCurrencyAmount == null)
            {
                throw new InvalidDataException("foreignCurrencyAmount is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.ForeignCurrencyAmount = foreignCurrencyAmount;
            }
            // to ensure "tenderAmount" is required (not null)
            if (tenderAmount == null)
            {
                throw new InvalidDataException("tenderAmount is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.TenderAmount = tenderAmount;
            }
            // to ensure "tenderCount" is required (not null)
            if (tenderCount == null)
            {
                throw new InvalidDataException("tenderCount is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.TenderCount = tenderCount;
            }
            // to ensure "cashbackFlag" is required (not null)
            if (cashbackFlag == null)
            {
                throw new InvalidDataException("cashbackFlag is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.CashbackFlag = cashbackFlag;
            }
            // to ensure "exchangeRateMultiplyFlag" is required (not null)
            if (exchangeRateMultiplyFlag == null)
            {
                throw new InvalidDataException("exchangeRateMultiplyFlag is a required property for ComGkSoftwareGkrApiTxpoolDtoTenderLineItem and cannot be null");
            }
            else
            {
                this.ExchangeRateMultiplyFlag = exchangeRateMultiplyFlag;
            }
            this.IsChangeFlag = isChangeFlag;
            this.TenderTypeCode = tenderTypeCode;
            this.TenderAccountNumber = tenderAccountNumber;
            this.ExchangeRate = exchangeRate;
            this.TenderGroupCode = tenderGroupCode;
            this.TenderDescription = tenderDescription;
            this.ForeignISOCurrencyCode = foreignISOCurrencyCode;
            this.CurrencySymbol = currencySymbol;
            this.TipAmount = tipAmount;
            this.TipForeignCurrencyAmount = tipForeignCurrencyAmount;
            this.Xxcustom08 = xxcustom08;
            this.Xxcustom10 = xxcustom10;
            this.Xxcustom09 = xxcustom09;
            this.Xxcustom07 = xxcustom07;
            this.Xxcustom05 = xxcustom05;
            this.Xxcustom06 = xxcustom06;
            this.Xxcustom11 = xxcustom11;
            this.Xxcustom12 = xxcustom12;
            this.Xxcustom13 = xxcustom13;
            this.Xxcustom14 = xxcustom14;
            this.Xxcustom15 = xxcustom15;
            this.Xxcustom03 = xxcustom03;
            this.CheckTenderLineItemList = checkTenderLineItemList;
            this.Xxcustom02 = xxcustom02;
            this.Xxcustom04 = xxcustom04;
            this.Xxcustom01 = xxcustom01;
        }
        
        /// <summary>
        /// &lt;p&gt;Getter for inner key class.&lt;/p&gt;
        /// </summary>
        /// <value>&lt;p&gt;Getter for inner key class.&lt;/p&gt;</value>
        [DataMember(Name="key", EmitDefaultValue=false)]
        public ComGkSoftwareGkrApiTxpoolDtoTenderLineItemKey Key { get; set; }

        /// <summary>
        /// If true, denotes that the Tender is returned by the retailer to the Customer. 
        /// </summary>
        /// <value>If true, denotes that the Tender is returned by the retailer to the Customer. </value>
        [DataMember(Name="isChangeFlag", EmitDefaultValue=false)]
        public bool? IsChangeFlag { get; set; }

        /// <summary>
        /// A code which uniquely identifies the tenderCorresponds to Tender.TenderTypeCode
        /// </summary>
        /// <value>A code which uniquely identifies the tenderCorresponds to Tender.TenderTypeCode</value>
        [DataMember(Name="tenderTypeCode", EmitDefaultValue=false)]
        public string TenderTypeCode { get; set; }

        /// <summary>
        /// The tender account number
        /// </summary>
        /// <value>The tender account number</value>
        [DataMember(Name="tenderAccountNumber", EmitDefaultValue=false)]
        public string TenderAccountNumber { get; set; }

        /// <summary>
        /// The monetary value (in the currency submitted by the Customer) of the tender submitted by the Customer. 
        /// </summary>
        /// <value>The monetary value (in the currency submitted by the Customer) of the tender submitted by the Customer. </value>
        [DataMember(Name="foreignCurrencyAmount", EmitDefaultValue=false)]
        public double? ForeignCurrencyAmount { get; set; }

        /// <summary>
        /// The exchange rate used to convert the tendered amount into the default currency of the retail enterprise. &lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!
        /// </summary>
        /// <value>The exchange rate used to convert the tendered amount into the default currency of the retail enterprise. &lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!</value>
        [DataMember(Name="exchangeRate", EmitDefaultValue=false)]
        public double? ExchangeRate { get; set; }

        /// <summary>
        /// The monetary value (in the default currency of the retail enterprise) of the tender submitted by the Customer. 
        /// </summary>
        /// <value>The monetary value (in the default currency of the retail enterprise) of the tender submitted by the Customer. </value>
        [DataMember(Name="tenderAmount", EmitDefaultValue=false)]
        public double? TenderAmount { get; set; }

        /// <summary>
        /// The grouping of tenders with similar (technical) handling on POS side. Corresponds to TenderHandlingRule.TenderGroupCode 
        /// </summary>
        /// <value>The grouping of tenders with similar (technical) handling on POS side. Corresponds to TenderHandlingRule.TenderGroupCode </value>
        [DataMember(Name="tenderGroupCode", EmitDefaultValue=false)]
        public string TenderGroupCode { get; set; }

        /// <summary>
        /// The count of the media for the given tender 
        /// </summary>
        /// <value>The count of the media for the given tender </value>
        [DataMember(Name="tenderCount", EmitDefaultValue=false)]
        public int? TenderCount { get; set; }

        /// <summary>
        /// Text to be printed on the receipt.
        /// </summary>
        /// <value>Text to be printed on the receipt.</value>
        [DataMember(Name="tenderDescription", EmitDefaultValue=false)]
        public string TenderDescription { get; set; }

        /// <summary>
        /// Boolean identifier for cash back
        /// </summary>
        /// <value>Boolean identifier for cash back</value>
        [DataMember(Name="cashbackFlag", EmitDefaultValue=false)]
        public bool? CashbackFlag { get; set; }

        /// <summary>
        /// Currency code designated by ISO to identify the currency of the tender
        /// </summary>
        /// <value>Currency code designated by ISO to identify the currency of the tender</value>
        [DataMember(Name="foreignISOCurrencyCode", EmitDefaultValue=false)]
        public string ForeignISOCurrencyCode { get; set; }

        /// <summary>
        /// Determines whether inside the calculation FromCurrencyID -&gt; ToCurrencyID the amount is to be multiplied with (true) or divided by (false) the factor (ExchangeRate)
        /// </summary>
        /// <value>Determines whether inside the calculation FromCurrencyID -&gt; ToCurrencyID the amount is to be multiplied with (true) or divided by (false) the factor (ExchangeRate)</value>
        [DataMember(Name="exchangeRateMultiplyFlag", EmitDefaultValue=false)]
        public bool? ExchangeRateMultiplyFlag { get; set; }

        /// <summary>
        /// Currency symbol of the tender
        /// </summary>
        /// <value>Currency symbol of the tender</value>
        [DataMember(Name="currencySymbol", EmitDefaultValue=false)]
        public string CurrencySymbol { get; set; }

        /// <summary>
        /// The monetary amount (in the default currency of the retail enterprise) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!
        /// </summary>
        /// <value>The monetary amount (in the default currency of the retail enterprise) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!</value>
        [DataMember(Name="tipAmount", EmitDefaultValue=false)]
        public double? TipAmount { get; set; }

        /// <summary>
        /// The monetary amount (in the tendered currency) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!
        /// </summary>
        /// <value>The monetary amount (in the tendered currency) being collected as Tip for serving staff&lt;br&gt;Fixed decimal precision expected, definition of used precision: double(16, 5). Be aware of this and round value!</value>
        [DataMember(Name="tipForeignCurrencyAmount", EmitDefaultValue=false)]
        public double? TipForeignCurrencyAmount { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom08", EmitDefaultValue=false)]
        public string Xxcustom08 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom10", EmitDefaultValue=false)]
        public string Xxcustom10 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom09", EmitDefaultValue=false)]
        public string Xxcustom09 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom07", EmitDefaultValue=false)]
        public string Xxcustom07 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom05", EmitDefaultValue=false)]
        public string Xxcustom05 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom06", EmitDefaultValue=false)]
        public string Xxcustom06 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom11", EmitDefaultValue=false)]
        public string Xxcustom11 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom12", EmitDefaultValue=false)]
        public string Xxcustom12 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom13", EmitDefaultValue=false)]
        public string Xxcustom13 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom14", EmitDefaultValue=false)]
        public string Xxcustom14 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom15", EmitDefaultValue=false)]
        public string Xxcustom15 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom03", EmitDefaultValue=false)]
        public string Xxcustom03 { get; set; }

        /// <summary>
        /// Check data for check tender line items
        /// </summary>
        /// <value>Check data for check tender line items</value>
        [DataMember(Name="checkTenderLineItemList", EmitDefaultValue=false)]
        public List<ComGkSoftwareGkrApiTxpoolDtoCheckTenderLineItem> CheckTenderLineItemList { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom02", EmitDefaultValue=false)]
        public string Xxcustom02 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom04", EmitDefaultValue=false)]
        public string Xxcustom04 { get; set; }

        /// <summary>
        /// Customizable information
        /// </summary>
        /// <value>Customizable information</value>
        [DataMember(Name="xxcustom01", EmitDefaultValue=false)]
        public string Xxcustom01 { get; set; }

        /// <summary>
        /// Returns the string presentation of the object
        /// </summary>
        /// <returns>String presentation of the object</returns>
        public override string ToString()
        {
            var sb = new StringBuilder();
            sb.Append("class ComGkSoftwareGkrApiTxpoolDtoTenderLineItem {\n");
            sb.Append("  Key: ").Append(Key).Append("\n");
            sb.Append("  IsChangeFlag: ").Append(IsChangeFlag).Append("\n");
            sb.Append("  TenderTypeCode: ").Append(TenderTypeCode).Append("\n");
            sb.Append("  TenderAccountNumber: ").Append(TenderAccountNumber).Append("\n");
            sb.Append("  ForeignCurrencyAmount: ").Append(ForeignCurrencyAmount).Append("\n");
            sb.Append("  ExchangeRate: ").Append(ExchangeRate).Append("\n");
            sb.Append("  TenderAmount: ").Append(TenderAmount).Append("\n");
            sb.Append("  TenderGroupCode: ").Append(TenderGroupCode).Append("\n");
            sb.Append("  TenderCount: ").Append(TenderCount).Append("\n");
            sb.Append("  TenderDescription: ").Append(TenderDescription).Append("\n");
            sb.Append("  CashbackFlag: ").Append(CashbackFlag).Append("\n");
            sb.Append("  ForeignISOCurrencyCode: ").Append(ForeignISOCurrencyCode).Append("\n");
            sb.Append("  ExchangeRateMultiplyFlag: ").Append(ExchangeRateMultiplyFlag).Append("\n");
            sb.Append("  CurrencySymbol: ").Append(CurrencySymbol).Append("\n");
            sb.Append("  TipAmount: ").Append(TipAmount).Append("\n");
            sb.Append("  TipForeignCurrencyAmount: ").Append(TipForeignCurrencyAmount).Append("\n");
            sb.Append("  Xxcustom08: ").Append(Xxcustom08).Append("\n");
            sb.Append("  Xxcustom10: ").Append(Xxcustom10).Append("\n");
            sb.Append("  Xxcustom09: ").Append(Xxcustom09).Append("\n");
            sb.Append("  Xxcustom07: ").Append(Xxcustom07).Append("\n");
            sb.Append("  Xxcustom05: ").Append(Xxcustom05).Append("\n");
            sb.Append("  Xxcustom06: ").Append(Xxcustom06).Append("\n");
            sb.Append("  Xxcustom11: ").Append(Xxcustom11).Append("\n");
            sb.Append("  Xxcustom12: ").Append(Xxcustom12).Append("\n");
            sb.Append("  Xxcustom13: ").Append(Xxcustom13).Append("\n");
            sb.Append("  Xxcustom14: ").Append(Xxcustom14).Append("\n");
            sb.Append("  Xxcustom15: ").Append(Xxcustom15).Append("\n");
            sb.Append("  Xxcustom03: ").Append(Xxcustom03).Append("\n");
            sb.Append("  CheckTenderLineItemList: ").Append(CheckTenderLineItemList).Append("\n");
            sb.Append("  Xxcustom02: ").Append(Xxcustom02).Append("\n");
            sb.Append("  Xxcustom04: ").Append(Xxcustom04).Append("\n");
            sb.Append("  Xxcustom01: ").Append(Xxcustom01).Append("\n");
            sb.Append("}\n");
            return sb.ToString();
        }
  
        /// <summary>
        /// Returns the JSON string presentation of the object
        /// </summary>
        /// <returns>JSON string presentation of the object</returns>
        public virtual string ToJson()
        {
            return JsonConvert.SerializeObject(this, Formatting.Indented);
        }

        /// <summary>
        /// Returns true if objects are equal
        /// </summary>
        /// <param name="input">Object to be compared</param>
        /// <returns>Boolean</returns>
        public override bool Equals(object input)
        {
            return this.Equals(input as ComGkSoftwareGkrApiTxpoolDtoTenderLineItem);
        }

        /// <summary>
        /// Returns true if ComGkSoftwareGkrApiTxpoolDtoTenderLineItem instances are equal
        /// </summary>
        /// <param name="input">Instance of ComGkSoftwareGkrApiTxpoolDtoTenderLineItem to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(ComGkSoftwareGkrApiTxpoolDtoTenderLineItem input)
        {
            if (input == null)
                return false;

            return 
                (
                    this.Key == input.Key ||
                    (this.Key != null &&
                    this.Key.Equals(input.Key))
                ) && 
                (
                    this.IsChangeFlag == input.IsChangeFlag ||
                    (this.IsChangeFlag != null &&
                    this.IsChangeFlag.Equals(input.IsChangeFlag))
                ) && 
                (
                    this.TenderTypeCode == input.TenderTypeCode ||
                    (this.TenderTypeCode != null &&
                    this.TenderTypeCode.Equals(input.TenderTypeCode))
                ) && 
                (
                    this.TenderAccountNumber == input.TenderAccountNumber ||
                    (this.TenderAccountNumber != null &&
                    this.TenderAccountNumber.Equals(input.TenderAccountNumber))
                ) && 
                (
                    this.ForeignCurrencyAmount == input.ForeignCurrencyAmount ||
                    (this.ForeignCurrencyAmount != null &&
                    this.ForeignCurrencyAmount.Equals(input.ForeignCurrencyAmount))
                ) && 
                (
                    this.ExchangeRate == input.ExchangeRate ||
                    (this.ExchangeRate != null &&
                    this.ExchangeRate.Equals(input.ExchangeRate))
                ) && 
                (
                    this.TenderAmount == input.TenderAmount ||
                    (this.TenderAmount != null &&
                    this.TenderAmount.Equals(input.TenderAmount))
                ) && 
                (
                    this.TenderGroupCode == input.TenderGroupCode ||
                    (this.TenderGroupCode != null &&
                    this.TenderGroupCode.Equals(input.TenderGroupCode))
                ) && 
                (
                    this.TenderCount == input.TenderCount ||
                    (this.TenderCount != null &&
                    this.TenderCount.Equals(input.TenderCount))
                ) && 
                (
                    this.TenderDescription == input.TenderDescription ||
                    (this.TenderDescription != null &&
                    this.TenderDescription.Equals(input.TenderDescription))
                ) && 
                (
                    this.CashbackFlag == input.CashbackFlag ||
                    (this.CashbackFlag != null &&
                    this.CashbackFlag.Equals(input.CashbackFlag))
                ) && 
                (
                    this.ForeignISOCurrencyCode == input.ForeignISOCurrencyCode ||
                    (this.ForeignISOCurrencyCode != null &&
                    this.ForeignISOCurrencyCode.Equals(input.ForeignISOCurrencyCode))
                ) && 
                (
                    this.ExchangeRateMultiplyFlag == input.ExchangeRateMultiplyFlag ||
                    (this.ExchangeRateMultiplyFlag != null &&
                    this.ExchangeRateMultiplyFlag.Equals(input.ExchangeRateMultiplyFlag))
                ) && 
                (
                    this.CurrencySymbol == input.CurrencySymbol ||
                    (this.CurrencySymbol != null &&
                    this.CurrencySymbol.Equals(input.CurrencySymbol))
                ) && 
                (
                    this.TipAmount == input.TipAmount ||
                    (this.TipAmount != null &&
                    this.TipAmount.Equals(input.TipAmount))
                ) && 
                (
                    this.TipForeignCurrencyAmount == input.TipForeignCurrencyAmount ||
                    (this.TipForeignCurrencyAmount != null &&
                    this.TipForeignCurrencyAmount.Equals(input.TipForeignCurrencyAmount))
                ) && 
                (
                    this.Xxcustom08 == input.Xxcustom08 ||
                    (this.Xxcustom08 != null &&
                    this.Xxcustom08.Equals(input.Xxcustom08))
                ) && 
                (
                    this.Xxcustom10 == input.Xxcustom10 ||
                    (this.Xxcustom10 != null &&
                    this.Xxcustom10.Equals(input.Xxcustom10))
                ) && 
                (
                    this.Xxcustom09 == input.Xxcustom09 ||
                    (this.Xxcustom09 != null &&
                    this.Xxcustom09.Equals(input.Xxcustom09))
                ) && 
                (
                    this.Xxcustom07 == input.Xxcustom07 ||
                    (this.Xxcustom07 != null &&
                    this.Xxcustom07.Equals(input.Xxcustom07))
                ) && 
                (
                    this.Xxcustom05 == input.Xxcustom05 ||
                    (this.Xxcustom05 != null &&
                    this.Xxcustom05.Equals(input.Xxcustom05))
                ) && 
                (
                    this.Xxcustom06 == input.Xxcustom06 ||
                    (this.Xxcustom06 != null &&
                    this.Xxcustom06.Equals(input.Xxcustom06))
                ) && 
                (
                    this.Xxcustom11 == input.Xxcustom11 ||
                    (this.Xxcustom11 != null &&
                    this.Xxcustom11.Equals(input.Xxcustom11))
                ) && 
                (
                    this.Xxcustom12 == input.Xxcustom12 ||
                    (this.Xxcustom12 != null &&
                    this.Xxcustom12.Equals(input.Xxcustom12))
                ) && 
                (
                    this.Xxcustom13 == input.Xxcustom13 ||
                    (this.Xxcustom13 != null &&
                    this.Xxcustom13.Equals(input.Xxcustom13))
                ) && 
                (
                    this.Xxcustom14 == input.Xxcustom14 ||
                    (this.Xxcustom14 != null &&
                    this.Xxcustom14.Equals(input.Xxcustom14))
                ) && 
                (
                    this.Xxcustom15 == input.Xxcustom15 ||
                    (this.Xxcustom15 != null &&
                    this.Xxcustom15.Equals(input.Xxcustom15))
                ) && 
                (
                    this.Xxcustom03 == input.Xxcustom03 ||
                    (this.Xxcustom03 != null &&
                    this.Xxcustom03.Equals(input.Xxcustom03))
                ) && 
                (
                    this.CheckTenderLineItemList == input.CheckTenderLineItemList ||
                    this.CheckTenderLineItemList != null &&
                    this.CheckTenderLineItemList.SequenceEqual(input.CheckTenderLineItemList)
                ) && 
                (
                    this.Xxcustom02 == input.Xxcustom02 ||
                    (this.Xxcustom02 != null &&
                    this.Xxcustom02.Equals(input.Xxcustom02))
                ) && 
                (
                    this.Xxcustom04 == input.Xxcustom04 ||
                    (this.Xxcustom04 != null &&
                    this.Xxcustom04.Equals(input.Xxcustom04))
                ) && 
                (
                    this.Xxcustom01 == input.Xxcustom01 ||
                    (this.Xxcustom01 != null &&
                    this.Xxcustom01.Equals(input.Xxcustom01))
                );
        }

        /// <summary>
        /// Gets the hash code
        /// </summary>
        /// <returns>Hash code</returns>
        public override int GetHashCode()
        {
            unchecked // Overflow is fine, just wrap
            {
                int hashCode = 41;
                if (this.Key != null)
                    hashCode = hashCode * 59 + this.Key.GetHashCode();
                if (this.IsChangeFlag != null)
                    hashCode = hashCode * 59 + this.IsChangeFlag.GetHashCode();
                if (this.TenderTypeCode != null)
                    hashCode = hashCode * 59 + this.TenderTypeCode.GetHashCode();
                if (this.TenderAccountNumber != null)
                    hashCode = hashCode * 59 + this.TenderAccountNumber.GetHashCode();
                if (this.ForeignCurrencyAmount != null)
                    hashCode = hashCode * 59 + this.ForeignCurrencyAmount.GetHashCode();
                if (this.ExchangeRate != null)
                    hashCode = hashCode * 59 + this.ExchangeRate.GetHashCode();
                if (this.TenderAmount != null)
                    hashCode = hashCode * 59 + this.TenderAmount.GetHashCode();
                if (this.TenderGroupCode != null)
                    hashCode = hashCode * 59 + this.TenderGroupCode.GetHashCode();
                if (this.TenderCount != null)
                    hashCode = hashCode * 59 + this.TenderCount.GetHashCode();
                if (this.TenderDescription != null)
                    hashCode = hashCode * 59 + this.TenderDescription.GetHashCode();
                if (this.CashbackFlag != null)
                    hashCode = hashCode * 59 + this.CashbackFlag.GetHashCode();
                if (this.ForeignISOCurrencyCode != null)
                    hashCode = hashCode * 59 + this.ForeignISOCurrencyCode.GetHashCode();
                if (this.ExchangeRateMultiplyFlag != null)
                    hashCode = hashCode * 59 + this.ExchangeRateMultiplyFlag.GetHashCode();
                if (this.CurrencySymbol != null)
                    hashCode = hashCode * 59 + this.CurrencySymbol.GetHashCode();
                if (this.TipAmount != null)
                    hashCode = hashCode * 59 + this.TipAmount.GetHashCode();
                if (this.TipForeignCurrencyAmount != null)
                    hashCode = hashCode * 59 + this.TipForeignCurrencyAmount.GetHashCode();
                if (this.Xxcustom08 != null)
                    hashCode = hashCode * 59 + this.Xxcustom08.GetHashCode();
                if (this.Xxcustom10 != null)
                    hashCode = hashCode * 59 + this.Xxcustom10.GetHashCode();
                if (this.Xxcustom09 != null)
                    hashCode = hashCode * 59 + this.Xxcustom09.GetHashCode();
                if (this.Xxcustom07 != null)
                    hashCode = hashCode * 59 + this.Xxcustom07.GetHashCode();
                if (this.Xxcustom05 != null)
                    hashCode = hashCode * 59 + this.Xxcustom05.GetHashCode();
                if (this.Xxcustom06 != null)
                    hashCode = hashCode * 59 + this.Xxcustom06.GetHashCode();
                if (this.Xxcustom11 != null)
                    hashCode = hashCode * 59 + this.Xxcustom11.GetHashCode();
                if (this.Xxcustom12 != null)
                    hashCode = hashCode * 59 + this.Xxcustom12.GetHashCode();
                if (this.Xxcustom13 != null)
                    hashCode = hashCode * 59 + this.Xxcustom13.GetHashCode();
                if (this.Xxcustom14 != null)
                    hashCode = hashCode * 59 + this.Xxcustom14.GetHashCode();
                if (this.Xxcustom15 != null)
                    hashCode = hashCode * 59 + this.Xxcustom15.GetHashCode();
                if (this.Xxcustom03 != null)
                    hashCode = hashCode * 59 + this.Xxcustom03.GetHashCode();
                if (this.CheckTenderLineItemList != null)
                    hashCode = hashCode * 59 + this.CheckTenderLineItemList.GetHashCode();
                if (this.Xxcustom02 != null)
                    hashCode = hashCode * 59 + this.Xxcustom02.GetHashCode();
                if (this.Xxcustom04 != null)
                    hashCode = hashCode * 59 + this.Xxcustom04.GetHashCode();
                if (this.Xxcustom01 != null)
                    hashCode = hashCode * 59 + this.Xxcustom01.GetHashCode();
                return hashCode;
            }
        }

        /// <summary>
        /// To validate all properties of the instance
        /// </summary>
        /// <param name="validationContext">Validation context</param>
        /// <returns>Validation Result</returns>
        IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
        {
            yield break;
        }
    }

}
