GridFSBucket<TFileId>.FindAsync Method |
Finds matching entries from the files collection.
Namespace:
MongoDB.Driver.GridFS
Assembly:
MongoDB.Driver.GridFS (in MongoDB.Driver.GridFS.dll) Version: 2.14.0+2b37a1fe1cbdbe1a020b52b77f1197b6d77575e7
Syntaxpublic Task<IAsyncCursor<GridFSFileInfo<TFileId>>> FindAsync(
FilterDefinition<GridFSFileInfo<TFileId>> filter,
GridFSFindOptions<TFileId> options = null,
CancellationToken cancellationToken = default
)
Public Function FindAsync (
filter As FilterDefinition(Of GridFSFileInfo(Of TFileId)),
Optional options As GridFSFindOptions(Of TFileId) = Nothing,
Optional cancellationToken As CancellationToken = Nothing
) As Task(Of IAsyncCursor(Of GridFSFileInfo(Of TFileId)))
abstract FindAsync :
filter : FilterDefinition<GridFSFileInfo<'TFileId>> *
?options : GridFSFindOptions<'TFileId> *
?cancellationToken : CancellationToken
(* Defaults:
let _options = defaultArg options null
let _cancellationToken = defaultArg cancellationToken new CancellationToken()
*)
-> Task<IAsyncCursor<GridFSFileInfo<'TFileId>>>
override FindAsync :
filter : FilterDefinition<GridFSFileInfo<'TFileId>> *
?options : GridFSFindOptions<'TFileId> *
?cancellationToken : CancellationToken
(* Defaults:
let _options = defaultArg options null
let _cancellationToken = defaultArg cancellationToken new CancellationToken()
*)
-> Task<IAsyncCursor<GridFSFileInfo<'TFileId>>>
Parameters
- filter
- Type: MongoDB.Driver.FilterDefinition<GridFSFileInfo<TFileId>>
The filter. - options (Optional)
- Type: MongoDB.Driver.GridFS.GridFSFindOptions<TFileId>
The options. - cancellationToken (Optional)
- Type: System.Threading.CancellationToken
The cancellation token.
Return Value
Type:
Task<IAsyncCursor<GridFSFileInfo<TFileId>>>A Task whose result is a cursor of files collection documents.
Implements
IGridFSBucket<TFileId>.FindAsync(FilterDefinition<GridFSFileInfo<TFileId>>, GridFSFindOptions<TFileId>, CancellationToken)
See Also