Class Operation
java.lang.Object
co.elastic.clients.elasticsearch.core.bulk.Operation
- All Implemented Interfaces:
JsonpSerializable,TaggedUnion<java.lang.Object>
@JsonpDeserializable public class Operation extends java.lang.Object implements TaggedUnion<java.lang.Object>, JsonpSerializable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classOperation.Builder -
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<Operation>_DESERIALIZERstatic java.lang.StringCREATEstatic java.lang.StringDELETEstatic java.lang.StringINDEXstatic java.lang.StringUPDATE -
Constructor Summary
Constructors Constructor Description Operation(OperationVariant value)Operation(ObjectBuilder<T> builder)Operation(java.util.function.Function<Operation.Builder,Operation.Builder> fn) -
Method Summary
Modifier and Type Method Description java.lang.Object_get()java.lang.String_type()Get the of the type of the variant held by this union object.CreateOperationcreate()Get thecreatevariant value.DeleteOperationdelete()Get thedeletevariant value.IndexOperationindex()Get theindexvariant value.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)protected static voidsetupOperationDeserializer(DelegatingDeserializer<Operation.Builder> op)UpdateOperationupdate()Get theupdatevariant value.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface co.elastic.clients.util.TaggedUnion
_is
-
Field Details
-
INDEX
public static final java.lang.String INDEX- See Also:
- Constant Field Values
-
CREATE
public static final java.lang.String CREATE- See Also:
- Constant Field Values
-
UPDATE
public static final java.lang.String UPDATE- See Also:
- Constant Field Values
-
DELETE
public static final java.lang.String DELETE- See Also:
- Constant Field Values
-
_DESERIALIZER
-
-
Constructor Details
-
Operation
-
Operation
-
Operation
-
-
Method Details
-
_type
public java.lang.String _type()Description copied from interface:TaggedUnionGet the of the type of the variant held by this union object.- Specified by:
_typein interfaceTaggedUnion<java.lang.Object>- Returns:
- the variant type
-
_get
public java.lang.Object _get()- Specified by:
_getin interfaceTaggedUnion<java.lang.Object>
-
index
Get theindexvariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theindexkind.
-
create
Get thecreatevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thecreatekind.
-
update
Get theupdatevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of theupdatekind.
-
delete
Get thedeletevariant value.- Throws:
java.lang.IllegalStateException- if the current variant is not of thedeletekind.
-
serialize
- Specified by:
serializein interfaceJsonpSerializable
-
setupOperationDeserializer
-