public class Pipeline
extends java.lang.Object
Pipeline
allows applying multiple transforms on an input NDList
.Constructor and Description |
---|
Pipeline()
Creates a new instance of
Pipeline that has no Transform defined yet. |
Pipeline(Transform... transforms)
Creates a new instance of
Pipeline that can apply the given transforms on its input. |
Modifier and Type | Method and Description |
---|---|
Pipeline |
add(int index,
Transform transform)
|
Pipeline |
add(java.lang.String name,
Transform transform)
|
Pipeline |
add(Transform transform)
|
Pipeline |
insert(int position,
int index,
Transform transform)
|
Pipeline |
insert(int position,
java.lang.String name,
Transform transform)
|
Pipeline |
insert(int position,
Transform transform)
Inserts the given
Transform to the list of transforms at the given position. |
NDList |
transform(NDList input)
Applies the transforms configured in this object on the input
NDList . |
public Pipeline()
Pipeline
that has no Transform
defined yet.public Pipeline(Transform... transforms)
Pipeline
that can apply the given transforms on its input.
Since no keys are provided for these transforms, they will be applied to the first element
in the input NDList
when the transform
method is called on
this object.
transforms
- the transforms to be applied when the transform
method is called on this objectpublic Pipeline add(Transform transform)
Transform
to the list of transforms to be applied on the input when
the transform
method is called on this object.
Since no keys are provided for this Transform
, it will be applied to the first
element in the input NDList
.
transform
- the Transform
to be addedPipeline
public Pipeline insert(int position, Transform transform)
Transform
to the list of transforms at the given position.
Since no keys or indices are provided for this Transform
, it will be applied to
the first element in the input NDList
when the transform
method is called on this object.
position
- the position at which the Transform
must be insertedtransform
- the Transform
to be insertedPipeline