Package | Description |
---|---|
com.mongodb.async.client |
This packages contains classes for the new async client
|
com.mongodb.client |
This package contains client interfaces
|
com.mongodb.client.model |
This package contains models and options that help describe MongoCollection operations
|
Modifier and Type | Method and Description |
---|---|
void |
MongoCollection.findOneAndUpdate(Bson filter,
Bson update,
FindOneAndUpdateOptions options,
SingleResultCallback<TDocument> callback)
Atomically find a document and update it.
|
Modifier and Type | Method and Description |
---|---|
TDocument |
MongoCollection.findOneAndUpdate(Bson filter,
Bson update,
FindOneAndUpdateOptions options)
Atomically find a document and update it.
|
Modifier and Type | Method and Description |
---|---|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.bypassDocumentValidation(Boolean bypassDocumentValidation)
Sets the bypass document level validation flag.
|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.maxTime(long maxTime,
TimeUnit timeUnit)
Sets the maximum execution time on the server for this operation.
|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.projection(Bson projection)
Sets a document describing the fields to return for all matching documents.
|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.returnDocument(ReturnDocument returnDocument)
Set whether to return the document before it was updated / inserted or after
|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.sort(Bson sort)
Sets the sort criteria to apply to the query.
|
FindOneAndUpdateOptions |
FindOneAndUpdateOptions.upsert(boolean upsert)
Set to true if a new document should be inserted if there are no matches to the query filter.
|
Copyright © 2016. All Rights Reserved.