java.lang.Object
org.springframework.data.mongodb.core.query.Update
org.springframework.data.mongodb.core.query.BasicUpdate
- All Implemented Interfaces:
UpdateDefinition
- Author:
- Thomas Risberg, John Brisbin, Oliver Gierke, Christoph Strobl, Mark Paluch
-
Nested Class Summary
Nested classes/interfaces inherited from class org.springframework.data.mongodb.core.query.Update
Update.AddToSetBuilder, Update.BitwiseOperatorBuilder, Update.Modifier, Update.Modifiers, Update.Position, Update.PushOperatorBuilderNested classes/interfaces inherited from interface org.springframework.data.mongodb.core.query.UpdateDefinition
UpdateDefinition.ArrayFilter -
Constructor Summary
ConstructorsConstructorDescriptionBasicUpdate(String updateString) BasicUpdate(org.bson.Document updateObject) -
Method Summary
Modifier and TypeMethodDescriptionUpdate using the $addToSet update modifierorg.bson.DocumentUpdate using the $inc update modifierpop(String key, Update.Position pos) Update using the $pop update modifierUpdate using the $pull update modifierUpdate using the $pullAll update modifierUpdate using the $push update modifierUpdate using the $rename update modifierUpdate using the $set update modifierUpdate using the $unset update modifierMethods inherited from class org.springframework.data.mongodb.core.query.Update
addMultiFieldOperation, addToSet, bitwise, currentDate, currentTimestamp, equals, filterArray, filterArray, fromDocument, getArrayFilters, hasArrayFilters, hashCode, inc, isIsolated, isolated, max, min, modifies, multiply, push, setOnInsert, toString, update
-
Constructor Details
-
BasicUpdate
-
BasicUpdate
public BasicUpdate(org.bson.Document updateObject)
-
-
Method Details
-
set
Description copied from class:UpdateUpdate using the $set update modifier- Overrides:
setin classUpdate- Parameters:
key- the field name.value- can be null. In this case the property remains in the db with a null value. To remove it useUpdate.unset(String).- Returns:
- this.
- See Also:
-
unset
Description copied from class:UpdateUpdate using the $unset update modifier -
inc
Description copied from class:UpdateUpdate using the $inc update modifier -
push
Description copied from class:UpdateUpdate using the $push update modifier -
addToSet
Description copied from class:UpdateUpdate using the $addToSet update modifier -
pop
Description copied from class:UpdateUpdate using the $pop update modifier -
pull
Description copied from class:UpdateUpdate using the $pull update modifier -
pullAll
Description copied from class:UpdateUpdate using the $pullAll update modifier -
rename
Description copied from class:UpdateUpdate using the $rename update modifier -
getUpdateObject
public org.bson.Document getUpdateObject()- Specified by:
getUpdateObjectin interfaceUpdateDefinition- Overrides:
getUpdateObjectin classUpdate- Returns:
- the actual update in its native
Documentformat. Never null.
-