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
ConstructorsConstructorDescriptionConstructs an empty query node processor pipeline.QueryNodeProcessorPipeline(QueryConfigHandler queryConfigHandler) Constructs with aQueryConfigHandlerobject. -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(int index, QueryNodeProcessor processor) booleanadd(QueryNodeProcessor processor) booleanaddAll(int index, Collection<? extends QueryNodeProcessor> c) booleanaddAll(Collection<? extends QueryNodeProcessor> c) voidclear()booleanbooleancontainsAll(Collection<?> c) get(int index) For reference about this method check:QueryNodeProcessor.getQueryConfigHandler().intbooleanisEmpty()iterator()intlistIterator(int index) For reference about this method check:QueryNodeProcessor.process(QueryNode).remove(int index) booleanbooleanremoveAll(Collection<?> c) booleanretainAll(Collection<?> c) set(int index, QueryNodeProcessor processor) voidsetQueryConfigHandler(QueryConfigHandler queryConfigHandler) For reference about this method check:QueryNodeProcessor.setQueryConfigHandler(QueryConfigHandler).intsize()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, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods 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
Constructs with aQueryConfigHandlerobject.
-
-
Method Details
-
getQueryConfigHandler
For reference about this method check:QueryNodeProcessor.getQueryConfigHandler().- Specified by:
getQueryConfigHandlerin interfaceQueryNodeProcessor- Returns:
- QueryConfigHandler the query configuration handler to be set.
- See Also:
-
process
For reference about this method check:QueryNodeProcessor.process(QueryNode).- Specified by:
processin interfaceQueryNodeProcessor- 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:
-
setQueryConfigHandler
For reference about this method check:QueryNodeProcessor.setQueryConfigHandler(QueryConfigHandler).- Specified by:
setQueryConfigHandlerin interfaceQueryNodeProcessor- Parameters:
queryConfigHandler- the query configuration handler to be set.- See Also:
-
add
- Specified by:
addin interfaceCollection<QueryNodeProcessor>- Specified by:
addin interfaceList<QueryNodeProcessor>- See Also:
-
add
- Specified by:
addin interfaceList<QueryNodeProcessor>- See Also:
-
addAll
- Specified by:
addAllin interfaceCollection<QueryNodeProcessor>- Specified by:
addAllin interfaceList<QueryNodeProcessor>- See Also:
-
addAll
- Specified by:
addAllin interfaceList<QueryNodeProcessor>- See Also:
-
clear
public void clear()- Specified by:
clearin interfaceCollection<QueryNodeProcessor>- Specified by:
clearin interfaceList<QueryNodeProcessor>- See Also:
-
contains
- Specified by:
containsin interfaceCollection<QueryNodeProcessor>- Specified by:
containsin interfaceList<QueryNodeProcessor>- See Also:
-
containsAll
- Specified by:
containsAllin interfaceCollection<QueryNodeProcessor>- Specified by:
containsAllin interfaceList<QueryNodeProcessor>- See Also:
-
get
- Specified by:
getin interfaceList<QueryNodeProcessor>- See Also:
-
indexOf
- Specified by:
indexOfin interfaceList<QueryNodeProcessor>- See Also:
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfaceCollection<QueryNodeProcessor>- Specified by:
isEmptyin interfaceList<QueryNodeProcessor>- See Also:
-
iterator
- Specified by:
iteratorin interfaceCollection<QueryNodeProcessor>- Specified by:
iteratorin interfaceIterable<QueryNodeProcessor>- Specified by:
iteratorin interfaceList<QueryNodeProcessor>- See Also:
-
lastIndexOf
- Specified by:
lastIndexOfin interfaceList<QueryNodeProcessor>- See Also:
-
listIterator
- Specified by:
listIteratorin interfaceList<QueryNodeProcessor>- See Also:
-
listIterator
- Specified by:
listIteratorin interfaceList<QueryNodeProcessor>- See Also:
-
remove
- Specified by:
removein interfaceCollection<QueryNodeProcessor>- Specified by:
removein interfaceList<QueryNodeProcessor>- See Also:
-
remove
- Specified by:
removein interfaceList<QueryNodeProcessor>- See Also:
-
removeAll
- Specified by:
removeAllin interfaceCollection<QueryNodeProcessor>- Specified by:
removeAllin interfaceList<QueryNodeProcessor>- See Also:
-
retainAll
- Specified by:
retainAllin interfaceCollection<QueryNodeProcessor>- Specified by:
retainAllin interfaceList<QueryNodeProcessor>- See Also:
-
set
- Specified by:
setin interfaceList<QueryNodeProcessor>- See Also:
-
size
public int size()- Specified by:
sizein interfaceCollection<QueryNodeProcessor>- Specified by:
sizein interfaceList<QueryNodeProcessor>- See Also:
-
subList
- Specified by:
subListin interfaceList<QueryNodeProcessor>- See Also:
-
toArray
public <T> T[] toArray(T[] array) - Specified by:
toArrayin interfaceCollection<QueryNodeProcessor>- Specified by:
toArrayin interfaceList<QueryNodeProcessor>- See Also:
-
toArray
- Specified by:
toArrayin interfaceCollection<QueryNodeProcessor>- Specified by:
toArrayin interfaceList<QueryNodeProcessor>- See Also:
-