|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.modeshape.graph.query.process.ProcessingComponent
@NotThreadSafe public abstract class ProcessingComponent
A component that performs (some) portion of the query processing by returning the tuples
that result from
this stage of processing. Processing components are designed to be assembled into a processing structure, with a single
component at the top that returns the results of a query.
Nested Class Summary | |
---|---|
protected static interface |
ProcessingComponent.DynamicOperation
Interface for evaluating a DynamicOperand to return the resulting value. |
Constructor Summary | |
---|---|
protected |
ProcessingComponent(QueryContext context,
QueryResults.Columns columns)
|
Method Summary | |
---|---|
void |
close()
Close these results, allowing any resources to be released. |
protected ProcessingComponent.DynamicOperation |
createDynamicOperation(TypeSystem typeSystem,
Schemata schemata,
QueryResults.Columns columns,
DynamicOperand operand)
Create a ProcessingComponent.DynamicOperation instance that is able to evaluate the supplied DynamicOperand . |
protected Comparator<Object[]> |
createSortComparator(QueryContext context,
QueryResults.Columns columns)
|
protected List<Object[]> |
emptyTuples()
Utility method to create a new tuples list that is empty. |
abstract List<Object[]> |
execute()
Execute this stage of processing and return the resulting tuples that each conform to the columns . |
QueryResults.Columns |
getColumns()
Get the column definitions. |
QueryContext |
getContext()
Get the context in which this query is being executed. |
protected Problems |
problems()
Get the container for problems encountered during processing. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected ProcessingComponent(QueryContext context, QueryResults.Columns columns)
Method Detail |
---|
public final QueryContext getContext()
public final QueryResults.Columns getColumns()
protected final Problems problems()
public abstract List<Object[]> execute()
columns
.
columns
; never nullpublic void close()
protected List<Object[]> emptyTuples()
protected ProcessingComponent.DynamicOperation createDynamicOperation(TypeSystem typeSystem, Schemata schemata, QueryResults.Columns columns, DynamicOperand operand)
ProcessingComponent.DynamicOperation
instance that is able to evaluate the supplied DynamicOperand
.
typeSystem
- the type system; may not be nullschemata
- the schemata; may not be nullcolumns
- the definition of the result columns and the tuples; may not be nulloperand
- the dynamic operand that is to be evaluated by the returned object; may not be null
protected Comparator<Object[]> createSortComparator(QueryContext context, QueryResults.Columns columns)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |