Skip to content

Commit fe26dc7

Browse files
committed
FunctionScoreQuery: Add overload to enable passing of a collection of function score functions
directly via the descriptor Closes elastic#1216
1 parent 18b7066 commit fe26dc7

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/Nest/DSL/Query/FunctionScoreQueryDescriptor.cs

+6
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,12 @@ public FunctionScoreQueryDescriptor<T> Functions(params Func<FunctionScoreFuncti
128128
return this;
129129
}
130130

131+
public FunctionScoreQueryDescriptor<T> Functions(IEnumerable<IFunctionScoreFunction> functions)
132+
{
133+
Self.Functions = functions;
134+
return this;
135+
}
136+
131137
public FunctionScoreQueryDescriptor<T> ScoreMode(FunctionScoreMode mode)
132138
{
133139
Self.ScoreMode = mode;

0 commit comments

Comments
 (0)