Package com.mongodb.operation
Class UpdateOperation
java.lang.Object
com.mongodb.operation.BaseWriteOperation
com.mongodb.operation.UpdateOperation
- All Implemented Interfaces:
AsyncWriteOperation<WriteConcernResult>
,WriteOperation<WriteConcernResult>
Deprecated.
An operation that updates a document in a collection.
- Since:
- 3.0
-
Constructor Summary
ConstructorsConstructorDescriptionUpdateOperation
(MongoNamespace namespace, boolean ordered, WriteConcern writeConcern, boolean retryWrites, List<UpdateRequest> updates) Deprecated.Construct an instance.UpdateOperation
(MongoNamespace namespace, boolean ordered, WriteConcern writeConcern, List<UpdateRequest> updates) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.Gets the list of update requests.Methods inherited from class com.mongodb.operation.BaseWriteOperation
bypassDocumentValidation, execute, executeAsync, getBypassDocumentValidation, getNamespace, getWriteConcern, isOrdered
-
Constructor Details
-
UpdateOperation
@Deprecated public UpdateOperation(MongoNamespace namespace, boolean ordered, WriteConcern writeConcern, List<UpdateRequest> updates) Deprecated.Construct an instance.- Parameters:
namespace
- the database and collection namespace for the operation.ordered
- whether the updates are ordered.writeConcern
- the write concern for the operation.updates
- the update requests.
-
UpdateOperation
public UpdateOperation(MongoNamespace namespace, boolean ordered, WriteConcern writeConcern, boolean retryWrites, List<UpdateRequest> updates) Deprecated.Construct an instance.- Parameters:
namespace
- the database and collection namespace for the operation.ordered
- whether the updates are ordered.writeConcern
- the write concern for the operation.retryWrites
- if writes should be retried if they fail due to a network error.updates
- the update requests.- Since:
- 3.6
-
-
Method Details
-
getUpdateRequests
Deprecated.Gets the list of update requests.- Returns:
- the update requests
-
UpdateOperation(MongoNamespace, boolean, WriteConcern, boolean, List)
instead