Class BulkWriteRequestBuilder<TDocument>
Represents a fluent builder for a write request (either a remove or an update).
public sealed class BulkWriteRequestBuilder<TDocument>
Type Parameters
TDocumentThe type of the document.
- Inheritance
-
BulkWriteRequestBuilder<TDocument>
- Inherited Members
- Extension Methods
Methods
Remove()
Adds a request to remove all matching documents to the bulk operation.
public void Remove()
RemoveOne()
Adds a request to remove one matching documents to the bulk operation.
public void RemoveOne()
ReplaceOne(TDocument)
Adds a request to replace one matching documents to the bulk operation.
public void ReplaceOne(TDocument document)
Parameters
documentTDocumentThe document.
Update(IMongoUpdate)
Adds a request to update all matching documents to the bulk operation.
public void Update(IMongoUpdate update)
Parameters
updateIMongoUpdateThe update.
UpdateOne(IMongoUpdate)
Adds a request to update one matching documents to the bulk operation.
public void UpdateOne(IMongoUpdate update)
Parameters
updateIMongoUpdateThe update.
Upsert()
Specifies that the request being built should be an upsert.
public BulkUpdateRequestBuilder<TDocument> Upsert()
Returns
- BulkUpdateRequestBuilder<TDocument>
A bulk update request builder.