Package org.reactfx.util
Class LL<T>
- java.lang.Object
-
- org.reactfx.util.LL<T>
-
-
Constructor Summary
Constructors Modifier Constructor Description private
LL()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description boolean
all(java.util.function.Predicate<T> cond)
static <T> LL<? extends T>
concat(LL<? extends T> l1, LL<? extends T> l2)
static <T> LL.Cons<T>
cons(T head, LL<? extends T> tail)
abstract <R> R
fold(R acc, java.util.function.BiFunction<? super R,? super T,? extends R> reduction)
abstract T
head()
abstract boolean
isEmpty()
abstract <U> LL<U>
map(java.util.function.Function<? super T,? extends U> f)
<U> U
mapFirst2(java.util.function.BiFunction<? super T,? super T,? extends U> f)
<U> U
mapFirst3(TriFunction<? super T,? super T,? super T,? extends U> f)
<U> U
mapFirst4(TetraFunction<? super T,? super T,? super T,? super T,? extends U> f)
<U> U
mapFirst5(PentaFunction<? super T,? super T,? super T,? super T,? super T,? extends U> f)
<U> U
mapFirst6(HexaFunction<? super T,? super T,? super T,? super T,? super T,? super T,? extends U> f)
abstract <R> java.util.Optional<R>
mapReduce(java.util.function.Function<? super T,? extends R> map, java.util.function.BinaryOperator<R> reduce)
static <T> LL<T>
nil()
private static <T> LL<T>
of(T[] elems, int to, LL<T> tail)
static <T> LL.Cons<T>
of(T head, T... tail)
abstract int
size()
java.util.stream.Stream<T>
stream()
abstract LL<? extends T>
tail()
java.lang.String
toString()
-
-
-
Method Detail
-
nil
public static <T> LL<T> nil()
-
of
@SafeVarargs public static <T> LL.Cons<T> of(T head, T... tail)
-
isEmpty
public abstract boolean isEmpty()
-
size
public abstract int size()
-
head
public abstract T head()
-
fold
public abstract <R> R fold(R acc, java.util.function.BiFunction<? super R,? super T,? extends R> reduction)
-
mapReduce
public abstract <R> java.util.Optional<R> mapReduce(java.util.function.Function<? super T,? extends R> map, java.util.function.BinaryOperator<R> reduce)
-
all
public boolean all(java.util.function.Predicate<T> cond)
-
mapFirst2
public <U> U mapFirst2(java.util.function.BiFunction<? super T,? super T,? extends U> f)
-
mapFirst3
public <U> U mapFirst3(TriFunction<? super T,? super T,? super T,? extends U> f)
-
mapFirst4
public <U> U mapFirst4(TetraFunction<? super T,? super T,? super T,? super T,? extends U> f)
-
mapFirst5
public <U> U mapFirst5(PentaFunction<? super T,? super T,? super T,? super T,? super T,? extends U> f)
-
mapFirst6
public <U> U mapFirst6(HexaFunction<? super T,? super T,? super T,? super T,? super T,? super T,? extends U> f)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
stream
public java.util.stream.Stream<T> stream()
-
-