QueryNodeProcessorPipeline (Lucene 10.5.1 queryparser API)
Description: declaration: package: org.apache.lucene.queryparser.flexible.core.processors, class: QueryNodeProcessorPipeline

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

# Class QueryNodeProcessorPipeline

java.lang.Object
org.apache.lucene.queryparser.flexible.core.processors.QueryNodeProcessorPipeline

All Implemented Interfaces:
  `Iterable<QueryNodeProcessor>`, `Collection<QueryNodeProcessor>`, `List<QueryNodeProcessor>`, `SequencedCollection<QueryNodeProcessor>`, `QueryNodeProcessor`

Direct Known Subclasses:
  `StandardQueryNodeProcessorPipeline`

public class QueryNodeProcessorPipeline extends Object implements QueryNodeProcessor, List<QueryNodeProcessor>
A `QueryNodeProcessorPipeline` class should be used to build a query node processor pipeline.

When a query node tree is processed using this class, it passes the query node tree to each processor on the pipeline and the result from each processor is passed to the next one, always following the order the processors were on the pipeline.

When a `QueryConfigHandler` object is set on a `QueryNodeProcessorPipeline`, it also takes care of setting this `QueryConfigHandler` on all processor on pipeline.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `QueryNodeProcessorPipeline()`
  Constructs an empty query node processor pipeline.
  `QueryNodeProcessorPipeline(QueryConfigHandler queryConfigHandler)`
  Constructs with a `QueryConfigHandler` object.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `add(int index, QueryNodeProcessor processor)`
  `boolean`
  `add(QueryNodeProcessor processor)`
  `boolean`
  `addAll(int index, Collection<? extends QueryNodeProcessor> c)`
  `boolean`
  `addAll(Collection<? extends QueryNodeProcessor> c)`
  `void`
  `clear()`
  `boolean`
  `contains(Object o)`
  `boolean`
  `containsAll(Collection<?> c)`
  `QueryNodeProcessor`
  `get(int index)`
  `QueryConfigHandler`
  `getQueryConfigHandler()`
  For reference about this method check: `QueryNodeProcessor.getQueryConfigHandler()`.
  `int`
  `indexOf(Object o)`
  `boolean`
  `isEmpty()`
  `Iterator<QueryNodeProcessor>`
  `iterator()`
  `int`
  `lastIndexOf(Object o)`
  `ListIterator<QueryNodeProcessor>`
  `listIterator()`
  `ListIterator<QueryNodeProcessor>`
  `listIterator(int index)`
  `QueryNode`
  `process(QueryNode queryTree)`
  For reference about this method check: `QueryNodeProcessor.process(QueryNode)`.
  `QueryNodeProcessor`
  `remove(int index)`
  `boolean`
  `remove(Object o)`
  `boolean`
  `removeAll(Collection<?> c)`
  `boolean`
  `retainAll(Collection<?> c)`
  `QueryNodeProcessor`
  `set(int index, QueryNodeProcessor processor)`
  `void`
  `setQueryConfigHandler(QueryConfigHandler queryConfigHandler)`
  For reference about this method check: `QueryNodeProcessor.setQueryConfigHandler(QueryConfigHandler)`.
  `int`
  `size()`
  `List<QueryNodeProcessor>`
  `subList(int fromIndex, int toIndex)`
  `Object[]`
  `toArray()`
  `<T> T[]`
  `toArray(T[] array)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface java.util.Collection

  `parallelStream, removeIf, stream, toArray`

  ### Methods inherited from interface java.lang.Iterable

  `forEach`

  ### Methods inherited from interface java.util.List

  `addFirst, addLast, equals, getFirst, getLast, hashCode, removeFirst, removeLast, replaceAll, reversed, sort, spliterator`

- ## Constructor Details

  - ### QueryNodeProcessorPipeline

    public QueryNodeProcessorPipeline()
    Constructs an empty query node processor pipeline.

  - ### QueryNodeProcessorPipeline

    public QueryNodeProcessorPipeline(QueryConfigHandler queryConfigHandler)
    Constructs with a `QueryConfigHandler` object.

- ## Method Details

  - ### getQueryConfigHandler

    public QueryConfigHandler getQueryConfigHandler()
    For reference about this method check: `QueryNodeProcessor.getQueryConfigHandler()`.
    Specified by:
      `getQueryConfigHandler` in interface `QueryNodeProcessor`
    Returns:
      QueryConfigHandler the query configuration handler to be set.
    See Also:
      - `QueryNodeProcessor.setQueryConfigHandler(QueryConfigHandler)`
      - `QueryConfigHandler`

  - ### process

    public QueryNode process(QueryNode queryTree) throws QueryNodeException
    For reference about this method check: `QueryNodeProcessor.process(QueryNode)`.
    Specified by:
      `process` in interface `QueryNodeProcessor`
    Parameters:
      `queryTree` - the query node tree to be processed
    Returns:
      the processed query tree
    Throws:
      `QueryNodeException` - if something goes wrong during the query node processing
    See Also:
      - `QueryNode`

  - ### setQueryConfigHandler

    public void setQueryConfigHandler(QueryConfigHandler queryConfigHandler)
    For reference about this method check: `QueryNodeProcessor.setQueryConfigHandler(QueryConfigHandler)`.
    Specified by:
      `setQueryConfigHandler` in interface `QueryNodeProcessor`
    Parameters:
      `queryConfigHandler` - the query configuration handler to be set.
    See Also:
      - `QueryNodeProcessor.getQueryConfigHandler()`
      - `QueryConfigHandler`

  - ### add

    public boolean add(QueryNodeProcessor processor)
    Specified by:
      `add` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `add` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.add(Object)`

  - ### add

    public void add(int index, QueryNodeProcessor processor)
    Specified by:
      `add` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.add(int, Object)`

  - ### addAll

    public boolean addAll(Collection<? extends QueryNodeProcessor> c)
    Specified by:
      `addAll` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `addAll` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.addAll(Collection)`

  - ### addAll

    public boolean addAll(int index, Collection<? extends QueryNodeProcessor> c)
    Specified by:
      `addAll` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.addAll(int, Collection)`

  - ### clear

    public void clear()
    Specified by:
      `clear` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `clear` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.clear()`

  - ### contains

    public boolean contains(Object o)
    Specified by:
      `contains` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `contains` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.contains(Object)`

  - ### containsAll

    public boolean containsAll(Collection<?> c)
    Specified by:
      `containsAll` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `containsAll` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.containsAll(Collection)`

  - ### get

    public QueryNodeProcessor get(int index)
    Specified by:
      `get` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.get(int)`

  - ### indexOf

    public int indexOf(Object o)
    Specified by:
      `indexOf` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.indexOf(Object)`

  - ### isEmpty

    public boolean isEmpty()
    Specified by:
      `isEmpty` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `isEmpty` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.isEmpty()`

  - ### iterator

    public Iterator<QueryNodeProcessor> iterator()
    Specified by:
      `iterator` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `iterator` in interface `Iterable<QueryNodeProcessor>`
    Specified by:
      `iterator` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.iterator()`

  - ### lastIndexOf

    public int lastIndexOf(Object o)
    Specified by:
      `lastIndexOf` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.lastIndexOf(Object)`

  - ### listIterator

    public ListIterator<QueryNodeProcessor> listIterator()
    Specified by:
      `listIterator` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.listIterator()`

  - ### listIterator

    public ListIterator<QueryNodeProcessor> listIterator(int index)
    Specified by:
      `listIterator` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.listIterator(int)`

  - ### remove

    public boolean remove(Object o)
    Specified by:
      `remove` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `remove` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.remove(Object)`

  - ### remove

    public QueryNodeProcessor remove(int index)
    Specified by:
      `remove` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.remove(int)`

  - ### removeAll

    public boolean removeAll(Collection<?> c)
    Specified by:
      `removeAll` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `removeAll` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.removeAll(Collection)`

  - ### retainAll

    public boolean retainAll(Collection<?> c)
    Specified by:
      `retainAll` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `retainAll` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.retainAll(Collection)`

  - ### set

    public QueryNodeProcessor set(int index, QueryNodeProcessor processor)
    Specified by:
      `set` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.set(int, Object)`

  - ### size

    public int size()
    Specified by:
      `size` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `size` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.size()`

  - ### subList

    public List<QueryNodeProcessor> subList(int fromIndex, int toIndex)
    Specified by:
      `subList` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.subList(int, int)`

  - ### toArray

    public <T> T[] toArray(T[] array)
    Specified by:
      `toArray` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `toArray` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.toArray(Object[])`

  - ### toArray

    public Object[] toArray()
    Specified by:
      `toArray` in interface `Collection<QueryNodeProcessor>`
    Specified by:
      `toArray` in interface `List<QueryNodeProcessor>`
    See Also:
      - `List.toArray()`