Package com.adyen.model.management
Class RestServiceError
- java.lang.Object
-
- com.adyen.model.management.RestServiceError
-
public class RestServiceError extends Object
RestServiceError
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classRestServiceError.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>openapiFieldsstatic HashSet<String>openapiRequiredFieldsstatic StringSERIALIZED_NAME_DETAILstatic StringSERIALIZED_NAME_ERROR_CODEstatic StringSERIALIZED_NAME_INSTANCEstatic StringSERIALIZED_NAME_INVALID_FIELDSstatic StringSERIALIZED_NAME_REQUEST_IDstatic StringSERIALIZED_NAME_RESPONSEstatic StringSERIALIZED_NAME_STATUSstatic StringSERIALIZED_NAME_TITLEstatic StringSERIALIZED_NAME_TYPE
-
Constructor Summary
Constructors Constructor Description RestServiceError()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description RestServiceErroraddInvalidFieldsItem(InvalidFieldWrapper invalidFieldsItem)RestServiceErrordetail(String detail)booleanequals(Object o)RestServiceErrorerrorCode(String errorCode)static RestServiceErrorfromJson(String jsonString)Create an instance of RestServiceError given an JSON stringStringgetDetail()A human-readable explanation specific to this occurrence of the problem.StringgetErrorCode()A code that identifies the problem type.StringgetInstance()A unique URI that identifies the specific occurrence of the problem.List<InvalidFieldWrapper>getInvalidFields()Detailed explanation of each validation error, when applicable.StringgetRequestId()A unique reference for the request, essentially the same as `pspReference`.JSONObjectgetResponse()Get responseIntegergetStatus()The HTTP status code.StringgetTitle()A short, human-readable summary of the problem type.StringgetType()A URI that identifies the problem type, pointing to human-readable documentation on this problem type.inthashCode()RestServiceErrorinstance(String instance)RestServiceErrorinvalidFields(List<InvalidFieldWrapper> invalidFields)RestServiceErrorrequestId(String requestId)RestServiceErrorresponse(JSONObject response)voidsetDetail(String detail)voidsetErrorCode(String errorCode)voidsetInstance(String instance)voidsetInvalidFields(List<InvalidFieldWrapper> invalidFields)voidsetRequestId(String requestId)voidsetResponse(JSONObject response)voidsetStatus(Integer status)voidsetTitle(String title)voidsetType(String type)RestServiceErrorstatus(Integer status)RestServiceErrortitle(String title)StringtoJson()Convert an instance of RestServiceError to an JSON stringStringtoString()RestServiceErrortype(String type)static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj)Validates the JSON Object and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_DETAIL
public static final String SERIALIZED_NAME_DETAIL
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ERROR_CODE
public static final String SERIALIZED_NAME_ERROR_CODE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_INSTANCE
public static final String SERIALIZED_NAME_INSTANCE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_INVALID_FIELDS
public static final String SERIALIZED_NAME_INVALID_FIELDS
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_REQUEST_ID
public static final String SERIALIZED_NAME_REQUEST_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_RESPONSE
public static final String SERIALIZED_NAME_RESPONSE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_STATUS
public static final String SERIALIZED_NAME_STATUS
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TITLE
public static final String SERIALIZED_NAME_TITLE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TYPE
public static final String SERIALIZED_NAME_TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
detail
public RestServiceError detail(String detail)
-
getDetail
public String getDetail()
A human-readable explanation specific to this occurrence of the problem.- Returns:
- detail
-
setDetail
public void setDetail(String detail)
-
errorCode
public RestServiceError errorCode(String errorCode)
-
getErrorCode
public String getErrorCode()
A code that identifies the problem type.- Returns:
- errorCode
-
setErrorCode
public void setErrorCode(String errorCode)
-
instance
public RestServiceError instance(String instance)
-
getInstance
public String getInstance()
A unique URI that identifies the specific occurrence of the problem.- Returns:
- instance
-
setInstance
public void setInstance(String instance)
-
invalidFields
public RestServiceError invalidFields(List<InvalidFieldWrapper> invalidFields)
-
addInvalidFieldsItem
public RestServiceError addInvalidFieldsItem(InvalidFieldWrapper invalidFieldsItem)
-
getInvalidFields
public List<InvalidFieldWrapper> getInvalidFields()
Detailed explanation of each validation error, when applicable.- Returns:
- invalidFields
-
setInvalidFields
public void setInvalidFields(List<InvalidFieldWrapper> invalidFields)
-
requestId
public RestServiceError requestId(String requestId)
-
getRequestId
public String getRequestId()
A unique reference for the request, essentially the same as `pspReference`.- Returns:
- requestId
-
setRequestId
public void setRequestId(String requestId)
-
response
public RestServiceError response(JSONObject response)
-
getResponse
public JSONObject getResponse()
Get response- Returns:
- response
-
setResponse
public void setResponse(JSONObject response)
-
status
public RestServiceError status(Integer status)
-
getStatus
public Integer getStatus()
The HTTP status code.- Returns:
- status
-
setStatus
public void setStatus(Integer status)
-
title
public RestServiceError title(String title)
-
getTitle
public String getTitle()
A short, human-readable summary of the problem type.- Returns:
- title
-
setTitle
public void setTitle(String title)
-
type
public RestServiceError type(String type)
-
getType
public String getType()
A URI that identifies the problem type, pointing to human-readable documentation on this problem type.- Returns:
- type
-
setType
public void setType(String type)
-
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 RestServiceError
-
fromJson
public static RestServiceError fromJson(String jsonString) throws IOException
Create an instance of RestServiceError given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of RestServiceError
- Throws:
IOException- if the JSON string is invalid with respect to RestServiceError
-
toJson
public String toJson()
Convert an instance of RestServiceError to an JSON string- Returns:
- JSON string
-
-