Interface PaymentProcess

All Known Implementing Classes:
BankTransferPayment, CardPayment

public interface PaymentProcess
Factory interface for creating Payment objects.
  • Method Details

    • createPayment

      Payment createPayment(BankAccount senderAccount, String description, BankAccount recipientAccount, Card card) throws Exception
      Creates a Payment object.
      Parameters:
      senderAccount - the bank account of the sender
      description - a description for the payment
      recipientAccount - the bank account of the recipient
      card - the card used for the payment
      Returns:
      the created Payment object
      Throws:
      Exception - if an error occurs during payment creation