org.objectweb.medor.eval.api

Interface NodeEvaluator

Known Implementing Classes:
BinaryIteratifNodeEvaluator, TupleCollectionNodeEvaluator, UnaryIteratifNodeEvaluator

public interface NodeEvaluator

This interface defines the controller object for the evaluation of a given QueryNode within a QueryTree. It is created at evaluation time by the NodeEvaluatorFactory, on request from the QueryEvaluator. The QueryEvaluator controls the overall evaluation by activating/killing the NodeEvaluator instances.

Method Summary

TupleCollection
fetchData(ParameterOperand[] parameters)
This method executes the query on the underlying node.
long
getCacheSize()
EvaluationMetaData
getEvaluationMetaData()
Returns the evaluation meta data associated with this node evaluator.
QueryNode
getQueryNode()
Returns the QueryNode to which the NodeEvaluator is attached.
boolean
linkChildren()
Opens the links between the current NodeEvaluator and the NodeEvaluators of the children QueryTrees for pipelining operations.
void
setCacheSize(long cacheSize)
void
setPrefetchBuffer(PrefetchBuffer pb)
Associates a PrefetchBuffer to be filled by the collection computed by this evaluator.
boolean
unlinkChildren()
Closes the links between the current NodeEvaluator and the NodeEvaluators of the children QueryTrees for pipelining operations.

Method Details

fetchData

public TupleCollection fetchData(ParameterOperand[] parameters)
            throws MedorException
This method executes the query on the underlying node. It controls the evaluation locally for this node. It returns the TupleCollection containing the result of the execution.


getCacheSize

public long getCacheSize()


getEvaluationMetaData

public EvaluationMetaData getEvaluationMetaData()
Returns the evaluation meta data associated with this node evaluator.

Returns:
the associated EvaluationMetaData


getQueryNode

public QueryNode getQueryNode()
Returns the QueryNode to which the NodeEvaluator is attached.


linkChildren

public boolean linkChildren()
Opens the links between the current NodeEvaluator and the NodeEvaluators of the children QueryTrees for pipelining operations. TODO complete comments


setCacheSize

public void setCacheSize(long cacheSize)


setPrefetchBuffer

public void setPrefetchBuffer(PrefetchBuffer pb)
            throws MedorException
Associates a PrefetchBuffer to be filled by the collection computed by this evaluator.

Parameters:
pb - The PrefetchBuffer to be filled.


unlinkChildren

public boolean unlinkChildren()
Closes the links between the current NodeEvaluator and the NodeEvaluators of the children QueryTrees for pipelining operations. TODO complete comments