Example #1
0
        public async Task <TransactionResult> MakeTransactionAsync(Buyer buyer, Order order, Card card, Language language, IRequestValidator <PaymentCommitRequest> validator, IPaymentCommitClient client)
        {
            var paymentRequest = requestBuilder.Build(buyer, order, card, wbpayIntegration, TransactionType.Purchase, language);

            return(await DoTransactionAsync(paymentRequest, language, validator, client));
        }
 protected TransactionResult DoTransaction(PaymentCommitRequest paymentRequest, Language language, IPaymentCommitClient paymentClient)
 {
     return(DoTransactionInternal(() => Task.FromResult(paymentClient.Send(paymentRequest)), paymentRequest, language, new PaymentCommitRequestValidator()).Result);
 }
 protected Task <TransactionResult> DoTransactionAsync(PaymentCommitRequest paymentRequest, Language language, IPaymentCommitClient paymentClient)
 {
     return(DoTransactionInternal(() => paymentClient.SendAsync(paymentRequest), paymentRequest, language, new PaymentCommitRequestValidator()));
 }
        public TransactionResult MakeTransaction(Buyer buyer, Order order, Card card, Language language, IRequestValidator <PaymentCommitRequest> validator, IPaymentCommitClient client)
        {
            var paymentRequest = requestBuilder.Build(buyer, order, card, wbpayIntegration, TransactionType.Authorize, language);

            return(DoTransaction(paymentRequest, language, validator, client));
        }