public abstract class ResponseWithErrorCode extends Object
Modifier and Type | Field and Description |
---|---|
protected String |
description
The error description.
|
protected String |
errorCode
The error code.
|
protected int |
httpStatusCode
The HTTP status code.
|
protected String |
referenceId
The error reference id.
|
Constructor and Description |
---|
ResponseWithErrorCode(int httpStatusCode,
String errorCode,
String description)
Constructor for a response with a HTTP status code.
|
Modifier and Type | Method and Description |
---|---|
io.vavr.control.Option<String> |
getDescription()
Get optional description.
|
String |
getErrorCode()
The error code.
|
int |
getHttpStatusCode()
The HTTP status code.
|
String |
getReferenceId()
The error reference id.
|
protected final int httpStatusCode
@Expose @SerializedName(value="error") protected final String errorCode
@Expose @SerializedName(value="referenceId") protected final String referenceId
public ResponseWithErrorCode(int httpStatusCode, @Nonnull String errorCode, @Nullable String description)
httpStatusCode
- The HTTP status code.errorCode
- The error code.description
- The optional error description.@Nonnull public io.vavr.control.Option<String> getDescription()
public int getHttpStatusCode()
public String getErrorCode()
public String getReferenceId()
Copyright © 2020 SAP SE. All rights reserved.