Class TransformOneToManyIterable<I,O>
- java.lang.Object
-
- uk.gov.gchq.gaffer.commonutil.iterable.TransformOneToManyIterable<I,O>
-
- Type Parameters:
I
- The input iterable type.O
- the output iterable type.
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Iterable<O>
public abstract class TransformOneToManyIterable<I,O> extends Object implements Closeable, Iterable<O>
ATransformToMultiIterable
allowsIterable
s to be lazily validated and transformed without loading the entire iterable into memory. The easiest way to use this class is to create an anonymous inner class. This class is very similar toTransformOneToManyIterable
except that this class transforms one to many items.
-
-
Constructor Summary
Constructors Constructor Description TransformOneToManyIterable(Iterable<? extends I> input)
Constructs anTransformOneToManyIterable
with the given inputIterable
and no validation.TransformOneToManyIterable(Iterable<? extends I> input, Validator<I> validator)
TransformOneToManyIterable(Iterable<? extends I> input, Validator<I> validator, boolean skipInvalid)
TransformOneToManyIterable(Iterable<? extends I> input, Validator<I> validator, boolean skipInvalid, boolean autoClose)
Constructs anTransformOneToManyIterable
with the given inputs
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Iterator<O>
iterator()
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Constructor Detail
-
TransformOneToManyIterable
public TransformOneToManyIterable(Iterable<? extends I> input)
Constructs anTransformOneToManyIterable
with the given inputIterable
and no validation.- Parameters:
input
- the inputIterable
-
TransformOneToManyIterable
public TransformOneToManyIterable(Iterable<? extends I> input, Validator<I> validator)
Constructs anTransformOneToManyIterable
with the given inputIterable
andValidator
. Invalid items will throw anIllegalArgumentException
to be thrown.
-
TransformOneToManyIterable
public TransformOneToManyIterable(Iterable<? extends I> input, Validator<I> validator, boolean skipInvalid)
-
-