Click or drag to resize

AggregateFluentBase<TResult>.Search Method (SearchDefinition<TResult>, SearchHighlightOptions<TResult>, String, SearchCountOptions, Boolean, Boolean)

Appends a $search stage to the pipeline.

Namespace:  MongoDB.Driver
Assembly:  MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.21.0+5a9c3311e158910b88195f290e6d4b1b2715d2b2
Syntax
public virtual IAggregateFluent<TResult> Search(
	SearchDefinition<TResult> searchDefinition,
	SearchHighlightOptions<TResult> highlight = null,
	string indexName = null,
	SearchCountOptions count = null,
	bool returnStoredSource = false,
	bool scoreDetails = false
)

Parameters

searchDefinition
Type: MongoDB.Driver.Search.SearchDefinition<TResult>
The search definition.
highlight (Optional)
Type: MongoDB.Driver.Search.SearchHighlightOptions<TResult>
The highlight options.
indexName (Optional)
Type: System.String
The index name.
count (Optional)
Type: MongoDB.Driver.Search.SearchCountOptions
The count options.
returnStoredSource (Optional)
Type: System.Boolean
Flag that specifies whether to perform a full document lookup on the backend database or return only stored source fields directly from Atlas Search.
scoreDetails (Optional)
Type: System.Boolean
Flag that specifies whether to return a detailed breakdown of the score for each document in the result.

Return Value

Type: IAggregateFluent<TResult>
The fluent aggregate interface.

Implements

IAggregateFluent<TResult>.Search(SearchDefinition<TResult>, SearchHighlightOptions<TResult>, String, SearchCountOptions, Boolean, Boolean)
See Also