Package com.hazelcast.jet.mongodb
Enum Class WriteMode
- All Implemented Interfaces:
Serializable
,Comparable<WriteMode>
,Constable
Defines allowed operations.
- Since:
- 5.3
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionItems will be inserted to MongoDB; in case of ID clash, error will be thrown.Performs replace.Performs update.Performs update. -
Method Summary
-
Enum Constant Details
-
INSERT_ONLY
Items will be inserted to MongoDB; in case of ID clash, error will be thrown. -
UPDATE_ONLY
Performs update. Entity with the given_id
must already exist, otherwise an error will be thrown. -
UPSERT
Performs update. If the entity with the given_id
does not exist, it will be created. -
REPLACE
Performs replace. If the entity with the given_id
does not exist, it will be created (if it was not overridden by the user).Replace is different from UPSERT in handling of missing fields. Replace will set them to null, while upsert won't affect such fields in the entity.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-