Module spring.data.mongodb
Interface ReactiveUpdateOperation.TerminatingUpdate<T>
- All Superinterfaces:
ReactiveUpdateOperation.FindAndModifyWithOptions<T>,ReactiveUpdateOperation.TerminatingFindAndModify<T>
- Enclosing interface:
- ReactiveUpdateOperation
public static interface ReactiveUpdateOperation.TerminatingUpdate<T>
extends ReactiveUpdateOperation.TerminatingFindAndModify<T>, ReactiveUpdateOperation.FindAndModifyWithOptions<T>
Compose update execution by calling one of the terminating methods.
-
Method Summary
Modifier and TypeMethodDescriptionMono<com.mongodb.client.result.UpdateResult>all()Update all matching documents in the collection.Mono<com.mongodb.client.result.UpdateResult>first()Update the first document in the collection.Mono<com.mongodb.client.result.UpdateResult>upsert()Creates a new document if no documents match the filter query or updates the matching ones.Methods inherited from interface org.springframework.data.mongodb.core.ReactiveUpdateOperation.FindAndModifyWithOptions
withOptionsMethods inherited from interface org.springframework.data.mongodb.core.ReactiveUpdateOperation.TerminatingFindAndModify
findAndModify
-
Method Details
-
all
Mono<com.mongodb.client.result.UpdateResult> all()Update all matching documents in the collection.- Returns:
- never null.
-
first
Mono<com.mongodb.client.result.UpdateResult> first()Update the first document in the collection.- Returns:
- never null.
-
upsert
Mono<com.mongodb.client.result.UpdateResult> upsert()Creates a new document if no documents match the filter query or updates the matching ones.- Returns:
- never null.
-