Package com.adyen.model.checkout
Class Mandate
- java.lang.Object
-
- com.adyen.model.checkout.Mandate
-
public class Mandate extends Object
Mandate
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classMandate.AmountRuleEnumThe limitation rule of the billing amount.static classMandate.BillingAttemptsRuleEnumThe rule to specify the period, within which the recurring debit can happen, relative to the mandate recurring date.static classMandate.FrequencyEnumThe frequency with which a shopper should be charged.
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_AMOUNTstatic StringJSON_PROPERTY_AMOUNT_RULEstatic StringJSON_PROPERTY_BILLING_ATTEMPTS_RULEstatic StringJSON_PROPERTY_BILLING_DAYstatic StringJSON_PROPERTY_ENDS_ATstatic StringJSON_PROPERTY_FREQUENCYstatic StringJSON_PROPERTY_REMARKSstatic StringJSON_PROPERTY_STARTS_AT
-
Constructor Summary
Constructors Constructor Description Mandate()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Mandateamount(String amount)MandateamountRule(Mandate.AmountRuleEnum amountRule)MandatebillingAttemptsRule(Mandate.BillingAttemptsRuleEnum billingAttemptsRule)MandatebillingDay(String billingDay)MandateendsAt(String endsAt)booleanequals(Object o)Return true if this Mandate object is equal to o.Mandatefrequency(Mandate.FrequencyEnum frequency)static MandatefromJson(String jsonString)Create an instance of Mandate given an JSON stringStringgetAmount()The billing amount (in minor units) of the recurring transactions.Mandate.AmountRuleEnumgetAmountRule()The limitation rule of the billing amount.Mandate.BillingAttemptsRuleEnumgetBillingAttemptsRule()The rule to specify the period, within which the recurring debit can happen, relative to the mandate recurring date.StringgetBillingDay()The number of the day, on which the recurring debit can happen.StringgetEndsAt()End date of the billing plan, in YYYY-MM-DD format.Mandate.FrequencyEnumgetFrequency()The frequency with which a shopper should be charged.StringgetRemarks()The message shown by UPI to the shopper on the approval screen.StringgetStartsAt()Start date of the billing plan, in YYYY-MM-DD format.inthashCode()Mandateremarks(String remarks)voidsetAmount(String amount)The billing amount (in minor units) of the recurring transactions.voidsetAmountRule(Mandate.AmountRuleEnum amountRule)The limitation rule of the billing amount.voidsetBillingAttemptsRule(Mandate.BillingAttemptsRuleEnum billingAttemptsRule)The rule to specify the period, within which the recurring debit can happen, relative to the mandate recurring date.voidsetBillingDay(String billingDay)The number of the day, on which the recurring debit can happen.voidsetEndsAt(String endsAt)End date of the billing plan, in YYYY-MM-DD format.voidsetFrequency(Mandate.FrequencyEnum frequency)The frequency with which a shopper should be charged.voidsetRemarks(String remarks)The message shown by UPI to the shopper on the approval screen.voidsetStartsAt(String startsAt)Start date of the billing plan, in YYYY-MM-DD format.MandatestartsAt(String startsAt)StringtoJson()Convert an instance of Mandate to an JSON stringStringtoString()
-
-
-
Field Detail
-
JSON_PROPERTY_AMOUNT
public static final String JSON_PROPERTY_AMOUNT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_AMOUNT_RULE
public static final String JSON_PROPERTY_AMOUNT_RULE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_BILLING_ATTEMPTS_RULE
public static final String JSON_PROPERTY_BILLING_ATTEMPTS_RULE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_BILLING_DAY
public static final String JSON_PROPERTY_BILLING_DAY
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ENDS_AT
public static final String JSON_PROPERTY_ENDS_AT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_FREQUENCY
public static final String JSON_PROPERTY_FREQUENCY
- See Also:
- Constant Field Values
-
JSON_PROPERTY_REMARKS
public static final String JSON_PROPERTY_REMARKS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_STARTS_AT
public static final String JSON_PROPERTY_STARTS_AT
- See Also:
- Constant Field Values
-
-
Method Detail
-
getAmount
public String getAmount()
The billing amount (in minor units) of the recurring transactions.- Returns:
- amount
-
setAmount
public void setAmount(String amount)
The billing amount (in minor units) of the recurring transactions.- Parameters:
amount-
-
amountRule
public Mandate amountRule(Mandate.AmountRuleEnum amountRule)
-
getAmountRule
public Mandate.AmountRuleEnum getAmountRule()
The limitation rule of the billing amount. Possible values: * **max**: The transaction amount can not exceed the `amount`. * **exact**: The transaction amount should be the same as the `amount`.- Returns:
- amountRule
-
setAmountRule
public void setAmountRule(Mandate.AmountRuleEnum amountRule)
The limitation rule of the billing amount. Possible values: * **max**: The transaction amount can not exceed the `amount`. * **exact**: The transaction amount should be the same as the `amount`.- Parameters:
amountRule-
-
billingAttemptsRule
public Mandate billingAttemptsRule(Mandate.BillingAttemptsRuleEnum billingAttemptsRule)
-
getBillingAttemptsRule
public Mandate.BillingAttemptsRuleEnum getBillingAttemptsRule()
The rule to specify the period, within which the recurring debit can happen, relative to the mandate recurring date. Possible values: * **on**: On a specific date. * **before**: Before and on a specific date. * **after**: On and after a specific date.- Returns:
- billingAttemptsRule
-
setBillingAttemptsRule
public void setBillingAttemptsRule(Mandate.BillingAttemptsRuleEnum billingAttemptsRule)
The rule to specify the period, within which the recurring debit can happen, relative to the mandate recurring date. Possible values: * **on**: On a specific date. * **before**: Before and on a specific date. * **after**: On and after a specific date.- Parameters:
billingAttemptsRule-
-
getBillingDay
public String getBillingDay()
The number of the day, on which the recurring debit can happen. Should be within the same calendar month as the mandate recurring date. Possible values: 1-31 based on the `frequency`.- Returns:
- billingDay
-
setBillingDay
public void setBillingDay(String billingDay)
The number of the day, on which the recurring debit can happen. Should be within the same calendar month as the mandate recurring date. Possible values: 1-31 based on the `frequency`.- Parameters:
billingDay-
-
getEndsAt
public String getEndsAt()
End date of the billing plan, in YYYY-MM-DD format.- Returns:
- endsAt
-
setEndsAt
public void setEndsAt(String endsAt)
End date of the billing plan, in YYYY-MM-DD format.- Parameters:
endsAt-
-
frequency
public Mandate frequency(Mandate.FrequencyEnum frequency)
-
getFrequency
public Mandate.FrequencyEnum getFrequency()
The frequency with which a shopper should be charged. Possible values: **daily**, **weekly**, **biWeekly**, **monthly**, **quarterly**, **halfYearly**, **yearly**.- Returns:
- frequency
-
setFrequency
public void setFrequency(Mandate.FrequencyEnum frequency)
The frequency with which a shopper should be charged. Possible values: **daily**, **weekly**, **biWeekly**, **monthly**, **quarterly**, **halfYearly**, **yearly**.- Parameters:
frequency-
-
getRemarks
public String getRemarks()
The message shown by UPI to the shopper on the approval screen.- Returns:
- remarks
-
setRemarks
public void setRemarks(String remarks)
The message shown by UPI to the shopper on the approval screen.- Parameters:
remarks-
-
getStartsAt
public String getStartsAt()
Start date of the billing plan, in YYYY-MM-DD format. By default, the transaction date.- Returns:
- startsAt
-
setStartsAt
public void setStartsAt(String startsAt)
Start date of the billing plan, in YYYY-MM-DD format. By default, the transaction date.- Parameters:
startsAt-
-
equals
public boolean equals(Object o)
Return true if this Mandate object is equal to o.
-
fromJson
public static Mandate fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of Mandate given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Mandate
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to Mandate
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of Mandate to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-