PipelineStageDefinitionBuilderSearchTInput Method |
Creates a $search stage.
Namespace:
MongoDB.Driver
Assembly:
MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.20.0+ee01960089f28ea1b501690df5fc9f6318a70242
Syntax public static PipelineStageDefinition<TInput, TInput> Search<TInput>(
SearchDefinition<TInput> searchDefinition,
SearchHighlightOptions<TInput> highlight = null,
string indexName = null,
SearchCountOptions count = null,
bool returnStoredSource = false
)
Public Shared Function Search(Of TInput) (
searchDefinition As SearchDefinition(Of TInput),
Optional highlight As SearchHighlightOptions(Of TInput) = Nothing,
Optional indexName As String = Nothing,
Optional count As SearchCountOptions = Nothing,
Optional returnStoredSource As Boolean = false
) As PipelineStageDefinition(Of TInput, TInput)
static member Search :
searchDefinition : SearchDefinition<'TInput> *
?highlight : SearchHighlightOptions<'TInput> *
?indexName : string *
?count : SearchCountOptions *
?returnStoredSource : bool
(* Defaults:
let _highlight = defaultArg highlight null
let _indexName = defaultArg indexName null
let _count = defaultArg count null
let _returnStoredSource = defaultArg returnStoredSource false
*)
-> PipelineStageDefinition<'TInput, 'TInput>
Parameters
- searchDefinition
- Type: MongoDB.Driver.SearchSearchDefinitionTInput
The search definition. - highlight (Optional)
- Type: MongoDB.Driver.SearchSearchHighlightOptionsTInput
The highlight options. - indexName (Optional)
- Type: SystemString
The index name. - count (Optional)
- Type: MongoDB.Driver.SearchSearchCountOptions
The count options. - returnStoredSource (Optional)
- Type: SystemBoolean
Flag that specifies whether to perform a full document lookup on the backend database
or return only stored source fields directly from Atlas Search.
Type Parameters
- TInput
- The type of the input documents.
Return Value
Type:
PipelineStageDefinitionTInput,
TInputThe stage.
See Also