@Immutable public final class ThingErrorResponse extends org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse> implements ThingCommandResponse<ThingErrorResponse>, org.eclipse.ditto.signals.commands.base.ErrorResponse<ThingErrorResponse>
ThingCommand which wraps the exception thrown while processing the command.ThingCommandResponse.JsonFieldsorg.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelector, org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelectorAndPredicate<T>, org.eclipse.ditto.model.base.json.Jsonifiable.WithPointer<J extends org.eclipse.ditto.json.JsonValue>, org.eclipse.ditto.model.base.json.Jsonifiable.WithPredicate<J extends org.eclipse.ditto.json.JsonValue,T>| Modifier and Type | Field and Description |
|---|---|
static String |
TYPE
Type of this response.
|
TYPE_PREFIX| Modifier and Type | Method and Description |
|---|---|
protected void |
appendPayload(org.eclipse.ditto.json.JsonObjectBuilder jsonObjectBuilder,
org.eclipse.ditto.model.base.json.JsonSchemaVersion schemaVersion,
Predicate<org.eclipse.ditto.json.JsonField> thePredicate) |
protected boolean |
canEqual(Object other) |
boolean |
equals(Object o) |
static ThingErrorResponse |
fromJson(org.eclipse.ditto.json.JsonObject jsonObject,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonObject. |
static ThingErrorResponse |
fromJson(String jsonString,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonString. |
static ThingErrorResponse |
fromJson(ThingErrorRegistry thingErrorRegistry,
org.eclipse.ditto.json.JsonObject jsonObject,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonObject using a special ThingErrorRegistry. |
static ThingErrorResponse |
fromJson(ThingErrorRegistry thingErrorRegistry,
String jsonString,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonString using a special ThingErrorRegistry. |
org.eclipse.ditto.model.base.exceptions.DittoRuntimeException |
getDittoRuntimeException() |
org.eclipse.ditto.json.JsonPointer |
getResourcePath() |
String |
getThingId() |
int |
hashCode() |
static ThingErrorResponse |
of(org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException)
Creates a new
ThingErrorResponse for the specified dittoRuntimeException. |
static ThingErrorResponse |
of(org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse for the specified dittoRuntimeException. |
static ThingErrorResponse |
of(String thingId,
org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException)
Creates a new
ThingErrorResponse for the specified dittoRuntimeException. |
static ThingErrorResponse |
of(String thingId,
org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException,
org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
Creates a new
ThingErrorResponse for the specified dittoRuntimeException. |
ThingErrorResponse |
setDittoHeaders(org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders) |
String |
toString() |
getDittoHeaders, getManifest, getStatusCode, getType, toJsonclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetId, getResourceTypegetImplementedSchemaVersion, getStatusCode, getStatusCodeValue, toJson, toJsontoJson, toJsonString, toJsonStringgetLatestSchemaVersion, getSupportedSchemaVersions, implementsSchemaVersion, implementsSchemaVersion, toJsonStringpublic static final String TYPE
public static ThingErrorResponse of(org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException)
ThingErrorResponse for the specified dittoRuntimeException.dittoRuntimeException - the exception.NullPointerException - if one of the arguments is null.public static ThingErrorResponse of(String thingId, org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException)
ThingErrorResponse for the specified dittoRuntimeException.thingId - the Thing ID which was related to the exception.dittoRuntimeException - the exception.NullPointerException - if one of the arguments is null.public static ThingErrorResponse of(org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse for the specified dittoRuntimeException.dittoRuntimeException - the exception.dittoHeaders - the headers of the command which caused the exception.NullPointerException - if one of the arguments is null.public static ThingErrorResponse of(String thingId, org.eclipse.ditto.model.base.exceptions.DittoRuntimeException dittoRuntimeException, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse for the specified dittoRuntimeException.thingId - the Thing's ID.dittoRuntimeException - the exception.dittoHeaders - the headers of the command which caused the exception.NullPointerException - if one of the arguments is null.public static ThingErrorResponse fromJson(String jsonString, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonString.jsonString - the JSON string representation of the causing DittoRuntimeException.dittoHeaders - the DittoHeaders to use.public static ThingErrorResponse fromJson(ThingErrorRegistry thingErrorRegistry, String jsonString, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonString using a special ThingErrorRegistry.thingErrorRegistry - the special ThingErrorRegistry to use for deserializing the
DittoRuntimeException.jsonString - the JSON string representation of the causing DittoRuntimeException.dittoHeaders - the DittoHeaders to use.public static ThingErrorResponse fromJson(org.eclipse.ditto.json.JsonObject jsonObject, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonObject.jsonObject - the JSON representation of the causing DittoRuntimeException.dittoHeaders - the DittoHeaders to use.public static ThingErrorResponse fromJson(ThingErrorRegistry thingErrorRegistry, org.eclipse.ditto.json.JsonObject jsonObject, org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
ThingErrorResponse containing the causing DittoRuntimeException which is deserialized
from the passed jsonObject using a special ThingErrorRegistry.thingErrorRegistry - the special ThingErrorRegistry to use for deserializing the
DittoRuntimeException.jsonObject - the JSON representation of the causing DittoRuntimeException.dittoHeaders - the DittoHeaders to use.public String getThingId()
getThingId in interface org.eclipse.ditto.signals.base.WithThingIdpublic org.eclipse.ditto.model.base.exceptions.DittoRuntimeException getDittoRuntimeException()
getDittoRuntimeException in interface org.eclipse.ditto.signals.commands.base.ErrorResponse<ThingErrorResponse>public org.eclipse.ditto.json.JsonPointer getResourcePath()
getResourcePath in interface org.eclipse.ditto.signals.base.WithResourceprotected void appendPayload(org.eclipse.ditto.json.JsonObjectBuilder jsonObjectBuilder,
org.eclipse.ditto.model.base.json.JsonSchemaVersion schemaVersion,
Predicate<org.eclipse.ditto.json.JsonField> thePredicate)
appendPayload in class org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse>public ThingErrorResponse setDittoHeaders(org.eclipse.ditto.model.base.headers.DittoHeaders dittoHeaders)
setDittoHeaders in interface org.eclipse.ditto.model.base.headers.WithDittoHeaders<ThingErrorResponse>setDittoHeaders in interface org.eclipse.ditto.signals.commands.base.CommandResponse<ThingErrorResponse>setDittoHeaders in interface org.eclipse.ditto.signals.commands.base.ErrorResponse<ThingErrorResponse>setDittoHeaders in interface ThingCommandResponse<ThingErrorResponse>public int hashCode()
hashCode in class org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse>public boolean equals(@Nullable Object o)
equals in class org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse>protected boolean canEqual(@Nullable Object other)
canEqual in class org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse>public String toString()
toString in class org.eclipse.ditto.signals.commands.base.AbstractCommandResponse<ThingErrorResponse>Copyright © 2017–2018 Eclipse Foundation. All rights reserved.