Namespace Lucene.Net.QueryParsers.Flexible.Precedence.Processors
Processors used by Precedence Query Parser
Lucene Precedence Query Parser Processors
This package contains the 2 QueryNodeProcessors used by PrecedenceQueryParser.
BooleanModifiersQueryNodeProcessor: this processor is used to apply ModifierQueryNodes on BooleanQueryNode children according to the boolean type or the default operator.
PrecedenceQueryNodeProcessorPipeline: this processor pipeline is used by PrecedenceQueryParser. It extends StandardQueryNodeProcessorPipeline and rearrange the pipeline so the boolean precedence is processed correctly. Check PrecedenceQueryNodeProcessorPipeline for more details.
Classes
BooleanModifiersQueryNodeProcessor
This processor is used to apply the correct ModifierQueryNode to BooleanQueryNodes children.
It walks through the query node tree looking for BooleanQueryNodes. If an AndQueryNode is found, every child, which is not a ModifierQueryNode or the ModifierQueryNode is MOD_NONE, becomes a MOD_REQ. For any other BooleanQueryNode which is not an OrQueryNode, it checks the default operator is AND, if it is, the same operation when an AndQueryNode is found is applied to it.
PrecedenceQueryNodeProcessorPipeline
This processor pipeline extends StandardQueryNodeProcessorPipeline and enables boolean precedence on it.
EXPERT: the precedence is enabled by removing GroupQueryNodeProcessor from the StandardQueryNodeProcessorPipeline and appending BooleanModifiersQueryNodeProcessor to the pipeline.