/** * Create a new Transformer that calls each transformer in turn, passing the * result into the next transformer. * * @param <T> the input/output type * @param transformers an array of transformers to chain * @return the transformer * @throws NullPointerException if the transformers array or any of the transformers is null * @see ChainedTransformer */ public static <T> Transformer<T, T> chainedTransformer( final Transformer<? super T, ? extends T>... transformers) { return ChainedTransformer.chainedTransformer(transformers); }
/** * Create a new Transformer that calls each transformer in turn, passing the * result into the next transformer. The ordering is that of the iterator() * method on the collection. * * @param <T> the input/output type * @param transformers a collection of transformers to chain * @return the transformer * @throws NullPointerException if the transformers collection or any of the transformers is null * @see ChainedTransformer */ public static <T> Transformer<T, T> chainedTransformer( final Collection<? extends Transformer<? super T, ? extends T>> transformers) { return ChainedTransformer.chainedTransformer(transformers); }