public class PurchaseInfo
extends java.lang.Object
implements android.os.Parcelable
Modifier and Type | Class and Description |
---|---|
static interface |
PurchaseInfo.Currency
Constant helper values for different currency codes (e.g.
|
static class |
PurchaseInfo.PurchaseInfoBuilder
Builder to create a
PurchaseInfo object. |
static interface |
PurchaseInfo.UserReviewAction
Constant helper values for different user review actions (e.g.
|
Modifier and Type | Field and Description |
---|---|
static android.os.Parcelable.Creator<PurchaseInfo> |
CREATOR |
static java.lang.String |
CURRENCY |
static java.lang.String |
CURRENCY_FORMAT |
static java.lang.String |
CUSTOM_DATA |
static java.lang.String |
CUSTOM_DESCRIPTION |
static java.lang.String |
DISCOUNT |
static java.lang.String |
ENABLE_USER_DATA_PREFILL |
static java.lang.String |
GIFT_WRAP_CHARGES |
static java.lang.String |
MISCELLANEOUS_CHARGES |
static java.lang.String |
ORDER_ID |
static java.lang.String |
PROMO_CODE |
static java.lang.String |
REFERENCE_CALL_ID |
static java.lang.String |
REQUEST_ID |
static java.lang.String |
REVIEW_ACTION |
static java.lang.String |
REVIEW_MESSAGE |
static java.lang.String |
SHIPPING_AND_HANDLING_CHARGES |
static java.lang.String |
SHIPPING_REQUIRED |
static java.lang.String |
SOURCE_ID |
static java.lang.String |
SUB_TOTAL |
static java.lang.String |
TAX |
static java.lang.String |
THREE_DS_ACTIVE |
static java.lang.String |
THREE_DS_SUPPRESS_CHALLENGE |
static java.lang.String |
TOTAL |
Constructor and Description |
---|
PurchaseInfo(org.json.JSONObject json)
Construct a PurchaseInfo object from JSON.
|
Modifier and Type | Method and Description |
---|---|
int |
describeContents() |
java.lang.Object |
get(java.lang.String name)
Retrieve a PurchaseInfo property by key.
|
java.lang.String |
getCurrency()
The currency being used to make the purchase.
|
java.lang.String |
getCurrencyFormat()
A string that specifies the display format for a currency amount associated with the Pay button.
|
java.util.HashMap<java.lang.String,java.lang.String> |
getCustomData()
Add any custom key/value pairs if needed.
|
java.lang.String |
getDescription()
Get the description that is associated with a payment.
|
java.math.BigDecimal |
getDiscount()
Get the total for the discounts that are related to the payment.
|
java.math.BigDecimal |
getGiftWrap()
Get the total gift-wrapping charges that is included in the payment.
|
java.lang.String |
getMerchantRequestId()
Get the Merchant's ID that is associated with the request.
|
java.math.BigDecimal |
getMisc()
Get the total uncategorized charges that are included in the payment.
|
java.lang.String |
getOrderId()
A custom value you may use to identify the purchase.
|
java.lang.String |
getPromoCode()
A promotional code entered by the user to make this purchase.
|
java.lang.String |
getReferenceCallId()
This value should be set if a successful
VisaPaymentSummary was
received AND you need to modify the purchase by invoking the Visa Checkout SDK again for the same purchase. |
java.lang.String |
getReviewMessage()
Get your message to display on the Review page.
|
java.math.BigDecimal |
getShippingHandling()
Get the total amount for the shipping and handling charges
that is included in the payment.
|
java.lang.String |
getSourceId()
A custom value you may use to identify this user.
|
java.math.BigDecimal |
getSubTotal()
Get the subtotal amount that is included in the payment.
|
java.math.BigDecimal |
getTax()
Get the total amount for the tax-related charges that
is included in the payment.
|
ThreeDSSetup |
getThreeDSSetup()
Get one or more name-value pairs that you can use to set up
Verified by Visa properties with Visa Checkout.
|
java.math.BigDecimal |
getTotal()
Get the total amount of the payment
|
java.lang.String |
getUserReviewAction()
Get the button label in the Visa Checkout lightbox
|
boolean |
isEnableUserDataPrefill()
Whether the user data prefill event handler is active for this transaction.
|
boolean |
isShippingAddressRequired()
Determines whether you require a shipping address from your customers.
|
void |
writeToParcel(android.os.Parcel out,
int flags) |
public static final java.lang.String TOTAL
public static final java.lang.String CURRENCY
public static final java.lang.String SUB_TOTAL
public static final java.lang.String SHIPPING_AND_HANDLING_CHARGES
public static final java.lang.String TAX
public static final java.lang.String DISCOUNT
public static final java.lang.String GIFT_WRAP_CHARGES
public static final java.lang.String MISCELLANEOUS_CHARGES
public static final java.lang.String CUSTOM_DESCRIPTION
public static final java.lang.String ORDER_ID
public static final java.lang.String REVIEW_MESSAGE
public static final java.lang.String REQUEST_ID
public static final java.lang.String SOURCE_ID
public static final java.lang.String PROMO_CODE
public static final java.lang.String SHIPPING_REQUIRED
public static final java.lang.String REVIEW_ACTION
public static final java.lang.String CUSTOM_DATA
public static final java.lang.String REFERENCE_CALL_ID
public static final java.lang.String THREE_DS_ACTIVE
public static final java.lang.String THREE_DS_SUPPRESS_CHALLENGE
public static final java.lang.String ENABLE_USER_DATA_PREFILL
public static final java.lang.String CURRENCY_FORMAT
public static final android.os.Parcelable.Creator<PurchaseInfo> CREATOR
public PurchaseInfo(org.json.JSONObject json)
PurchaseInfo.PurchaseInfoBuilder
.json
- the json object to construct frompublic java.lang.Object get(java.lang.String name)
name
- the key to retrieve.public java.math.BigDecimal getTotal()
public java.lang.String getCurrency()
public java.math.BigDecimal getSubTotal()
public java.math.BigDecimal getShippingHandling()
public ThreeDSSetup getThreeDSSetup()
public java.math.BigDecimal getTax()
public java.math.BigDecimal getDiscount()
public java.math.BigDecimal getGiftWrap()
public java.math.BigDecimal getMisc()
public java.lang.String getDescription()
public java.lang.String getOrderId()
public java.lang.String getReviewMessage()
public java.lang.String getMerchantRequestId()
public java.lang.String getSourceId()
public java.lang.String getPromoCode()
public boolean isShippingAddressRequired()
public java.lang.String getUserReviewAction()
public java.util.HashMap<java.lang.String,java.lang.String> getCustomData()
public java.lang.String getReferenceCallId()
VisaPaymentSummary
was
received AND you need to modify the purchase by invoking the Visa Checkout SDK again for the same purchase.
For instance, if the user successfully completes the Visa Checkout process,
VisaPaymentSummary.getCallId()
will be populated with a string that represents this purchase.
If, then, you need to make adjustments to the exact same purchase, you must be sure to set
this value to the one obtained from VisaPaymentSummary.getCallId()
before the user attempts to
checkout again.public int describeContents()
describeContents
in interface android.os.Parcelable
public boolean isEnableUserDataPrefill()
public java.lang.String getCurrencyFormat()
public void writeToParcel(android.os.Parcel out, int flags)
writeToParcel
in interface android.os.Parcelable