Class LazyLongIterate
- java.lang.Object
-
- org.eclipse.collections.impl.utility.primitive.LazyLongIterate
-
public final class LazyLongIterate extends Object
LazyLongIterate is a factory class which creates "deferred" long iterables around the specified long iterables. A "deferred" long iterable performs some operation, such as filtering or transforming, when the result long iterable is iterated over. This makes the operation very memory efficient, because you don't have to create intermediate collections during the operation. This file was automatically generated from template file lazyPrimitiveIterate.stg.- Since:
- 5.0
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static LazyLongIterable
adapt(LongIterable iterable)
Creates a deferred long iterable for the specified long iterable.static <V> LazyIterable<V>
collect(LongIterable iterable, LongToObjectFunction<? extends V> function)
Creates a deferred transforming long iterable for the specified long iterable.static <V> LazyIterable<V>
collectIf(LongIterable iterable, LongPredicate predicate, LongToObjectFunction<? extends V> function)
Creates a deferred filtering and transforming long iterable for the specified long iterable.static LazyLongIterable
empty()
static <V> LazyIterable<V>
flatCollect(LongIterable iterable, LongToObjectFunction<? extends Iterable<V>> function)
Creates a deferred transforming and flattening long iterable for the specified long iterable.static LazyLongIterable
select(LongIterable iterable, LongPredicate predicate)
Creates a deferred filtering long iterable for the specified long iterable.static LazyLongIterable
tap(LongIterable iterable, LongProcedure procedure)
Creates a deferred tap iterable for the specified iterable.
-
-
-
Method Detail
-
adapt
public static LazyLongIterable adapt(LongIterable iterable)
Creates a deferred long iterable for the specified long iterable.
-
select
public static LazyLongIterable select(LongIterable iterable, LongPredicate predicate)
Creates a deferred filtering long iterable for the specified long iterable.
-
collect
public static <V> LazyIterable<V> collect(LongIterable iterable, LongToObjectFunction<? extends V> function)
Creates a deferred transforming long iterable for the specified long iterable.
-
flatCollect
public static <V> LazyIterable<V> flatCollect(LongIterable iterable, LongToObjectFunction<? extends Iterable<V>> function)
Creates a deferred transforming and flattening long iterable for the specified long iterable.- Since:
- 9.0
-
collectIf
public static <V> LazyIterable<V> collectIf(LongIterable iterable, LongPredicate predicate, LongToObjectFunction<? extends V> function)
Creates a deferred filtering and transforming long iterable for the specified long iterable.
-
empty
public static LazyLongIterable empty()
-
tap
public static LazyLongIterable tap(LongIterable iterable, LongProcedure procedure)
Creates a deferred tap iterable for the specified iterable.- Since:
- 9.0
-
-