IMongoClient.ListDatabasesAsync Method (ListDatabasesOptions, CancellationToken) |
Lists the databases on the server.
Namespace:
MongoDB.Driver
Assembly:
MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.20.0+ee01960089f28ea1b501690df5fc9f6318a70242
Syntax Task<IAsyncCursor<BsonDocument>> ListDatabasesAsync(
ListDatabasesOptions options,
CancellationToken cancellationToken = null
)
Function ListDatabasesAsync (
options As ListDatabasesOptions,
Optional cancellationToken As CancellationToken = Nothing
) As Task(Of IAsyncCursor(Of BsonDocument))
abstract ListDatabasesAsync :
options : ListDatabasesOptions *
?cancellationToken : CancellationToken
(* Defaults:
let _cancellationToken = defaultArg cancellationToken null
*)
-> Task<IAsyncCursor<BsonDocument>>
Parameters
- options
- Type: MongoDB.Driver.ListDatabasesOptions
The options. - cancellationToken (Optional)
- Type: System.Threading.CancellationToken
The cancellation token.
Return Value
Type:
Task<IAsyncCursor<BsonDocument>>A Task whose result is a cursor.
See Also