The client interface to MongoDB.
Namespace:
MongoDB.Driver
Assembly:
MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.9.0+32b058abcdf2c7e8d9dd3a676d207b31897eee2e
Syntaxpublic 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.
|
Top
Extension Methods
Remarks
This interface is not guaranteed to remain stable. Implementors should use
MongoClientBase.
See Also