/// <summary>
 /// Initializes a new instance of the <see cref="PaymentRequest" /> class.
 /// </summary>
 /// <param name="Capture">Capture.</param>
 /// <param name="AmountDetail">AmountDetail (required).</param>
 /// <param name="Solution">Solution.</param>
 /// <param name="PaymentInstrument">PaymentInstrument (required).</param>
 /// <param name="BillTo">BillTo.</param>
 /// <param name="ShipTo">ShipTo.</param>
 /// <param name="CustomerIp">CustomerIp.</param>
 /// <param name="Order">Order.</param>
 /// <param name="Tax">Tax.</param>
 /// <param name="Duty">Duty.</param>
 /// <param name="Shipping">Shipping.</param>
 /// <param name="LineItems">LineItems.</param>
 public PaymentRequest(bool?Capture = null, AmountDetail AmountDetail = null, Solution Solution = null, PaymentInstrument PaymentInstrument = null, BaseAddress BillTo = null, BaseAddress ShipTo = null, string CustomerIp = null, Order Order = null, ExtendedAmount Tax = null, ExtendedAmount Duty = null, ExtendedAmount Shipping = null, List <LineItem> LineItems = null)
 {
     // to ensure "AmountDetail" is required (not null)
     if (AmountDetail == null)
     {
         throw new InvalidDataException("AmountDetail is a required property for PaymentRequest and cannot be null");
     }
     else
     {
         this.AmountDetail = AmountDetail;
     }
     // to ensure "PaymentInstrument" is required (not null)
     if (PaymentInstrument == null)
     {
         throw new InvalidDataException("PaymentInstrument is a required property for PaymentRequest and cannot be null");
     }
     else
     {
         this.PaymentInstrument = PaymentInstrument;
     }
     this.Capture    = Capture;
     this.Solution   = Solution;
     this.BillTo     = BillTo;
     this.ShipTo     = ShipTo;
     this.CustomerIp = CustomerIp;
     this.Order      = Order;
     this.Tax        = Tax;
     this.Duty       = Duty;
     this.Shipping   = Shipping;
     this.LineItems  = LineItems;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="Payment" /> class.
 /// </summary>
 /// <param name="Links">Links.</param>
 /// <param name="Id">Id.</param>
 /// <param name="Solution">Solution.</param>
 /// <param name="Batch">Batch.</param>
 /// <param name="SubmitTimeUTC">SubmitTimeUTC.</param>
 /// <param name="SubmitTimeLocal">SubmitTimeLocal.</param>
 /// <param name="TransactionStatus">TransactionStatus.</param>
 /// <param name="Processor">Processor.</param>
 /// <param name="RecurringBilling">RecurringBilling.</param>
 /// <param name="CustomerIp">CustomerIp.</param>
 /// <param name="Order">Order.</param>
 /// <param name="AuthAmount">AuthAmount.</param>
 /// <param name="SettleAmount">SettleAmount.</param>
 /// <param name="Tax">Tax.</param>
 /// <param name="Shipping">Shipping.</param>
 /// <param name="Duty">Duty.</param>
 /// <param name="LineItems">LineItems.</param>
 /// <param name="TaxExempt">TaxExempt.</param>
 /// <param name="PaymentInstrument">PaymentInstrument.</param>
 /// <param name="FraudInformation">FraudInformation.</param>
 /// <param name="CustomerId">CustomerId.</param>
 /// <param name="BillTo">BillTo.</param>
 /// <param name="ShipTo">ShipTo.</param>
 public Payment(PaymentLinks Links = null, string Id = null, Solution Solution = null, Batch Batch = null, string SubmitTimeUTC = null, string SubmitTimeLocal = null, string TransactionStatus = null, Processor Processor = null, bool?RecurringBilling = null, string CustomerIp = null, Order Order = null, string AuthAmount = null, string SettleAmount = null, ExtendedAmount Tax = null, ExtendedAmount Shipping = null, ExtendedAmount Duty = null, List <LineItem> LineItems = null, bool?TaxExempt = null, PaymentInstrument PaymentInstrument = null, FraudInformation FraudInformation = null, string CustomerId = null, BaseAddress BillTo = null, BaseAddress ShipTo = null)
 {
     this.Links             = Links;
     this.Id                = Id;
     this.Solution          = Solution;
     this.Batch             = Batch;
     this.SubmitTimeUTC     = SubmitTimeUTC;
     this.SubmitTimeLocal   = SubmitTimeLocal;
     this.TransactionStatus = TransactionStatus;
     this.Processor         = Processor;
     this.RecurringBilling  = RecurringBilling;
     this.CustomerIp        = CustomerIp;
     this.Order             = Order;
     this.AuthAmount        = AuthAmount;
     this.SettleAmount      = SettleAmount;
     this.Tax               = Tax;
     this.Shipping          = Shipping;
     this.Duty              = Duty;
     this.LineItems         = LineItems;
     this.TaxExempt         = TaxExempt;
     this.PaymentInstrument = PaymentInstrument;
     this.FraudInformation  = FraudInformation;
     this.CustomerId        = CustomerId;
     this.BillTo            = BillTo;
     this.ShipTo            = ShipTo;
 }
Esempio n. 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="RefundRequest" /> class.
 /// </summary>
 /// <param name="Amount">Amount (required).</param>
 /// <param name="Order">Order.</param>
 /// <param name="LineItems">LineItems.</param>
 /// <param name="Tax">Tax.</param>
 /// <param name="Shipping">Shipping.</param>
 /// <param name="Duty">Duty.</param>
 /// <param name="PaymentInstrument">PaymentInstrument (required).</param>
 /// <param name="BillTo">BillTo.</param>
 /// <param name="ShipTo">ShipTo.</param>
 public RefundRequest(string Amount = null, Order Order = null, List <LineItem> LineItems = null, ExtendedAmount Tax = null, ExtendedAmount Shipping = null, ExtendedAmount Duty = null, PaymentInstrument PaymentInstrument = null, BaseAddress BillTo = null, BaseAddress ShipTo = null)
 {
     // to ensure "Amount" is required (not null)
     if (Amount == null)
     {
         throw new InvalidDataException("Amount is a required property for RefundRequest and cannot be null");
     }
     else
     {
         this.Amount = Amount;
     }
     // to ensure "PaymentInstrument" is required (not null)
     if (PaymentInstrument == null)
     {
         throw new InvalidDataException("PaymentInstrument is a required property for RefundRequest and cannot be null");
     }
     else
     {
         this.PaymentInstrument = PaymentInstrument;
     }
     this.Order     = Order;
     this.LineItems = LineItems;
     this.Tax       = Tax;
     this.Shipping  = Shipping;
     this.Duty      = Duty;
     this.BillTo    = BillTo;
     this.ShipTo    = ShipTo;
 }