All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.gu.memsub.PaymentMethod.scala Maven / Gradle / Ivy

There is a newer version: 0.605
Show newest version
package com.gu.memsub

case class PaymentCardDetails(lastFourDigits: String, expiryMonth: Int, expiryYear: Int)

sealed trait PaymentMethod {
  val numConsecutiveFailures: Option[Int]
  val paymentMethodStatus: Option[String]
}
case class PaymentCard(
  isReferenceTransaction: Boolean,
  cardType: Option[String],
  paymentCardDetails: Option[PaymentCardDetails],
  numConsecutiveFailures: Option[Int] = None,
  paymentMethodStatus: Option[String] = None
) extends PaymentMethod

case class PayPalMethod(
  email : String,
  numConsecutiveFailures: Option[Int] = None,
  paymentMethodStatus: Option[String] = None
) extends PaymentMethod

case class GoCardless(
  mandateId: String,
  accountName: String,
  accountNumber: String,
  sortCode: String,
  numConsecutiveFailures: Option[Int] = None,
  paymentMethodStatus: Option[String] = None
) extends PaymentMethod




© 2015 - 2024 Weber Informatics LLC | Privacy Policy