Class IMongoCollectionExtensions
| MongoDB CSharp Driver API Reference (original) (raw)
Namespace
MongoDB.Driver
Assembly
MongoDB.Driver.dll
public static class IMongoCollectionExtensions
Inheritance
IMongoCollectionExtensions
Inherited Members
Methods
Aggregate(IMongoCollection, AggregateOptions)
Begins a fluent aggregation interface.
Aggregate(IMongoCollection, IClientSessionHandle, AggregateOptions)
Begins a fluent aggregation interface.
AsQueryable(IMongoCollection, AggregateOptions)
Creates a queryable source of documents.
AsQueryable(IMongoCollection, IClientSessionHandle, AggregateOptions)
Creates a queryable source of documents.
CountAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection.
CountAsync(IMongoCollection, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection.
CountDocumentsAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection. For a fast estimate of the total documents in a collection see EstimatedDocumentCountAsync(EstimatedDocumentCountOptions, CancellationToken).
CountDocumentsAsync(IMongoCollection, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection. For a fast estimate of the total documents in a collection see EstimatedDocumentCountAsync(EstimatedDocumentCountOptions, CancellationToken).
CountDocuments(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection. For a fast estimate of the total documents in a collection see EstimatedDocumentCount(EstimatedDocumentCountOptions, CancellationToken).
CountDocuments(IMongoCollection, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection. For a fast estimate of the total documents in a collection see EstimatedDocumentCount(EstimatedDocumentCountOptions, CancellationToken).
Count(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection.
Count(IMongoCollection, Expression<Func<TDocument, bool>>, CountOptions, CancellationToken)
Counts the number of documents in the collection.
DeleteManyAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes multiple documents.
DeleteManyAsync(IMongoCollection, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes multiple documents.
DeleteManyAsync(IMongoCollection, Expression<Func<TDocument, bool>>, CancellationToken)
Deletes multiple documents.
DeleteMany(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes multiple documents.
DeleteMany(IMongoCollection, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes multiple documents.
DeleteMany(IMongoCollection, Expression<Func<TDocument, bool>>, CancellationToken)
Deletes multiple documents.
DeleteOneAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes a single document.
DeleteOneAsync(IMongoCollection, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes a single document.
DeleteOneAsync(IMongoCollection, Expression<Func<TDocument, bool>>, CancellationToken)
Deletes a single document.
DeleteOne(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes a single document.
DeleteOne(IMongoCollection, Expression<Func<TDocument, bool>>, DeleteOptions, CancellationToken)
Deletes a single document.
DeleteOne(IMongoCollection, Expression<Func<TDocument, bool>>, CancellationToken)
Deletes a single document.
DistinctAsync<TDocument, TField>(IMongoCollection, FieldDefinition<TDocument, TField>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctAsync<TDocument, TField>(IMongoCollection, IClientSessionHandle, FieldDefinition<TDocument, TField>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctAsync<TDocument, TField>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, TField>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctAsync<TDocument, TField>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, TField>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctAsync<TDocument, TField>(IMongoCollection, Expression<Func<TDocument, TField>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctAsync<TDocument, TField>(IMongoCollection, Expression<Func<TDocument, TField>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, FieldDefinition<TDocument, IEnumerable>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, IClientSessionHandle, FieldDefinition<TDocument, IEnumerable>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, IEnumerable>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, IEnumerable>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, Expression<Func<TDocument, IEnumerable>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctManyAsync<TDocument, TItem>(IMongoCollection, Expression<Func<TDocument, IEnumerable>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, FieldDefinition<TDocument, IEnumerable>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, IClientSessionHandle, FieldDefinition<TDocument, IEnumerable>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, IEnumerable>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, IEnumerable>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, Expression<Func<TDocument, IEnumerable>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
DistinctMany<TDocument, TItem>(IMongoCollection, Expression<Func<TDocument, IEnumerable>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified array field.
Distinct<TDocument, TField>(IMongoCollection, FieldDefinition<TDocument, TField>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
Distinct<TDocument, TField>(IMongoCollection, IClientSessionHandle, FieldDefinition<TDocument, TField>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
Distinct<TDocument, TField>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, TField>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
Distinct<TDocument, TField>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, TField>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
Distinct<TDocument, TField>(IMongoCollection, Expression<Func<TDocument, TField>>, FilterDefinition, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
Distinct<TDocument, TField>(IMongoCollection, Expression<Func<TDocument, TField>>, Expression<Func<TDocument, bool>>, DistinctOptions, CancellationToken)
Gets the distinct values for a specified field.
FindAsync(IMongoCollection, FilterDefinition, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindAsync(IMongoCollection, IClientSessionHandle, FilterDefinition, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindAsync(IMongoCollection, Expression<Func<TDocument, bool>>, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindOneAndDeleteAsync(IMongoCollection, FilterDefinition, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDeleteAsync(IMongoCollection, IClientSessionHandle, FilterDefinition, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDeleteAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDeleteAsync(IMongoCollection, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDeleteAsync<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDeleteAsync<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete(IMongoCollection, FilterDefinition, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete(IMongoCollection, IClientSessionHandle, FilterDefinition, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete(IMongoCollection, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndDelete<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, FindOneAndDeleteOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and deletes it atomically.
FindOneAndReplaceAsync(IMongoCollection, FilterDefinition, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplaceAsync(IMongoCollection, IClientSessionHandle, FilterDefinition, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplaceAsync(IMongoCollection, Expression<Func<TDocument, bool>>, IClientSessionHandle, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplaceAsync(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplaceAsync<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplaceAsync<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace(IMongoCollection, FilterDefinition, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace(IMongoCollection, IClientSessionHandle, FilterDefinition, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndReplace<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, FindOneAndReplaceOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and replaces it atomically.
FindOneAndUpdateAsync(IMongoCollection, FilterDefinition, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdateAsync(IMongoCollection, IClientSessionHandle, FilterDefinition, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdateAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdateAsync(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdateAsync<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdateAsync<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate(IMongoCollection, FilterDefinition, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate(IMongoCollection, IClientSessionHandle, FilterDefinition, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TDocument>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate<TDocument, TProjection>(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and updates it atomically.
FindOneAndUpdate<TDocument, TProjection>(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, FindOneAndUpdateOptions<TDocument, TProjection>, CancellationToken)
Finds a single document and updates it atomically.
FindSync(IMongoCollection, FilterDefinition, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindSync(IMongoCollection, IClientSessionHandle, FilterDefinition, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindSync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
FindSync(IMongoCollection, Expression<Func<TDocument, bool>>, FindOptions<TDocument, TDocument>, CancellationToken)
Finds the documents matching the filter.
Find(IMongoCollection, FilterDefinition, FindOptions)
Begins a fluent find interface.
Find(IMongoCollection, IClientSessionHandle, FilterDefinition, FindOptions)
Begins a fluent find interface.
Find(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, FindOptions)
Begins a fluent find interface.
Find(IMongoCollection, Expression<Func<TDocument, bool>>, FindOptions)
Begins a fluent find interface.
ReplaceOneAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, ReplaceOptions, CancellationToken)
Replaces a single document.
ReplaceOneAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, UpdateOptions, CancellationToken)
Replaces a single document.
ReplaceOneAsync(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, ReplaceOptions, CancellationToken)
Replaces a single document.
ReplaceOneAsync(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, UpdateOptions, CancellationToken)
Replaces a single document.
ReplaceOne(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, ReplaceOptions, CancellationToken)
Replaces a single document.
ReplaceOne(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, TDocument, UpdateOptions, CancellationToken)
Replaces a single document.
ReplaceOne(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, ReplaceOptions, CancellationToken)
Replaces a single document.
ReplaceOne(IMongoCollection, Expression<Func<TDocument, bool>>, TDocument, UpdateOptions, CancellationToken)
Replaces a single document.
UpdateManyAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates many documents.
UpdateManyAsync(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates many documents.
UpdateMany(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates many documents.
UpdateMany(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates many documents.
UpdateOneAsync(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates a single document.
UpdateOneAsync(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates a single document.
UpdateOne(IMongoCollection, IClientSessionHandle, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates a single document.
UpdateOne(IMongoCollection, Expression<Func<TDocument, bool>>, UpdateDefinition, UpdateOptions, CancellationToken)
Updates a single document.
WatchAsync(IMongoCollection, ChangeStreamOptions, CancellationToken)
Watches changes on the collection.
WatchAsync(IMongoCollection, IClientSessionHandle, ChangeStreamOptions, CancellationToken)
Watches changes on the collection.
Watch(IMongoCollection, ChangeStreamOptions, CancellationToken)
Watches changes on the collection.
Watch(IMongoCollection, IClientSessionHandle, ChangeStreamOptions, CancellationToken)
Watches changes on the collection.