public abstract class PaymentCard extends PaymentMethod
PaymentCard
is used to charge the cost of goods or services to an account, belonging to the party
identified on the card. A PaymentCard
which has a line of credit is a CreditCard
. A
DebitCard
is a PaymentCard
where the associated account is debited immediately. An example for a
DebitCard
is an EC-card or MaestroCard. Other forms of PaymentCard
s such as prepaid cards or charge
cards are not implemented at the moment.Constructor and Description |
---|
PaymentCard(String cardName,
String cardAssociationName,
String cardNumber,
String nameOnCard,
String billingAddress,
LocalDateTime validFrom,
LocalDateTime expiryDate,
String cardVerificationCode)
Instantiates a
PaymentCard . |
Modifier and Type | Method and Description |
---|---|
protected boolean |
canEqual(Object other) |
boolean |
equals(Object o) |
String |
getBillingAddress()
The billing address registered with this card.
|
String |
getCardAssociationName()
The name of the card association.
|
String |
getCardNumber()
The number uniquely identifying this payment card.
|
String |
getCardVerificationCode()
The verification code of this card.
|
LocalDateTime |
getExpiryDate()
The date on which the card expires.
|
String |
getNameOnCard()
The name of the party to which the card was issued to.
|
LocalDateTime |
getValidFrom()
The date from which on the card is valid.
|
int |
hashCode() |
String |
toString() |
public PaymentCard(String cardName, String cardAssociationName, String cardNumber, String nameOnCard, String billingAddress, LocalDateTime validFrom, LocalDateTime expiryDate, String cardVerificationCode)
PaymentCard
.cardName
- specific name of this card, e.g. VISA, or MasterCardcardAssociationName
- the name of the association which issued the cardcardNumber
- the number of this cardnameOnCard
- name of the card ownerbillingAddress
- the address to which account statements are sentvalidFrom
- date from which the card is validexpiryDate
- date on which the card expirescardVerificationCode
- verification code printed on the card or a PINpublic String toString()
toString
in class PaymentMethod
@Generated(value="lombok") public String getCardAssociationName()
@Generated(value="lombok") public String getCardNumber()
@Generated(value="lombok") public String getNameOnCard()
@Generated(value="lombok") public String getBillingAddress()
@Generated(value="lombok") public LocalDateTime getValidFrom()
@Generated(value="lombok") public LocalDateTime getExpiryDate()
@Generated(value="lombok") public String getCardVerificationCode()
@Generated(value="lombok") public boolean equals(Object o)
equals
in class PaymentMethod
@Generated(value="lombok") protected boolean canEqual(Object other)
canEqual
in class PaymentMethod
@Generated(value="lombok") public int hashCode()
hashCode
in class PaymentMethod
Copyright © 2018 Pivotal Software, Inc.. All rights reserved.