Package com.adyen.model.management
Class Key
- java.lang.Object
-
- com.adyen.model.management.Key
-
public class Key extends Object
Key
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_IDENTIFIERstatic StringJSON_PROPERTY_PASSPHRASEstatic StringJSON_PROPERTY_VERSION
-
Constructor Summary
Constructors Constructor Description Key()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Return true if this Key object is equal to o.static KeyfromJson(String jsonString)Create an instance of Key given an JSON stringMap<String,Object>getExplicitNulls()Returns a map of properties to be merged into the JSON payload as explicit null values.StringgetIdentifier()The unique identifier of the shared key.StringgetPassphrase()The secure passphrase to protect the shared key.IntegergetVersion()The version number of the shared key.inthashCode()Keyidentifier(String identifier)The unique identifier of the shared key.KeyincludeNullValues(boolean includeNullValues)Configures whether null values are explicitly serialized in the JSON payload.booleanisIncludeNullValues()Returns whether null values are explicitly serialized in the JSON payload.Keypassphrase(String passphrase)The secure passphrase to protect the shared key.voidsetIdentifier(String identifier)The unique identifier of the shared key.voidsetIncludeNullValues(boolean includeNullValues)Sets whether null values should be explicitly serialized in the JSON payload.voidsetPassphrase(String passphrase)The secure passphrase to protect the shared key.voidsetVersion(Integer version)The version number of the shared key.StringtoJson()Convert an instance of Key to an JSON stringStringtoString()Keyversion(Integer version)The version number of the shared key.
-
-
-
Field Detail
-
JSON_PROPERTY_IDENTIFIER
public static final String JSON_PROPERTY_IDENTIFIER
- See Also:
- Constant Field Values
-
JSON_PROPERTY_PASSPHRASE
public static final String JSON_PROPERTY_PASSPHRASE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_VERSION
public static final String JSON_PROPERTY_VERSION
- See Also:
- Constant Field Values
-
-
Method Detail
-
identifier
public Key identifier(String identifier)
The unique identifier of the shared key.- Parameters:
identifier- The unique identifier of the shared key.- Returns:
- the current
Keyinstance, allowing for method chaining
-
getIdentifier
public String getIdentifier()
The unique identifier of the shared key.- Returns:
- identifier The unique identifier of the shared key.
-
setIdentifier
public void setIdentifier(String identifier)
The unique identifier of the shared key.- Parameters:
identifier- The unique identifier of the shared key.
-
passphrase
public Key passphrase(String passphrase)
The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.- Parameters:
passphrase- The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.- Returns:
- the current
Keyinstance, allowing for method chaining
-
getPassphrase
public String getPassphrase()
The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.- Returns:
- passphrase The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.
-
setPassphrase
public void setPassphrase(String passphrase)
The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.- Parameters:
passphrase- The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `!`, `@`, `#`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`.
-
version
public Key version(Integer version)
The version number of the shared key.- Parameters:
version- The version number of the shared key.- Returns:
- the current
Keyinstance, allowing for method chaining
-
getVersion
public Integer getVersion()
The version number of the shared key.- Returns:
- version The version number of the shared key.
-
setVersion
public void setVersion(Integer version)
The version number of the shared key.- Parameters:
version- The version number of the shared key.
-
includeNullValues
public Key includeNullValues(boolean includeNullValues)
Configures whether null values are explicitly serialized in the JSON payload. Default is false.
-
isIncludeNullValues
public boolean isIncludeNullValues()
Returns whether null values are explicitly serialized in the JSON payload.
-
setIncludeNullValues
public void setIncludeNullValues(boolean includeNullValues)
Sets whether null values should be explicitly serialized in the JSON payload. Default is false.
-
equals
public boolean equals(Object o)
Return true if this Key object is equal to o.
-
getExplicitNulls
public Map<String,Object> getExplicitNulls()
Returns a map of properties to be merged into the JSON payload as explicit null values.
-
fromJson
public static Key fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of Key given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Key
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to Key
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of Key to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-