O
- the type of the operation that are processed by this navigator processorpublic class NavigationProcessorWrapper<O extends AbstractOperation> extends java.lang.Object implements NavigationProcessor<O>
NavigationProcessor
that delegates the methods
to an encapsulated NavigationProcessor
.Modifier and Type | Field and Description |
---|---|
protected NavigationProcessor<O> |
navigationProcessor
Encapsulated navigation processor
|
Constructor and Description |
---|
NavigationProcessorWrapper(NavigationProcessor<O> navigationProcessor)
Creates a new wrapper for the given navigation processor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Method to be called after processing all the steps.
|
O |
getOperation()
Returns the operation for which this navigator was created.
|
int |
getProcessedCount()
Returns the number of processing steps already evaluated by this processor.
|
int |
getRemainingCount()
Returns the number of the remaining processing steps.
|
boolean |
isFinished()
Returns whether this processor is finished.
|
boolean |
processStep()
Processes the encapsulated operation by the next processing step.
|
protected final NavigationProcessor<O extends AbstractOperation> navigationProcessor
public NavigationProcessorWrapper(NavigationProcessor<O> navigationProcessor)
navigationProcessor
- the processor to wrappublic boolean processStep() throws java.lang.InterruptedException, AlgorithmMethodException, java.lang.CloneNotSupportedException
NavigationProcessor
processStep
in interface NavigationProcessor<O extends AbstractOperation>
java.lang.InterruptedException
- if the thread processing the step is interruptedAlgorithmMethodException
- if an error occurred during the evaluation of the processing stepjava.lang.CloneNotSupportedException
- if there was a need for cloning (due to asynchronous access) but cloning was not supportedpublic boolean isFinished()
NavigationProcessor
NavigationProcessor.processStep()
returns false.isFinished
in interface NavigationProcessor<O extends AbstractOperation>
NavigationProcessor.processStep()
is possible or
true if this processor has finishedpublic int getRemainingCount()
NavigationProcessor
getRemainingCount
in interface NavigationProcessor<O extends AbstractOperation>
public int getProcessedCount()
NavigationProcessor
getProcessedCount
in interface NavigationProcessor<O extends AbstractOperation>
public O getOperation()
NavigationProcessor
getOperation
in interface NavigationProcessor<O extends AbstractOperation>
public void close()
NavigationProcessor
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in interface NavigationProcessor<O extends AbstractOperation>