E - type of enumerated elements.final class SkipPipeProcessor<E> extends AbstractPipeProcessor<E,E>
SkipWhilePipeProcessor,
WhilePipeProcessorhasNextNeedsValue, nextOnSameSourceOnNoValue| Constructor and Description |
|---|
SkipPipeProcessor(long n)
Constructs a
SkipPipeProcessor that skips over n
elements. |
| Modifier and Type | Method and Description |
|---|---|
protected void |
clearOutputValue()
Clears the processed result after being returned by
AbstractPipeProcessor.retrieveOutputValue(). |
boolean |
hasOutputValue()
Gets whether processing was successful and the processor has a value
to yield.
|
boolean |
isInactive()
Gets whether the processor does not process any more and the pipeline
up to it should be discarded.
|
void |
processInputValue(E value)
Processes an input value in order to return a result, if any.
|
protected E |
retrieveOutputValue()
Retrieves the processed result produced by
AbstractPipeProcessor.processInputValue(Object). |
enqueueFilter, enqueueMap, getNext, getOutputValue, getSource, pushFrontFilter, pushFrontMap, setNext, setSourcepublic SkipPipeProcessor(long n)
SkipPipeProcessor that skips over n
elements.
The new SkipPipeProcessor stores its limit internally.
n - number of elements to skip.public void processInputValue(E value)
AbstractPipeProcessorThe result of processing must be stored internally.
processInputValue in class AbstractPipeProcessor<E,E>value - Value to process.AbstractPipeProcessor.hasOutputValue(),
AbstractPipeProcessor.getOutputValue()public boolean hasOutputValue()
AbstractPipeProcessor
If AbstractPipeProcessor.hasOutputValue() returns false than no internal
storage of input or output may take place.
hasOutputValue in class AbstractPipeProcessor<E,E>AbstractPipeProcessor.processInputValue(java.lang.Object),
AbstractPipeProcessor.getOutputValue()protected E retrieveOutputValue()
AbstractPipeProcessorAbstractPipeProcessor.processInputValue(Object).retrieveOutputValue in class AbstractPipeProcessor<E,E>AbstractPipeProcessor.getOutputValue(),
AbstractPipeProcessor.clearOutputValue()protected void clearOutputValue()
AbstractPipeProcessorAbstractPipeProcessor.retrieveOutputValue().clearOutputValue in class AbstractPipeProcessor<E,E>AbstractPipeProcessor.getOutputValue(),
AbstractPipeProcessor.retrieveOutputValue()public boolean isInactive()
AbstractPipeProcessor
AbstractPipeProcessor.isInactive() returning true is equivalent to the
situation when no matter with what value
AbstractPipeProcessor.processInputValue(Object) will be called,
AbstractPipeProcessor.hasOutputValue() will always return false.
Most processors have this function return false with the
exception of while and limit compositions. These will
turn completely inactive once a certain condition is met.
isInactive in class AbstractPipeProcessor<E,E>true if processing must stop, false otherwise.Copyright © 2016. All rights reserved.