| Constructor and Description |
|---|
ListSequence() |
| Modifier and Type | Method and Description |
|---|---|
Sequence<T> |
append(java.lang.Iterable<T> iterable)
Append the elements of the given
Iterable to the end of this Sequence. |
Sequence<T> |
append(T... items)
Append the given elements to the end of this
Sequence. |
<U extends java.util.Collection<T>> |
collectInto(U collection)
Collect this
Sequence into the given Collection. |
static <T> Sequence<T> |
empty()
Create an empty
Sequence with no items. |
static <T> Sequence<T> |
from(java.util.List<T> list) |
java.util.Optional<T> |
get(long index) |
java.util.Iterator<T> |
iterator() |
java.util.Optional<T> |
last() |
Sequence<T> |
limit(long limit)
Limit the maximum number of results returned by this
Sequence. |
static <T> Sequence<T> |
of(T... items)
Create a
Sequence with one item. |
static <T> Sequence<T> |
of(T item)
Create a
Sequence with one item. |
Sequence<T> |
reverse() |
Sequence<T> |
shuffle() |
Sequence<T> |
shuffle(java.util.Random md) |
Sequence<T> |
skip(long skip)
Skip a set number of steps in this
Sequence. |
<S extends java.lang.Comparable<? super S>> |
sorted() |
Sequence<T> |
sorted(java.util.Comparator<? super T> comparator) |
java.util.stream.Stream<T> |
stream() |
abstract java.util.List<T> |
toList()
Collect the elements in this
Sequence into a List. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitadjacentEntries, adjacentPairs, all, any, append, append, batch, batch, chars, chars, collect, collect, collectInto, count, delimit, delimit, distinct, endingAt, endingAt, endingAtNull, entries, filter, filterBack, filterBack, filterForward, filterForward, first, flatten, flatten, from, from, from, from, from, generate, index, interleave, ints, ints, intsFromZero, join, join, longs, longs, longsFromZero, map, mapBack, mapBack, mapForward, mapForward, max, min, none, pairs, peek, peekBack, peekBack, peekForward, peekForward, prefix, range, range, range, recurse, recurse, reduce, reduce, removeAll, repeat, repeat, second, step, suffix, swap, third, toArray, toArray, toBiSequence, toChars, toCollection, toDoubles, toEntrySequence, toInts, toList, toLongs, toMap, toMap, toMap, toMap, toSet, toSet, toSortedMap, toSortedMap, toSortedSet, until, until, untilNull, window, windowpublic static <T> Sequence<T> empty()
SequenceSequence with no items.empty in interface Sequence<T>Sequence.of(Object),
Sequence.of(Object...),
Sequence.from(Iterable)public static <T> Sequence<T> of(T item)
SequenceSequence with one item.of in interface Sequence<T>Sequence.of(Object...),
Sequence.from(Iterable)public static <T> Sequence<T> of(T... items)
SequenceSequence with one item.of in interface Sequence<T>Sequence.of(Object...),
Sequence.from(Iterable)public static <T> Sequence<T> from(java.util.List<T> list)
public java.util.Iterator<T> iterator()
iterator in interface java.lang.Iterable<T>public Sequence<T> skip(long skip)
SequenceSequence.public Sequence<T> limit(long limit)
SequenceSequence.public abstract java.util.List<T> toList()
SequenceSequence into a List.public <U extends java.util.Collection<T>> U collectInto(U collection)
SequenceSequence into the given Collection.collectInto in interface Sequence<T>public Sequence<T> append(java.lang.Iterable<T> iterable)
SequenceIterable to the end of this Sequence.public Sequence<T> append(T... items)
SequenceSequence.public <S extends java.lang.Comparable<? super S>> Sequence<S> sorted()
public java.util.Optional<T> get(long index)
public java.util.Optional<T> last()