Class ExamineMultiFieldQueryParser
Custom query parser to deal with Examine/Lucene field value types
public class ExamineMultiFieldQueryParser : CustomMultiFieldQueryParser, ICommonQueryParserConfiguration
- Inheritance
-
QueryBuilderQueryParserBaseQueryParserMultiFieldQueryParserExamineMultiFieldQueryParser
- Implements
-
ICommonQueryParserConfiguration
- Inherited Members
-
MultiFieldQueryParser.m_fieldsMultiFieldQueryParser.m_boostsQueryParser.Conjunction()QueryParser.Modifiers()QueryParser.ReInit(ICharStream)QueryParser.ReInit(QueryParserTokenManager)QueryParser.GetNextToken()QueryParser.GenerateParseException()QueryParser.Enable_tracing()QueryParser.Disable_tracing()QueryParser.TokenSourceQueryParser.TokenQueryParser.Jj_ntQueryParserBase.CONJ_NONEQueryParserBase.CONJ_ANDQueryParserBase.CONJ_ORQueryParserBase.MOD_NONEQueryParserBase.MOD_NOTQueryParserBase.MOD_REQQueryParserBase.AND_OPERATORQueryParserBase.OR_OPERATORQueryParserBase.m_fieldQueryParserBase.SetDateResolution(DateResolution)QueryParserBase.NewBooleanClause(Query, Occur)QueryParserBase.NewPrefixQuery(Term)QueryParserBase.NewRegexpQuery(Term)QueryParserBase.NewMatchAllDocsQuery()QueryParserBase.NewWildcardQuery(Term)QueryParserBase.FieldQueryParserBase.AutoGeneratePhraseQueriesQueryParserBase.FuzzyMinSimQueryParserBase.FuzzyPrefixLengthQueryParserBase.PhraseSlopQueryParserBase.AllowLeadingWildcardQueryParserBase.DefaultOperatorQueryParserBase.LowercaseExpandedTermsQueryParserBase.MultiTermRewriteMethodQueryParserBase.LocaleQueryParserBase.TimeZoneQueryParserBase.AnalyzeRangeTermsQueryBuilder.NewTermQuery(Term)QueryBuilder.NewPhraseQuery()QueryBuilder.NewMultiPhraseQuery()QueryBuilder.AnalyzerQueryBuilder.EnablePositionIncrements
Constructors
ExamineMultiFieldQueryParser(ISearchContext, LuceneVersion, Analyzer)
public ExamineMultiFieldQueryParser(ISearchContext searchContext, LuceneVersion matchVersion, Analyzer analyzer)
Parameters
searchContext
ISearchContextmatchVersion
LuceneVersionanalyzer
Analyzer
Methods
GetRangeQuery(string, string, string, bool, bool)
Override to provide support for numerical range query parsing
protected override Query GetRangeQuery(string field, string part1, string part2, bool startInclusive, bool endInclusive)
Parameters
Returns
- Query
Remarks
By Default the lucene query parser only deals with strings and the result is a TermRangeQuery, however for numerics it needs to be a NumericRangeQuery. We can override this method to provide that behavior.
In previous releases people were complaining that this wouldn't work and this is why. The answer came from here https://stackoverflow.com/questions/5026185/how-do-i-make-the-queryparser-in-lucene-handle-numeric-ranges