The client interface to MongoDB.
Namespace:
MongoDB.Driver
Assembly:
MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.7.3+Branch.v2.7.x.Sha.2f1f2be13a23b8520cb9c2ee8439c022f9a03efe
Syntax public interface IMongoClient
Public Interface IMongoClient
type IMongoClient = interface end
The IMongoClient type exposes the following members.
Properties Methods
| Name | Description |
---|
| DropDatabase(String, CancellationToken) |
Drops the database with the specified name.
|
| DropDatabase(IClientSessionHandle, String, CancellationToken) |
Drops the database with the specified name.
|
| DropDatabaseAsync(String, CancellationToken) |
Drops the database with the specified name.
|
| DropDatabaseAsync(IClientSessionHandle, String, CancellationToken) |
Drops the database with the specified name.
|
| GetDatabase |
Gets a database.
|
| ListDatabaseNames(CancellationToken) |
Returns the names of the databases on the server.
|
| ListDatabaseNames(IClientSessionHandle, CancellationToken) |
Returns the names of the databases on the server.
|
| ListDatabaseNamesAsync(CancellationToken) |
Returns the names of the databases on the server.
|
| ListDatabaseNamesAsync(IClientSessionHandle, CancellationToken) |
Returns the names of the databases on the server.
|
| ListDatabases(CancellationToken) |
Lists the databases on the server.
|
| ListDatabases(IClientSessionHandle, CancellationToken) |
Lists the databases on the server.
|
| ListDatabases(ListDatabasesOptions, CancellationToken) |
Lists the databases on the server.
|
| ListDatabases(IClientSessionHandle, ListDatabasesOptions, CancellationToken) |
Lists the databases on the server.
|
| ListDatabasesAsync(CancellationToken) |
Lists the databases on the server.
|
| ListDatabasesAsync(IClientSessionHandle, CancellationToken) |
Lists the databases on the server.
|
| ListDatabasesAsync(ListDatabasesOptions, CancellationToken) |
Lists the databases on the server.
|
| ListDatabasesAsync(IClientSessionHandle, ListDatabasesOptions, CancellationToken) |
Lists the databases on the server.
|
| StartSession |
Starts a client session.
|
| StartSessionAsync |
Starts a client session.
|
| WatchTResult(PipelineDefinitionChangeStreamDocumentBsonDocument, TResult, ChangeStreamOptions, CancellationToken) |
Watches changes on all collections in all databases.
|
| WatchTResult(IClientSessionHandle, PipelineDefinitionChangeStreamDocumentBsonDocument, TResult, ChangeStreamOptions, CancellationToken) |
Watches changes on all collections in all databases.
|
| WatchAsyncTResult(PipelineDefinitionChangeStreamDocumentBsonDocument, TResult, ChangeStreamOptions, CancellationToken) |
Watches changes on all collections in all databases.
|
| WatchAsyncTResult(IClientSessionHandle, PipelineDefinitionChangeStreamDocumentBsonDocument, TResult, ChangeStreamOptions, CancellationToken) |
Watches changes on all collections in all databases.
|
| WithReadConcern |
Returns a new IMongoClient instance with a different read concern setting.
|
| WithReadPreference |
Returns a new IMongoClient instance with a different read preference setting.
|
| WithWriteConcern |
Returns a new IMongoClient instance with a different write concern setting.
|
TopExtension Methods Remarks
This interface is not guaranteed to remain stable. Implementors should use
MongoClientBase.
See Also