Click or drag to resize

IFulltextQueryOptionsTDocumentFieldWeightTField Method (ExpressionFuncTDocument, TField, Int32)

Sets a weight for the selected field.

Namespace:  SphinxConnector.FluentApi
Assembly:  SphinxConnector (in SphinxConnector.dll) Version: 5.3.0
Syntax
IFulltextQueryOptions<TDocument> FieldWeight<TField>(
	Expression<Func<TDocument, TField>> fieldSelector,
	int weight
)

Parameters

fieldSelector
Type: System.Linq.ExpressionsExpressionFuncTDocument, TField
A function to select the field for which the weight should be set.
weight
Type: SystemInt32
The weight to set for the field.

Type Parameters

TField
The type of field to set a weight for.

Return Value

Type: IFulltextQueryOptionsTDocument
The current instance.
See Also