Method ListDatabaseNamesAsync
ListDatabaseNamesAsync(CancellationToken)
Returns the names of the databases on the server.
public Task<IAsyncCursor<string>> ListDatabaseNamesAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<IAsyncCursor<string>>
The database names.
ListDatabaseNamesAsync(ListDatabaseNamesOptions, CancellationToken)
Returns the names of the databases on the server.
public Task<IAsyncCursor<string>> ListDatabaseNamesAsync(ListDatabaseNamesOptions options, CancellationToken cancellationToken = default)
Parameters
optionsListDatabaseNamesOptionsThe options.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<IAsyncCursor<string>>
The database names.
ListDatabaseNamesAsync(IClientSessionHandle, CancellationToken)
Returns the names of the databases on the server.
public Task<IAsyncCursor<string>> ListDatabaseNamesAsync(IClientSessionHandle session, CancellationToken cancellationToken = default)
Parameters
sessionIClientSessionHandleThe session.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<IAsyncCursor<string>>
The database names.
ListDatabaseNamesAsync(IClientSessionHandle, ListDatabaseNamesOptions, CancellationToken)
Returns the names of the databases on the server.
public Task<IAsyncCursor<string>> ListDatabaseNamesAsync(IClientSessionHandle session, ListDatabaseNamesOptions options, CancellationToken cancellationToken = default)
Parameters
sessionIClientSessionHandleThe session.
optionsListDatabaseNamesOptionsThe options.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<IAsyncCursor<string>>
The database names.