public class ErrorMessage extends BaseFssApiResource
UTF_8| Modifier and Type | Method and Description |
|---|---|
static ErrorMessage |
create(FssApiVersion apiVersion,
FssApiError error,
java.lang.String description)
Returns a versioned ErrorMessage that is compatible with the specified apiVersion.
|
static ErrorMessage |
create(FssApiVersion apiVersion,
java.io.InputStreamReader reader)
Returns a versioned instance of ErrorMessage.
|
static ErrorMessage |
createLatest(FssApiError error,
java.lang.String description) |
java.lang.String |
getDescription()
Returns the description of the error.
|
FssApiError |
getError()
Returns the error that occurred.
|
static java.lang.Class<? extends ErrorMessage> |
getFssApiClass(FssApiVersion apiVersion)
Returns the
Class of the ErrorMessage that corresponds to the specified
apiVersion. |
java.lang.String |
toString()
The JSON representation of the specified object.
|
protected void |
validate(java.lang.String fieldName,
BaseFssApiResource parent)
Validates this object.
|
badValue, badValue, fromJson, toJson, toJson, validate, validateFieldInRange, validateFieldInRange, validateFieldIsNull, validateFieldNotNull, validateLocale, validateOptionalField, validateOptionalFieldList, validateRequiredField, validateRequiredFieldList, writeToOutputStreampublic static java.lang.Class<? extends ErrorMessage> getFssApiClass(FssApiVersion apiVersion)
Class of the ErrorMessage that corresponds to the specified
apiVersion.apiVersion - API version of the class to be returnedClass of the ErrorMessage that corresponds to the specified
apiVersionpublic static ErrorMessage create(FssApiVersion apiVersion, FssApiError error, java.lang.String description) throws AwUnsupportedApiVersionException
apiVersion - API version to be supported by the ErrorMessageerror - type of errordescription - description of the error. This can be null.AwUnsupportedApiVersionExceptionpublic static ErrorMessage createLatest(FssApiError error, java.lang.String description)
public FssApiError getError()
public java.lang.String getDescription()
public java.lang.String toString()
BaseFssApiResourcetoString in class BaseFssApiResourcepublic static ErrorMessage create(FssApiVersion apiVersion, java.io.InputStreamReader reader) throws AwJsonException, AwUnsupportedApiVersionException
apiVersion - API version of the HCP Anywhere FSS APIreader - AwJsonExceptionAwUnsupportedApiVersionExceptionprotected void validate(java.lang.String fieldName,
BaseFssApiResource parent)
throws AwJsonException
BaseFssApiResourceBaseFssApiResource.validateRequiredField(String, BaseFssApiResource, String) for foo, and
BaseFssApiResource.validateOptionalField(String, BaseFssApiResource) for bar.validate in class BaseFssApiResourcefieldName - name of this object in the parent (containing) object. If this object is a
top-level object (not contained within another object), then enter null for this
parameterparent - parent (containing) object that contains the object specified in the fieldName
parameter. If this object is a top-level object (not contained within another
object), then enter null for this parameterAwJsonException - if any validation errors occur