T - type of item this stage operates upon@ThreadSafe public abstract class BaseStage<T> extends net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent implements Stage<T>
Stage implementations.| Modifier and Type | Field and Description |
|---|---|
private com.google.common.base.Predicate<Collection<Item<T>>> |
collectionPredicate
The
Predicate applied to the supplied item collection to determine whether the stage will be executed. |
| Constructor and Description |
|---|
BaseStage() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
doExecute(Collection<Item<T>> itemCollection)
Performs the stage processing on the given Item collection.
|
void |
execute(Collection<Item<T>> itemCollection)
Creates an
ComponentInfo, delegates actual work on the collection to doExecute(Collection), adds
the ComponentInfo to all the resultant Item elements and then sets its completion time. |
com.google.common.base.Predicate<Collection<Item<T>>> |
getCollectionPredicate()
Gets the
Predicate being applied to the supplied item collection to determine whether
the stage will be executed. |
void |
setCollectionPredicate(com.google.common.base.Predicate<Collection<Item<T>>> pred)
Sets the
Predicate applied to the supplied item collection to determine whether
the stage will be executed. |
setIddoInitialize, getIddestroy, doDestroy, initialize, isDestroyed, isInitializedclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdestroy, isDestroyed@Nonnull private com.google.common.base.Predicate<Collection<Item<T>>> collectionPredicate
Predicate applied to the supplied item collection to determine whether the stage will be executed.
Default value: always true.public void setCollectionPredicate(@Nonnull com.google.common.base.Predicate<Collection<Item<T>>> pred)
Predicate applied to the supplied item collection to determine whether
the stage will be executed.pred - the Predicate applied to the supplied item collection to determine
whether the stage will be executed@Nonnull public com.google.common.base.Predicate<Collection<Item<T>>> getCollectionPredicate()
Predicate being applied to the supplied item collection to determine whether
the stage will be executed.Predicate being applied to the supplied item collection to determine whether
the stage will be executed.public void execute(@Nonnull@NonnullElements Collection<Item<T>> itemCollection) throws StageProcessingException
ComponentInfo, delegates actual work on the collection to doExecute(Collection), adds
the ComponentInfo to all the resultant Item elements and then sets its completion time.
Transforms the given input data.execute in interface Stage<T>itemCollection - the data to be transformedStageProcessingException - thrown if there is a problem running this stage on the given inputprotected abstract void doExecute(@Nonnull@NonnullElements Collection<Item<T>> itemCollection) throws StageProcessingException
The stage is guaranteed to be have been initialized and not destroyed when this is invoked.
itemCollection - collection to be processedStageProcessingException - thrown if there is an unrecoverable problem when processing the stageCopyright © 1999–2016. All rights reserved.