Payment module types

OrderService depends on the PaymentGateway contract; card and wallet gateways implement it.

Payment module types OrderService depends on the PaymentGateway contract; card and wallet gateways implement it. OrderService · Creates orders and starts payment · Class OrderService -gatewayPaymentGateway +createOrder(cart: Cart)Order +checkout(order: Order)Receipt PaymentGateway · Payment contract every channel fulfils · Interface «interface» PaymentGateway +pay(amount: Money)Result Order · Order identity, amount, and status · Class Order +idOrderId +amountMoney +statusOrderStatus +markPaid()void CardGateway · Charges a bank card · Class CardGateway +pay(amount: Money)Result WalletGateway · Debits a stored wallet balance · Class WalletGateway +pay(amount: Money)Result pays through creates Legend Depends on Implements