Package org.apache.lucene.queryparser.flexible.core.processors

# Interface QueryNodeProcessor

All Known Implementing Classes:
  `AllowLeadingWildcardProcessor`, `AnalyzerQueryNodeProcessor`, `BooleanModifiersQueryNodeProcessor`, `BooleanQuery2ModifierNodeProcessor`, `BooleanSingleChildOptimizationQueryNodeProcessor`, `BoostQueryNodeProcessor`, `DefaultPhraseSlopQueryNodeProcessor`, `FuzzyQueryNodeProcessor`, `IntervalQueryNodeProcessor`, `MatchAllDocsQueryNodeProcessor`, `MultiFieldQueryNodeProcessor`, `MultiTermRewriteMethodProcessor`, `NoChildOptimizationQueryNodeProcessor`, `OpenRangeQueryNodeProcessor`, `PhraseSlopQueryNodeProcessor`, `PointQueryNodeProcessor`, `PointRangeQueryNodeProcessor`, `PrecedenceQueryNodeProcessorPipeline`, `QueryNodeProcessorImpl`, `QueryNodeProcessorPipeline`, `RegexpQueryNodeProcessor`, `RemoveDeletedQueryNodesProcessor`, `RemoveEmptyNonLeafQueryNodeProcessor`, `StandardQueryNodeProcessorPipeline`, `TermRangeQueryNodeProcessor`, `WildcardQueryNodeProcessor`

public interface QueryNodeProcessor
A `QueryNodeProcessor` is an interface for classes that process a `QueryNode` tree.

The implementor of this class should perform some operation on a query node tree and return the same or another query node tree.

It also may carry a `QueryConfigHandler` object that contains configuration about the query represented by the query tree or the collection/index where it's intended to be executed.

In case there is any `QueryConfigHandler` associated to the query tree to be processed, it should be set using `setQueryConfigHandler(QueryConfigHandler)` before `process(QueryNode)` is invoked.

See Also:
  - `QueryNode`
  - `QueryNodeProcessor`
  - `QueryConfigHandler`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `QueryConfigHandler`
  `getQueryConfigHandler()`
  Returns the `QueryConfigHandler` associated to the query tree if any, otherwise it returns `null`
  `QueryNode`
  `process(QueryNode queryTree)`
  Processes a query node tree.
  `void`
  `setQueryConfigHandler(QueryConfigHandler queryConfigHandler)`
  Sets the `QueryConfigHandler` associated to the query tree.

- ## Method Details

  - ### process

    QueryNode process(QueryNode queryTree) throws QueryNodeException
    Processes a query node tree. It may return the same or another query tree. I should never return `null`.
    Parameters:
      `queryTree` - tree root node
    Returns:
      the processed query tree
    Throws:
      `QueryNodeException`

  - ### setQueryConfigHandler

    void setQueryConfigHandler(QueryConfigHandler queryConfigHandler)
    Sets the `QueryConfigHandler` associated to the query tree.

  - ### getQueryConfigHandler

    QueryConfigHandler getQueryConfigHandler()
    Returns the `QueryConfigHandler` associated to the query tree if any, otherwise it returns `null`
    Returns:
      the `QueryConfigHandler` associated to the query tree if any, otherwise it returns `null`