@@ -8,54 +8,59 @@ namespace Nest
88 [ JsonConverter ( typeof ( ReadAsTypeJsonConverter < MultiMatchQueryDescriptor < object > > ) ) ]
99 public interface IMultiMatchQuery : IQuery
1010 {
11- [ JsonProperty ( PropertyName = "type" ) ]
12- [ JsonConverter ( typeof ( StringEnumConverter ) ) ]
11+ [ JsonProperty ( "type" ) ]
1312 TextQueryType ? Type { get ; set ; }
1413
15- [ JsonProperty ( PropertyName = "query" ) ]
14+ [ JsonProperty ( "query" ) ]
1615 string Query { get ; set ; }
1716
18- [ JsonProperty ( PropertyName = "analyzer" ) ]
17+ [ JsonProperty ( "analyzer" ) ]
1918 string Analyzer { get ; set ; }
2019
21- [ JsonProperty ( PropertyName = "fuzzy_rewrite" ) ]
22- [ JsonConverter ( typeof ( StringEnumConverter ) ) ]
20+ [ JsonProperty ( "fuzzy_rewrite" ) ]
2321 RewriteMultiTerm ? FuzzyRewrite { get ; set ; }
2422
25- [ JsonProperty ( PropertyName = "fuzziness" ) ]
23+ /// <summary>
24+ /// Allows fuzzy matching based on the type of field being queried.
25+ /// Cannot be used with the
26+ /// <see cref="TextQueryType.CrossFields"/>,
27+ /// <see cref="TextQueryType.Phrase"/> or
28+ /// <see cref="TextQueryType.PhrasePrefix"/> types.
29+ /// </summary>
30+ [ JsonProperty ( "fuzziness" ) ]
2631 Fuzziness Fuzziness { get ; set ; }
2732
28- [ JsonProperty ( PropertyName = "cutoff_frequency" ) ]
33+ [ JsonProperty ( "cutoff_frequency" ) ]
2934 double ? CutoffFrequency { get ; set ; }
3035
31- [ JsonProperty ( PropertyName = "prefix_length" ) ]
36+ [ JsonProperty ( "prefix_length" ) ]
3237 int ? PrefixLength { get ; set ; }
3338
34- [ JsonProperty ( PropertyName = "max_expansions" ) ]
39+ [ JsonProperty ( "max_expansions" ) ]
3540 int ? MaxExpansions { get ; set ; }
3641
37- [ JsonProperty ( PropertyName = "slop" ) ]
42+ [ JsonProperty ( "slop" ) ]
3843 int ? Slop { get ; set ; }
3944
40- [ JsonProperty ( PropertyName = "lenient" ) ]
45+ [ JsonProperty ( "lenient" ) ]
4146 bool ? Lenient { get ; set ; }
4247
43- [ JsonProperty ( PropertyName = "use_dis_max" ) ]
48+ [ JsonProperty ( "use_dis_max" ) ]
4449 bool ? UseDisMax { get ; set ; }
4550
46- [ JsonProperty ( PropertyName = "tie_breaker" ) ]
51+ [ JsonProperty ( "tie_breaker" ) ]
4752 double ? TieBreaker { get ; set ; }
4853
49- [ JsonProperty ( PropertyName = "minimum_should_match" ) ]
54+ [ JsonProperty ( "minimum_should_match" ) ]
5055 MinimumShouldMatch MinimumShouldMatch { get ; set ; }
5156
52- [ JsonProperty ( PropertyName = "operator" ) ]
57+ [ JsonProperty ( "operator" ) ]
5358 Operator ? Operator { get ; set ; }
5459
55- [ JsonProperty ( PropertyName = "fields" ) ]
60+ [ JsonProperty ( "fields" ) ]
5661 Fields Fields { get ; set ; }
5762
58- [ JsonProperty ( PropertyName = "zero_terms_query" ) ]
63+ [ JsonProperty ( "zero_terms_query" ) ]
5964 ZeroTermsQuery ? ZeroTermsQuery { get ; set ; }
6065 }
6166
@@ -66,6 +71,14 @@ public class MultiMatchQuery : QueryBase, IMultiMatchQuery
6671 public string Query { get ; set ; }
6772 public string Analyzer { get ; set ; }
6873 public RewriteMultiTerm ? FuzzyRewrite { get ; set ; }
74+
75+ /// <summary>
76+ /// Allows fuzzy matching based on the type of field being queried.
77+ /// Cannot be used with the
78+ /// <see cref="TextQueryType.CrossFields"/>,
79+ /// <see cref="TextQueryType.Phrase"/> or
80+ /// <see cref="TextQueryType.PhrasePrefix"/> types.
81+ /// </summary>
6982 public Fuzziness Fuzziness { get ; set ; }
7083 public double ? CutoffFrequency { get ; set ; }
7184 public int ? PrefixLength { get ; set ; }
@@ -116,6 +129,13 @@ public MultiMatchQueryDescriptor<T> Fields(Func<FieldsDescriptor<T>, IPromise<Fi
116129
117130 public MultiMatchQueryDescriptor < T > Analyzer ( string analyzer ) => Assign ( a => a . Analyzer = analyzer ) ;
118131
132+ /// <summary>
133+ /// Allows fuzzy matching based on the type of field being queried.
134+ /// Cannot be used with the
135+ /// <see cref="TextQueryType.CrossFields"/>,
136+ /// <see cref="TextQueryType.Phrase"/> or
137+ /// <see cref="TextQueryType.PhrasePrefix"/> types.
138+ /// </summary>
119139 public MultiMatchQueryDescriptor < T > Fuzziness ( Fuzziness fuzziness ) => Assign ( a => a . Fuzziness = fuzziness ) ;
120140
121141 public MultiMatchQueryDescriptor < T > CutoffFrequency ( double cutoffFrequency )
0 commit comments