Class IndexResult
java.lang.Object
co.elastic.clients.elasticsearch.watcher.IndexResult
- All Implemented Interfaces:
JsonpSerializable,TaggedUnion<IndexResult.Kind,Object>
@JsonpDeserializable
public class IndexResult
extends Object
implements TaggedUnion<IndexResult.Kind,Object>, JsonpSerializable
The result of an index action. It is a container that holds either the
response of an executed index operation, or the
request that would have run when the action is simulated.- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal Object_get()final IndexResult.Kind_kind()Get the of the kind of variant held by this object.booleanIs this variant instance of kindrequest?booleanIs this variant instance of kindresponse?static IndexResultrequest()Get therequestvariant value.response()Get theresponsevariant value.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static voidtoString()
-
Field Details
-
_DESERIALIZER
-
-
Constructor Details
-
IndexResult
-
-
Method Details
-
_kind
Description copied from interface:TaggedUnionGet the of the kind of variant held by this object.- Specified by:
_kindin interfaceTaggedUnion<IndexResult.Kind,Object> - Returns:
- the variant kind
-
_get
- Specified by:
_getin interfaceTaggedUnion<IndexResult.Kind,Object>
-
of
-
isResponse
public boolean isResponse()Is this variant instance of kindresponse? -
response
Get theresponsevariant value.- Throws:
IllegalStateException- if the current variant is not of theresponsekind.
-
isRequest
public boolean isRequest()Is this variant instance of kindrequest? -
request
Get therequestvariant value.- Throws:
IllegalStateException- if the current variant is not of therequestkind.
-
serialize
- Specified by:
serializein interfaceJsonpSerializable
-
toString
-
setupIndexResultDeserializer
-