Package com.adyen.model.balanceplatform
Class RestServiceError
- java.lang.Object
-
- com.adyen.model.balanceplatform.RestServiceError
-
public class RestServiceError extends Object
RestServiceError
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_DETAILstatic StringJSON_PROPERTY_ERROR_CODEstatic StringJSON_PROPERTY_INSTANCEstatic StringJSON_PROPERTY_INVALID_FIELDSstatic StringJSON_PROPERTY_REQUEST_IDstatic StringJSON_PROPERTY_RESPONSEstatic StringJSON_PROPERTY_STATUSstatic StringJSON_PROPERTY_TITLEstatic StringJSON_PROPERTY_TYPE
-
Constructor Summary
Constructors Constructor Description RestServiceError()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description RestServiceErroraddInvalidFieldsItem(InvalidField invalidFieldsItem)RestServiceErrordetail(String detail)booleanequals(Object o)Return true if this RestServiceError object is equal to 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<InvalidField>getInvalidFields()Detailed explanation of each validation error, when applicable.StringgetRequestId()A unique reference for the request, essentially the same as `pspReference`.ObjectgetResponse()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<InvalidField> invalidFields)RestServiceErrorrequestId(String requestId)RestServiceErrorresponse(Object response)voidsetDetail(String detail)A human-readable explanation specific to this occurrence of the problem.voidsetErrorCode(String errorCode)A code that identifies the problem type.voidsetInstance(String instance)A unique URI that identifies the specific occurrence of the problem.voidsetInvalidFields(List<InvalidField> invalidFields)Detailed explanation of each validation error, when applicable.voidsetRequestId(String requestId)A unique reference for the request, essentially the same as `pspReference`.voidsetResponse(Object response)responsevoidsetStatus(Integer status)The HTTP status code.voidsetTitle(String title)A short, human-readable summary of the problem type.voidsetType(String type)A URI that identifies the problem type, pointing to human-readable documentation on this problem type.RestServiceErrorstatus(Integer status)RestServiceErrortitle(String title)StringtoJson()Convert an instance of RestServiceError to an JSON stringStringtoString()RestServiceErrortype(String type)
-
-
-
Field Detail
-
JSON_PROPERTY_DETAIL
public static final String JSON_PROPERTY_DETAIL
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ERROR_CODE
public static final String JSON_PROPERTY_ERROR_CODE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_INSTANCE
public static final String JSON_PROPERTY_INSTANCE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_INVALID_FIELDS
public static final String JSON_PROPERTY_INVALID_FIELDS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_REQUEST_ID
public static final String JSON_PROPERTY_REQUEST_ID
- See Also:
- Constant Field Values
-
JSON_PROPERTY_RESPONSE
public static final String JSON_PROPERTY_RESPONSE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_STATUS
public static final String JSON_PROPERTY_STATUS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TITLE
public static final String JSON_PROPERTY_TITLE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TYPE
public static final String JSON_PROPERTY_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)
A human-readable explanation specific to this occurrence of the problem.- Parameters:
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)
A code that identifies the problem type.- Parameters:
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)
A unique URI that identifies the specific occurrence of the problem.- Parameters:
instance-
-
invalidFields
public RestServiceError invalidFields(List<InvalidField> invalidFields)
-
addInvalidFieldsItem
public RestServiceError addInvalidFieldsItem(InvalidField invalidFieldsItem)
-
getInvalidFields
public List<InvalidField> getInvalidFields()
Detailed explanation of each validation error, when applicable.- Returns:
- invalidFields
-
setInvalidFields
public void setInvalidFields(List<InvalidField> invalidFields)
Detailed explanation of each validation error, when applicable.- Parameters:
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)
A unique reference for the request, essentially the same as `pspReference`.- Parameters:
requestId-
-
response
public RestServiceError response(Object response)
-
getResponse
public Object getResponse()
Get response- Returns:
- response
-
setResponse
public void setResponse(Object response)
response- Parameters:
response-
-
status
public RestServiceError status(Integer status)
-
getStatus
public Integer getStatus()
The HTTP status code.- Returns:
- status
-
setStatus
public void setStatus(Integer status)
The HTTP status code.- Parameters:
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)
A short, human-readable summary of the problem type.- Parameters:
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)
A URI that identifies the problem type, pointing to human-readable documentation on this problem type.- Parameters:
type-
-
equals
public boolean equals(Object o)
Return true if this RestServiceError object is equal to o.
-
fromJson
public static RestServiceError fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of RestServiceError given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of RestServiceError
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to RestServiceError
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of RestServiceError to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-