Class UnaryExecutableOpBase
java.lang.Object
se.liu.ida.hefquin.engine.queryplan.executable.impl.ops.BaseForExecOps
se.liu.ida.hefquin.engine.queryplan.executable.impl.ops.UnaryExecutableOpBase
- All Implemented Interfaces:
StatsProvider,ExecutableOperator,UnaryExecutableOp
- Direct Known Subclasses:
BaseForExecOpBindJoin,BaseForExecOpIndexNestedLoopsJoin,ExecOpParallelMultiwayLeftJoin,UnaryExecutableOpBaseWithIterator
Top-level base class for all implementations of
UnaryExecutableOp.
This base class handles the collection of statistics about both the input
and the processing times per input block. To this end, it implements the
major methods of the UnaryExecutableOp interface, where the actual
functionality to be implemented for these methods needs to be provided by
implementing two abstract functions in each sub-class of this base class.
These two functions are:
-
Field Summary
FieldsFields inherited from class se.liu.ida.hefquin.engine.queryplan.executable.impl.ops.BaseForExecOps
collectExceptions -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract void_concludeExecution(IntermediateResultElementSink sink, ExecutionContext execCxt) Implementations of this function need to conclude the execution of this operator and send the remaining result elements (if any) to the given sink.protected abstract void_process(IntermediateResultBlock input, IntermediateResultElementSink sink, ExecutionContext execCxt) Implementations of this function need to process the given input block and send the produced result elements (if any) to the given sink.final voidconcludeExecution(IntermediateResultElementSink sink, ExecutionContext execCxt) Concludes the execution of this operator and sends the remaining result elements (if any) to the given sink.protected ExecutableOperatorStatsImplfinal ExecutableOperatorStatsgetStats()final voidprocess(IntermediateResultBlock input, IntermediateResultElementSink sink, ExecutionContext execCxt) Processes the given input and sends the produced result elements (if any) to the given sink.voidMethods inherited from class se.liu.ida.hefquin.engine.queryplan.executable.impl.ops.BaseForExecOps
getExceptionsCaughtDuringExecution, recordExceptionCaughtDuringExecutionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface se.liu.ida.hefquin.engine.queryplan.executable.ExecutableOperator
getExceptionsCaughtDuringExecutionMethods inherited from interface se.liu.ida.hefquin.engine.queryplan.executable.UnaryExecutableOp
preferredInputBlockSize
-
Field Details
-
timeAtCurrentProcStart
protected long timeAtCurrentProcStart
-
-
Constructor Details
-
UnaryExecutableOpBase
public UnaryExecutableOpBase(boolean collectExceptions)
-
-
Method Details
-
process
public final void process(IntermediateResultBlock input, IntermediateResultElementSink sink, ExecutionContext execCxt) throws ExecOpExecutionException Description copied from interface:UnaryExecutableOpProcesses the given input and sends the produced result elements (if any) to the given sink.- Specified by:
processin interfaceUnaryExecutableOp- Throws:
ExecOpExecutionException
-
concludeExecution
public final void concludeExecution(IntermediateResultElementSink sink, ExecutionContext execCxt) throws ExecOpExecutionException Description copied from interface:UnaryExecutableOpConcludes the execution of this operator and sends the remaining result elements (if any) to the given sink. This method will be called only once, after the sub-plan that produces the input for this operator has finished producing its result.- Specified by:
concludeExecutionin interfaceUnaryExecutableOp- Throws:
ExecOpExecutionException
-
_process
protected abstract void _process(IntermediateResultBlock input, IntermediateResultElementSink sink, ExecutionContext execCxt) throws ExecOpExecutionException Implementations of this function need to process the given input block and send the produced result elements (if any) to the given sink. If an exception occurs while processing the input block, this exception needs to either be collected or be thrown, depending on whetherBaseForExecOps.collectExceptionsis set totrue.- Throws:
ExecOpExecutionException
-
_concludeExecution
protected abstract void _concludeExecution(IntermediateResultElementSink sink, ExecutionContext execCxt) throws ExecOpExecutionException Implementations of this function need to conclude the execution of this operator and send the remaining result elements (if any) to the given sink. If an exception occurs during this process, then this exception needs to either be collected or be thrown, depending on whetherBaseForExecOps.collectExceptionsis set totrue.- Throws:
ExecOpExecutionException
-
resetStats
public void resetStats()- Specified by:
resetStatsin interfaceStatsProvider
-
getStats
- Specified by:
getStatsin interfaceExecutableOperator- Specified by:
getStatsin interfaceStatsProvider
-
createStats
-