Class IsReadyToPayRequestJsonBuilder
-
- All Implemented Interfaces:
public class IsReadyToPayRequestJsonBuilderThis class provides methods to build com.google.android.gms.wallet.IsReadyToPayRequest in JSON format.
-
-
Constructor Summary
Constructors Constructor Description IsReadyToPayRequestJsonBuilder()
-
Method Summary
Modifier and Type Method Description IsReadyToPayRequestJsonBuildersetExistingPaymentMethodRequired(boolean existingPaymentMethodRequired)Optional. JSONObjecttoJson()Returns the com.google.android.gms.wallet.IsReadyToPayRequest as JSONObject. IsReadyToPayRequestJsonBuildersetAllowedPaymentMethods(@NonNull() JSONArray allowedPaymentMethods)Required. -
-
Method Detail
-
setExistingPaymentMethodRequired
IsReadyToPayRequestJsonBuilder setExistingPaymentMethodRequired(boolean existingPaymentMethodRequired)
Optional. Sets existing payment method required.
- Parameters:
existingPaymentMethodRequired- If set totrue, then theisReadyToPay()class method will return true if the current viewer is ready to pay with one or more payment methods specified in allowedPaymentMethods.- Returns:
a reference to this object.
-
toJson
@NonNull() JSONObject toJson()
Returns the com.google.android.gms.wallet.IsReadyToPayRequest as JSONObject.
- Returns:
the is ready to pay request JSON.
-
setAllowedPaymentMethods
IsReadyToPayRequestJsonBuilder setAllowedPaymentMethods(@NonNull() JSONArray allowedPaymentMethods)
Required. Sets one or more payment methods supported by the Google Pay API. See CardPaymentMethodJsonBuilder.
- Parameters:
allowedPaymentMethods- The allowed payment methods.- Returns:
a reference to this object.
-
-
-
-