Package com.adyen.model.management
Class Currency
- java.lang.Object
-
- com.adyen.model.management.Currency
-
public class Currency extends Object
Currency
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCurrency.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>openapiFieldsstatic HashSet<String>openapiRequiredFieldsstatic StringSERIALIZED_NAME_AMOUNTstatic StringSERIALIZED_NAME_CURRENCY_CODEstatic StringSERIALIZED_NAME_PERCENTAGE
-
Constructor Summary
Constructors Constructor Description Currency()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Currencyamount(Integer amount)CurrencycurrencyCode(String currencyCode)booleanequals(Object o)static CurrencyfromJson(String jsonString)Create an instance of Currency given an JSON stringIntegergetAmount()Surcharge amount per transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes).StringgetCurrencyCode()Three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes).ObjectgetPercentage()Get percentageinthashCode()Currencypercentage(Object percentage)voidsetAmount(Integer amount)voidsetCurrencyCode(String currencyCode)voidsetPercentage(Object percentage)StringtoJson()Convert an instance of Currency to an JSON stringStringtoString()static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj)Validates the JSON Object and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_AMOUNT
public static final String SERIALIZED_NAME_AMOUNT
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_CURRENCY_CODE
public static final String SERIALIZED_NAME_CURRENCY_CODE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_PERCENTAGE
public static final String SERIALIZED_NAME_PERCENTAGE
- See Also:
- Constant Field Values
-
-
Method Detail
-
getAmount
public Integer getAmount()
Surcharge amount per transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes).- Returns:
- amount
-
setAmount
public void setAmount(Integer amount)
-
getCurrencyCode
public String getCurrencyCode()
Three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes). For example, **AUD**.- Returns:
- currencyCode
-
setCurrencyCode
public void setCurrencyCode(String currencyCode)
-
getPercentage
public Object getPercentage()
Get percentage- Returns:
- percentage
-
setPercentage
public void setPercentage(Object percentage)
-
validateJsonObject
public static void validateJsonObject(com.google.gson.JsonObject jsonObj) throws IOExceptionValidates the JSON Object and throws an exception if issues found- Parameters:
jsonObj- JSON Object- Throws:
IOException- if the JSON Object is invalid with respect to Currency
-
fromJson
public static Currency fromJson(String jsonString) throws IOException
Create an instance of Currency given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Currency
- Throws:
IOException- if the JSON string is invalid with respect to Currency
-
toJson
public String toJson()
Convert an instance of Currency to an JSON string- Returns:
- JSON string
-
-