Package com.adyen.model.balanceplatform
Class Address
- java.lang.Object
-
- com.adyen.model.balanceplatform.Address
-
public class Address extends Object
Address
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAddress.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>openapiFieldsstatic HashSet<String>openapiRequiredFieldsstatic StringSERIALIZED_NAME_CITYstatic StringSERIALIZED_NAME_COUNTRYstatic StringSERIALIZED_NAME_HOUSE_NUMBER_OR_NAMEstatic StringSERIALIZED_NAME_POSTAL_CODEstatic StringSERIALIZED_NAME_STATE_OR_PROVINCEstatic StringSERIALIZED_NAME_STREET
-
Constructor Summary
Constructors Constructor Description Address()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Addresscity(String city)Addresscountry(String country)booleanequals(Object o)static AddressfromJson(String jsonString)Create an instance of Address given an JSON stringStringgetCity()The name of the city.StringgetCountry()The two-character ISO-3166-1 alpha-2 country code.StringgetHouseNumberOrName()The number or name of the house.StringgetPostalCode()A maximum of five digits for an address in the US, or a maximum of ten characters for an address in all other countries.StringgetStateOrProvince()The two-character ISO 3166-2 state or province code.StringgetStreet()The name of the street.inthashCode()AddresshouseNumberOrName(String houseNumberOrName)AddresspostalCode(String postalCode)voidsetCity(String city)voidsetCountry(String country)voidsetHouseNumberOrName(String houseNumberOrName)voidsetPostalCode(String postalCode)voidsetStateOrProvince(String stateOrProvince)voidsetStreet(String street)AddressstateOrProvince(String stateOrProvince)Addressstreet(String street)StringtoJson()Convert an instance of Address to an JSON stringStringtoString()static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj)static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj, boolean strictValidation)Validates the JSON Object and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_CITY
public static final String SERIALIZED_NAME_CITY
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_COUNTRY
public static final String SERIALIZED_NAME_COUNTRY
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_HOUSE_NUMBER_OR_NAME
public static final String SERIALIZED_NAME_HOUSE_NUMBER_OR_NAME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_POSTAL_CODE
public static final String SERIALIZED_NAME_POSTAL_CODE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_STATE_OR_PROVINCE
public static final String SERIALIZED_NAME_STATE_OR_PROVINCE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_STREET
public static final String SERIALIZED_NAME_STREET
- See Also:
- Constant Field Values
-
-
Method Detail
-
getCity
public String getCity()
The name of the city. Maximum length: 3000 characters.- Returns:
- city
-
setCity
public void setCity(String city)
-
getCountry
public String getCountry()
The two-character ISO-3166-1 alpha-2 country code. For example, **US**. > If you don't know the country or are not collecting the country from the shopper, provide `country` as `ZZ`.- Returns:
- country
-
setCountry
public void setCountry(String country)
-
getHouseNumberOrName
public String getHouseNumberOrName()
The number or name of the house. Maximum length: 3000 characters.- Returns:
- houseNumberOrName
-
setHouseNumberOrName
public void setHouseNumberOrName(String houseNumberOrName)
-
getPostalCode
public String getPostalCode()
A maximum of five digits for an address in the US, or a maximum of ten characters for an address in all other countries.- Returns:
- postalCode
-
setPostalCode
public void setPostalCode(String postalCode)
-
getStateOrProvince
public String getStateOrProvince()
The two-character ISO 3166-2 state or province code. For example, **CA** in the US or **ON** in Canada. > Required for the US and Canada.- Returns:
- stateOrProvince
-
setStateOrProvince
public void setStateOrProvince(String stateOrProvince)
-
getStreet
public String getStreet()
The name of the street. Maximum length: 3000 characters. > The house number should not be included in this field; it should be separately provided via `houseNumberOrName`.- Returns:
- street
-
setStreet
public void setStreet(String street)
-
validateJsonObject
public static void validateJsonObject(com.google.gson.JsonObject jsonObj) throws IOException- Throws:
IOException
-
validateJsonObject
public static void validateJsonObject(com.google.gson.JsonObject jsonObj, boolean strictValidation) throws IOExceptionValidates the JSON Object and throws an exception if issues found- Parameters:
jsonObj- JSON ObjectstrictValidation- reject (new) fields missing from the specifications- Throws:
IOException- if the JSON Object is invalid with respect to Address
-
fromJson
public static Address fromJson(String jsonString) throws IOException
Create an instance of Address given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Address
- Throws:
IOException- if the JSON string is invalid with respect to Address
-
toJson
public String toJson()
Convert an instance of Address to an JSON string- Returns:
- JSON string
-
-