Package co.arago.hiro.client.model
Class HiroError
- java.lang.Object
-
- co.arago.hiro.client.model.HiroJsonMap
-
- co.arago.hiro.client.model.HiroError
-
- All Implemented Interfaces:
JsonMessage,ToMap,java.io.Serializable
public class HiroError extends HiroJsonMap
Handles error responses from HIRO of the format.{ "error": { "message": "error message", "code": number } }or
{ "error": "error message" }- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classHiroError.HiroErrorEntry
-
Field Summary
Fields Modifier and Type Field Description HiroError.HiroErrorEntryerror-
Fields inherited from class co.arago.hiro.client.model.HiroJsonMap
fieldsMap
-
-
Constructor Summary
Constructors Constructor Description HiroError(java.lang.Object errorObj)Creates the intendedHiroError.HiroErrorEntryfrom either one of the two JSON data formats.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.IntegergetCode()java.lang.StringgetMessage()-
Methods inherited from class co.arago.hiro.client.model.HiroJsonMap
addFields, getField, getMap, getUnmappedField, setField, setFields, toMap
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface co.arago.hiro.client.model.JsonMessage
toJsonString, toJsonStringNoNull, toPrettyJsonString, toPrettyJsonStringNoNull
-
-
-
-
Field Detail
-
error
public HiroError.HiroErrorEntry error
-
-
Constructor Detail
-
HiroError
public HiroError(java.lang.Object errorObj)
Creates the intendedHiroError.HiroErrorEntryfrom either one of the two JSON data formats.- Parameters:
errorObj- The value for the key "error" in the source JSON. Must be either a Map or a String.- See Also:
HiroError
-
-