Skip to content

Commit

Permalink
Merge pull request #1392 from elastic/feature/analyze-wildcard-simple…
Browse files Browse the repository at this point in the history
…-query-string

fix #1357 add support for analyze_wildcard on simeple_query_string
  • Loading branch information
gmarz committed May 7, 2015
2 parents 7a534cf + dca09f7 commit 9e20238
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/Nest/DSL/Query/SimpleQueryStringQueryDescriptor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ public interface ISimpleQueryStringQuery : IQuery
[JsonProperty(PropertyName = "lowercase_expanded_terms")]
bool? LowercaseExpendedTerms { get; set; }

[JsonProperty(PropertyName = "analyze_wildcard")]
bool? AnalyzeWildcard { get; set; }

[JsonProperty(PropertyName = "flags")]
string Flags { get; set; }

Expand All @@ -56,6 +59,7 @@ protected override void WrapInContainer(IQueryContainer container)
public Operator? DefaultOperator { get; set; }
public string Analyzer { get; set; }
public bool? LowercaseExpendedTerms { get; set; }
public bool? AnalyzeWildcard { get; set; }
public string Flags { get; set; }
public string Locale { get; set; }
public string MinimumShouldMatch { get; set; }
Expand All @@ -75,6 +79,8 @@ public class SimpleQueryStringQueryDescriptor<T> : ISimpleQueryStringQuery where

string ISimpleQueryStringQuery.Analyzer { get; set; }

bool? ISimpleQueryStringQuery.AnalyzeWildcard { get; set; }

bool? ISimpleQueryStringQuery.LowercaseExpendedTerms { get; set; }

string ISimpleQueryStringQuery.Flags { get; set; }
Expand Down Expand Up @@ -159,6 +165,11 @@ public SimpleQueryStringQueryDescriptor<T> LowercaseExpendedTerms(bool lowercase
Self.LowercaseExpendedTerms = lowercaseExpendedTerms;
return this;
}
public SimpleQueryStringQueryDescriptor<T> AnalyzeWildcard(bool analyzeWildcard = true)
{
Self.AnalyzeWildcard = analyzeWildcard;
return this;
}
public SimpleQueryStringQueryDescriptor<T> Locale(string locale)
{
Self.Locale = locale;
Expand Down

0 comments on commit 9e20238

Please sign in to comment.