Class LazyLongIterate
- java.lang.Object
-
- org.eclipse.collections.impl.utility.primitive.LazyLongIterate
-
public final class LazyLongIterate extends java.lang.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
-
-
Field Summary
Fields Modifier and Type Field Description private static LazyLongIterable
EMPTY_ITERABLE
-
Constructor Summary
Constructors Modifier Constructor Description private
LazyLongIterate()
-
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 java.lang.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.
-
-
-
Field Detail
-
EMPTY_ITERABLE
private static final LazyLongIterable EMPTY_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 java.lang.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
-
-