IFulltext Query OptionsTDocumentField WeightTField(ExpressionFuncTDocument, TField, Int 32) Method
Sets a weight for the selected field.
Definition
Namespace: SphinxConnector.FluentApi
Assembly: SphinxConnector (in SphinxConnector.dll) Version: 6.1.0
The current instance.
Assembly: SphinxConnector (in SphinxConnector.dll) Version: 6.1.0
C#
IFulltextQueryOptions<TDocument> FieldWeight<TField>(
Expression<Func<TDocument, TField>> fieldSelector,
int weight
)
VB
Function FieldWeight(Of TField) (
fieldSelector As Expression(Of Func(Of TDocument, TField)),
weight As Integer
) As IFulltextQueryOptions(Of TDocument)Parameters
- fieldSelector ExpressionFuncTDocument, TField
- A function to select the field for which the weight should be set.
- weight Int32
- The weight to set for the field.
Type Parameters
- TField
- The type of field to set a weight for.
Return Value
IFulltextQueryOptionsTDocumentThe current instance.