Parcelable representing more detailed information about a payment card.
Inherited Constant Summary
Field Summary
public static final Creator<CardInfo> | CREATOR |
Public Method Summary
UserAddress |
getBillingAddress()
Gets the billing address associated with buyer's payment card.
|
int |
getCardClass()
Gets the card class which can be either credit, debit or prepaid.
|
String |
getCardDescription()
Gets a user-facing message to describe the card selected for funding this
payment transaction.
|
String |
getCardDetails()
Gets the last four digits of the selected card.
|
String |
getCardNetwork()
Gets the card network of the selected card.
|
void |
writeToParcel(Parcel out, int
flags)
|
Inherited Method Summary
Fields
Public Methods
public UserAddress getBillingAddress ()
Gets the billing address associated with buyer's payment card.
Note this billing address will only be populated when billing address is set as
required through
CardRequirements.Builder.setBillingAddressRequired(boolean)
. Also, the
billing address' appearance depends on the optional setting in
CardRequirements.Builder.setBillingAddressFormat(int)
Returns
- the billing address if requested, or
null
otherwise.
public int getCardClass ()
Gets the card class which can be either credit, debit or prepaid. See WalletConstants.CardClass
for the expected card class values. This class should not be displayed
to the buyer, but can be used when the details of a buyer's card are needed. An example
would be selecting a processor that gives better interchange rates or applying a
discount depending on the card class.
Returns
WalletConstants.CardClass
of the buyer's selected card, but can be unknown if it can not be determined.
public String getCardDescription ()
Gets a user-facing message to describe the card selected for funding this payment transaction. You are required to show this to inform the buyer of their funding source. Please refer to the documentation for more information.
IMPORTANT: Do not attempt to parse the contents of this string as
the format, contents and length may change at any time. If you need finer grain
details, see getCardNetwork()
,
getCardDetails()
,
and getCardClass()
for stable card information.
Returns
- a user-facing message about the selected card used for payment.
public String getCardDetails ()
Gets the last four digits of the selected card. These details should not be displayed to the buyer, but can be used when the details of a buyer's card are needed. An example would be for customer support to help the buyer identify the card used for this transaction.
Returns
- the card details.
public String getCardNetwork ()
Gets the card network of the selected card. Card network has a finite set of values. This card network should not be displayed to the buyer, but can be used when the details of a buyer's card are needed. An example would be for customer support to help the buyer identify the card used for this transaction.
You can rely on the card network not changing once it is defined for a given card in a transaction (i.e. purchasing with a single Visa card will always return VISA).
Examples of currently expected values for elements returned are:
- VISA
- MASTERCARD
- DISCOVER
- AMEX
Returns
- the card network of the buyer's selected card.