Class GiftcardFields
- java.lang.Object
-
- com.cheetahdigital.corekit.rest.params.BaseParams
-
- com.cheetahdigital.giftcards.core.api.GiftcardFields
-
- All Implemented Interfaces:
android.os.Parcelable
public class GiftcardFields extends BaseParams
Class for setting the field parameters of Giftcards API. AllNullable
parameters means you can remove the parameter by passing anull
value.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GiftcardFields.Builder
Builder class forGiftcardFields
-
Nested classes/interfaces inherited from class com.cheetahdigital.corekit.rest.params.BaseParams
BaseParams.BaseBuilder<T extends BaseParams,B extends BaseParams.BaseBuilder>
-
-
Field Summary
Fields Modifier and Type Field Description static android.os.Parcelable.Creator<GiftcardFields>
CREATOR
-
Fields inherited from class com.cheetahdigital.corekit.rest.params.BaseParams
mId, mQueryMap
-
-
Constructor Summary
Constructors Constructor Description GiftcardFields()
GiftcardFields(android.os.Parcel source)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Float
getAmount()
Returns the amount to use for purchasejava.lang.String
getGiftcardClass()
Returns the internal name of the gift card class used for purchasejava.lang.String
getPaymentMethodNonce()
Returns the payment method nonce from Braintreejava.lang.String
getPin()
Returns the PIN of gift cardjava.lang.String
getReloadAmount()
Returns the amount to add during auto-reloadjava.lang.String
getReloadThreshold()
Returns the amount threshold to trigger auto-reloadjava.lang.Boolean
isAutoReload()
Returns the status of auto-reloadvoid
setAmount(java.lang.Float amount)
Set the amount to use for purchase.void
setGiftcardClass(java.lang.String giftcardClass)
Set the gift card class to be used for purchasevoid
setIsAutoReload(java.lang.Boolean isAutoReload)
Set the flag to indicate if auto-reload is on or offvoid
setPaymentMethodNonce(java.lang.String paymentMethodNonce)
Set the payment method nonce from Braintreevoid
setPin(java.lang.String pin)
Set the PIN of gift cardvoid
setReloadAmount(java.lang.String reloadAmount)
Set the amount to add during auto-reloadvoid
setReloadThreshold(java.lang.String reloadThreshold)
Sets the amount threshold to trigger auto-reload-
Methods inherited from class com.cheetahdigital.corekit.rest.params.BaseParams
addParam, describeContents, getAccessToken, getId, getParam, getQueryMap, setAccessToken, setId, writeToParcel
-
-
-
-
Field Detail
-
CREATOR
public static final android.os.Parcelable.Creator<GiftcardFields> CREATOR
-
-
Method Detail
-
setIsAutoReload
public void setIsAutoReload(@Nullable java.lang.Boolean isAutoReload)
Set the flag to indicate if auto-reload is on or off- Parameters:
isAutoReload
-true
to turn on auto reload
-
isAutoReload
@Nullable public java.lang.Boolean isAutoReload()
Returns the status of auto-reload- Returns:
- status of auto-reload
-
getPaymentMethodNonce
@Nullable public java.lang.String getPaymentMethodNonce()
Returns the payment method nonce from Braintree- Returns:
- payment method nonce from Braintree
-
setPaymentMethodNonce
public void setPaymentMethodNonce(@Nullable java.lang.String paymentMethodNonce)
Set the payment method nonce from Braintree- Parameters:
paymentMethodNonce
- payment method nonce from Braintree
-
getAmount
@Nullable public java.lang.Float getAmount()
Returns the amount to use for purchase- Returns:
- value store in
GiftcardApiConstants.AMOUNT
-
setAmount
public void setAmount(@Nullable java.lang.Float amount)
Set the amount to use for purchase. Use this when reloading a gift cardGiftcardsAPI.reloadGiftcard(GiftcardParams, GiftcardFields, ListenerModel)
- Parameters:
amount
- amount to use for purchase
-
getPin
@Nullable public java.lang.String getPin()
Returns the PIN of gift card- Returns:
- value store in
GiftcardApiConstants.PIN
-
setPin
public void setPin(@Nullable java.lang.String pin)
Set the PIN of gift card- Parameters:
pin
- text for pin
-
getReloadThreshold
@Nullable public java.lang.String getReloadThreshold()
Returns the amount threshold to trigger auto-reload- Returns:
- amount threshold to trigger auto-reload
-
setReloadThreshold
public void setReloadThreshold(@Nullable java.lang.String reloadThreshold)
Sets the amount threshold to trigger auto-reload- Parameters:
reloadThreshold
- amount threshold to trigger auto-reload
-
getReloadAmount
@Nullable public java.lang.String getReloadAmount()
Returns the amount to add during auto-reload- Returns:
- amount to add during auto-reload
-
setReloadAmount
public void setReloadAmount(@Nullable java.lang.String reloadAmount)
Set the amount to add during auto-reload- Parameters:
reloadAmount
- amount to add during auto-reload
-
setGiftcardClass
public void setGiftcardClass(java.lang.String giftcardClass)
Set the gift card class to be used for purchase- Parameters:
giftcardClass
- internal name of the giftcard class
-
getGiftcardClass
public java.lang.String getGiftcardClass()
Returns the internal name of the gift card class used for purchase- Returns:
- internal name of the gift card class
-
-