Uses of Interface
io.vavr.collection.Traversable
-
Packages that use Traversable Package Description io.vavr BesideAPI
the io.vavr package contains core types like (Checked)Functions and Tuples.io.vavr.collection Purely functional collections based on Traversable. -
-
Uses of Traversable in io.vavr
Methods in io.vavr with type parameters of type Traversable Modifier and Type Method Description static <T,R extends Traversable<T>>
RValueModule. toTraversable(Value<T> value, R empty, java.util.function.Function<T,R> ofElement, java.util.function.Function<java.lang.Iterable<T>,R> ofAll)
-
Uses of Traversable in io.vavr.collection
Classes in io.vavr.collection with type parameters of type Traversable Modifier and Type Class Description private static class
JavaConverters.HasDelegate<C extends Traversable<?>>
Encapsulates the access to delegate and performs mutability checks.Subinterfaces of Traversable in io.vavr.collection Modifier and Type Interface Description interface
BitSet<T>
An immutableBitSet
implementation.interface
IndexedSeq<T>
Interface for immutable, indexed sequences.interface
Iterator<T>
io.vavr.collection.Iterator
is a compositional replacement forjava.util.Iterator
whose purpose is to iterate once over a sequence of elements.interface
LinearSeq<T>
Interface for immutable, linear sequences.interface
List<T>
An immutableList
is an eager sequence of elements.interface
Map<K,V>
An immutableMap
interface.interface
Multimap<K,V>
An immutableMultimap
interface.interface
Seq<T>
Interface for immutable sequential data structures.interface
Set<T>
An immutableSet
interface.interface
SortedMap<K,V>
An immutableSortedMap
interface.interface
SortedMultimap<K,V>
An immutableSortedMultimap
interface.interface
SortedSet<T>
An immutableSortedSet
interface.interface
Stream<T>
An immutableStream
is lazy sequence of elements which may be infinitely long.interface
Tree<T>
A general Tree interface.Classes in io.vavr.collection that implement Traversable Modifier and Type Class Description (package private) class
AbstractIterator<T>
Provides a commonObject.toString()
implementation.(package private) class
AbstractMultimap<K,V,M extends Multimap<K,V>>
AnMultimap
implementation (not intended to be public).(package private) class
AbstractQueue<T,Q extends AbstractQueue<T,Q>>
class
Array<T>
Array is a Traversable wrapper forObject[]
containing elements of typeT
.static class
BitSetModule.AbstractBitSet<T>
static class
BitSetModule.BitSet1<T>
static class
BitSetModule.BitSet2<T>
static class
BitSetModule.BitSetIterator<T>
static class
BitSetModule.BitSetN<T>
class
CharSeq
The CharSeq (read: character sequence) collection essentially is a rich String wrapper having all operations we know from the functional Vavr collections.static class
HashArrayMappedTrieModule.LeafNodeIterator<K,V>
class
HashMap<K,V>
An immutableHashMap
implementation based on a Hash array mapped trie (HAMT).class
HashMultimap<K,V>
class
HashSet<T>
An immutableHashSet
implementation.static class
IteratorModule.CachedIterator<T>
static class
IteratorModule.ConcatIterator<T>
static class
IteratorModule.DistinctIterator<T,U>
static class
IteratorModule.EmptyIterator
static class
IteratorModule.GroupedIterator<T>
class
LinkedHashMap<K,V>
An immutableLinkedHashMap
implementation that has predictable (insertion-order) iteration.class
LinkedHashMultimap<K,V>
ALinkedHashMap
-based implementation ofMultimap
class
LinkedHashSet<T>
An immutableHashSet
implementation that has predictable (insertion-order) iteration.static class
List.Cons<T>
Non-emptyList
, consisting of ahead
and atail
.static class
List.Nil<T>
Representation of the singleton emptyList
.class
PriorityQueue<T>
A PriorityQueue.class
Queue<T>
An immutableQueue
stores elements allowing a first-in-first-out (FIFO) retrieval.static class
Stream.Cons<T>
Non-emptyStream
, consisting of ahead
, andtail
.static class
Stream.Empty<T>
The empty Stream.static class
StreamModule.AppendElements<T>
static class
StreamModule.ConsImpl<T>
static class
StreamModule.FlatMapIterator<T,U>
static class
StreamModule.StreamIterator<T>
static class
Tree.Empty<T>
The empty tree.static class
Tree.Node<T>
Represents a tree node.class
TreeMap<K,V>
SortedMap implementation, backed by a Red/Black Tree.class
TreeMultimap<K,V>
class
TreeSet<T>
SortedSet implementation, backed by a Red/Black Tree.class
Vector<T>
Vector is the default Seq implementation that provides effectively constant time access to any element.Fields in io.vavr.collection declared as Traversable Modifier and Type Field Description private C
JavaConverters.HasDelegate. delegate
Fields in io.vavr.collection with type parameters of type Traversable Modifier and Type Field Description private java.util.function.BiFunction<Traversable<?>,java.lang.Object,Traversable<?>>
Multimap.ContainerType. add
private java.util.function.BiFunction<Traversable<?>,java.lang.Object,Traversable<?>>
Multimap.ContainerType. add
protected Map<K,Traversable<V>>
AbstractMultimap. back
protected AbstractMultimap.SerializableSupplier<Traversable<?>>
AbstractMultimap. emptyContainer
private AbstractMultimap.SerializableSupplier<Traversable<?>>
HashMultimap.Builder. emptyContainer
private AbstractMultimap.SerializableSupplier<Traversable<?>>
LinkedHashMultimap.Builder. emptyContainer
private AbstractMultimap.SerializableSupplier<Traversable<?>>
TreeMultimap.Builder. emptyContainer
private java.util.function.BiFunction<Traversable<?>,java.lang.Object,Traversable<?>>
Multimap.ContainerType. remove
private java.util.function.BiFunction<Traversable<?>,java.lang.Object,Traversable<?>>
Multimap.ContainerType. remove
Methods in io.vavr.collection with type parameters of type Traversable Modifier and Type Method Description (package private) static <C extends Traversable<T>,T>
CCollections. fill(int n, java.util.function.Supplier<? extends T> s, C empty, java.util.function.Function<T[],C> of)
(package private) static <C extends Traversable<T>,T>
CCollections. fillObject(int n, T element, C empty, java.util.function.Function<T[],C> of)
(package private) static <C extends Traversable<T>,T>
Tuple2<C,C>Collections. partition(C collection, java.util.function.Function<java.lang.Iterable<T>,C> creator, java.util.function.Predicate<? super T> predicate)
(package private) static <C extends Traversable<T>,T>
CCollections. reject(C source, java.util.function.Predicate<? super T> predicate)
(package private) static <C extends Traversable<T>,T>
CCollections. removeAll(C source, java.lang.Iterable<? extends T> elements)
(package private) static <C extends Traversable<T>,T>
CCollections. removeAll(C source, T element)
(package private) static <C extends Traversable<T>,T>
CCollections. retainAll(C source, java.lang.Iterable<? extends T> elements)
(package private) static <T,U,R extends Traversable<U>>
RCollections. scanLeft(Traversable<? extends T> source, U zero, java.util.function.BiFunction<? super U,? super T,? extends U> operation, java.util.function.Function<Iterator<U>,R> finisher)
(package private) static <T,U,R extends Traversable<U>>
RCollections. scanRight(Traversable<? extends T> source, U zero, java.util.function.BiFunction<? super T,? super U,? extends U> operation, java.util.function.Function<Iterator<U>,R> finisher)
(package private) static <C extends Traversable<T>,T>
CCollections. tabulate(int n, java.util.function.Function<? super java.lang.Integer,? extends T> f, C empty, java.util.function.Function<T[],C> of)
Methods in io.vavr.collection that return Traversable Modifier and Type Method Description (package private) <T> Traversable<T>
Multimap.ContainerType. add(Traversable<?> container, T elem)
default Traversable<V>
Multimap. apply(K key)
Deprecated.<R> Traversable<R>
Traversable. collect(PartialFunction<? super T,? extends R> partialFunction)
Collects all elements that are in the domain of the givenpartialFunction
by mapping the elements to typeR
.Traversable<T>
Traversable. distinct()
Returns a new version of this which contains no duplicates.Traversable<T>
Traversable. distinctBy(java.util.Comparator<? super T> comparator)
Returns a new version of this which contains no duplicates.<U> Traversable<T>
Traversable. distinctBy(java.util.function.Function<? super T,? extends U> keyExtractor)
Returns a new version of this which contains no duplicates.Traversable<T>
Traversable. drop(int n)
Drops the first n elements of this or all elements, if this length < n.Traversable<T>
Traversable. dropRight(int n)
Drops the last n elements of this or all elements, if this length < n.Traversable<T>
Traversable. dropUntil(java.util.function.Predicate<? super T> predicate)
Drops elements until the predicate holds for the current element.Traversable<T>
Traversable. dropWhile(java.util.function.Predicate<? super T> predicate)
Drops elements while the predicate holds for the current element.Traversable<T>
Traversable. filter(java.util.function.Predicate<? super T> predicate)
Returns a new traversable consisting of all elements which satisfy the given predicate.<U> Traversable<U>
Traversable. flatMap(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends U>> mapper)
FlatMaps this Traversable.Traversable<V>
AbstractMultimap. getOrElse(K key, Traversable<? extends V> defaultValue)
Traversable<V>
Multimap. getOrElse(K key, Traversable<? extends V> defaultValue)
Returns the value associated with a key, or a default value if the key is not contained in the mapTraversable<T>
Traversable. init()
Dual of tail(), returning all elements except the last.<U> Traversable<U>
Traversable. map(java.util.function.Function<? super T,? extends U> mapper)
Maps the elements of thisTraversable
to elements of a new type preserving their order, if any.static <T> Traversable<T>
Traversable. narrow(Traversable<? extends T> traversable)
Narrows a widenedTraversable<? extends T>
toTraversable<T>
by performing a type-safe cast.Traversable<T>
Traversable. orElse(java.lang.Iterable<? extends T> other)
Returns thisTraversable
if it is nonempty, otherwise return the alternative.Traversable<T>
Traversable. orElse(java.util.function.Supplier<? extends java.lang.Iterable<? extends T>> supplier)
Returns thisTraversable
if it is nonempty, otherwise return the result of evaluating supplier.Traversable<T>
Traversable. peek(java.util.function.Consumer<? super T> action)
default Traversable<T>
Traversable. reject(java.util.function.Predicate<? super T> predicate)
Returns a new traversable consisting of all elements which do not satisfy the given predicate.(package private) <T> Traversable<T>
Multimap.ContainerType. remove(Traversable<?> container, T elem)
Traversable<T>
Traversable. replace(T currentElement, T newElement)
Replaces the first occurrence (if exists) of the given currentElement with newElement.Traversable<T>
Traversable. replaceAll(T currentElement, T newElement)
Replaces all occurrences of the given currentElement with newElement.Traversable<T>
Traversable. retainAll(java.lang.Iterable<? extends T> elements)
Keeps all occurrences of the given elements from this.default Traversable<T>
Iterator. scan(T zero, java.util.function.BiFunction<? super T,? super T,? extends T> operation)
Traversable<T>
Traversable. scan(T zero, java.util.function.BiFunction<? super T,? super T,? extends T> operation)
Computes a prefix scan of the elements of the collection.<U> Traversable<U>
Traversable. scanLeft(U zero, java.util.function.BiFunction<? super U,? super T,? extends U> operation)
Produces a collection containing cumulative results of applying the operator going left to right.<U> Traversable<U>
Traversable. scanRight(U zero, java.util.function.BiFunction<? super T,? super U,? extends U> operation)
Produces a collection containing cumulative results of applying the operator going right to left.Traversable<T>
Traversable. tail()
Drops the first element of a non-empty Traversable.Traversable<T>
Traversable. take(int n)
Takes the first n elements of this or all elements, if this length < n.Traversable<T>
Traversable. takeRight(int n)
Takes the last n elements of this or all elements, if this length < n.Traversable<T>
Traversable. takeUntil(java.util.function.Predicate<? super T> predicate)
Takes elements until the predicate holds for the current element.Traversable<T>
Traversable. takeWhile(java.util.function.Predicate<? super T> predicate)
Takes elements while the predicate holds for the current element.Traversable<V>
AbstractMultimap. values()
Traversable<V>
Multimap. values()
<U> Traversable<Tuple2<T,U>>
Traversable. zip(java.lang.Iterable<? extends U> that)
Returns a traversable formed from this traversable and another Iterable collection by combining corresponding elements in pairs.<U> Traversable<Tuple2<T,U>>
Traversable. zipAll(java.lang.Iterable<? extends U> that, T thisElem, U thatElem)
Returns a traversable formed from this traversable and another Iterable by combining corresponding elements in pairs.<U,R>
Traversable<R>Traversable. zipWith(java.lang.Iterable<? extends U> that, java.util.function.BiFunction<? super T,? super U,? extends R> mapper)
Returns a traversable formed from this traversable and another Iterable collection by mapping elements.Traversable<Tuple2<T,java.lang.Integer>>
Traversable. zipWithIndex()
Zips this traversable with its indices.<U> Traversable<U>
Traversable. zipWithIndex(java.util.function.BiFunction<? super T,? super java.lang.Integer,? extends U> mapper)
Zips this traversable with its indices by applying mapper provided.Methods in io.vavr.collection that return types with arguments of type Traversable Modifier and Type Method Description Map<K,Traversable<V>>
AbstractMultimap. asMap()
Map<K,Traversable<V>>
Multimap. asMap()
Converts thisMultimap
to aMap
default PartialFunction<K,Traversable<V>>
Multimap. asPartialFunction()
Turns thisMultimap
into aPartialFunction
which is defined at a specific index, if thisMultimap
contains the given key.Option<Traversable<V>>
AbstractMultimap. get(K key)
Option<Traversable<V>>
Multimap. get(K key)
Returns theSome
of value to which the specified key is mapped, orNone
if this multimap contains no mapping for the key.<C> Map<C,? extends Traversable<T>>
Traversable. groupBy(java.util.function.Function<? super T,? extends C> classifier)
Groups this elements by classifying the elements.Iterator<? extends Traversable<T>>
Traversable. grouped(int size)
Groups thisTraversable
into fixed size blocks.default Option<? extends Traversable<T>>
Traversable. initOption()
Dual of tailOption(), returning all elements except the last asOption
.Tuple2<? extends Traversable<T>,? extends Traversable<T>>
Traversable. partition(java.util.function.Predicate<? super T> predicate)
Creates a partition of thisTraversable
by splitting this elements in two in distinct traversables according to a predicate.Tuple2<? extends Traversable<T>,? extends Traversable<T>>
Traversable. partition(java.util.function.Predicate<? super T> predicate)
Creates a partition of thisTraversable
by splitting this elements in two in distinct traversables according to a predicate.Iterator<? extends Traversable<T>>
Traversable. slideBy(java.util.function.Function<? super T,?> classifier)
Slides a non-overlapping window of a variable size over thisTraversable
.Iterator<? extends Traversable<T>>
Traversable. sliding(int size)
Slides a window of a specificsize
and step size 1 over thisTraversable
by callingsliding(int, int)
.Iterator<? extends Traversable<T>>
Traversable. sliding(int size, int step)
Slides a window of a specificsize
andstep
size over thisTraversable
.Tuple2<? extends Traversable<T>,? extends Traversable<T>>
Traversable. span(java.util.function.Predicate<? super T> predicate)
Returns a tuple where the first element is the longest prefix of elements that satisfy the givenpredicate
and the second element is the remainder.Tuple2<? extends Traversable<T>,? extends Traversable<T>>
Traversable. span(java.util.function.Predicate<? super T> predicate)
Returns a tuple where the first element is the longest prefix of elements that satisfy the givenpredicate
and the second element is the remainder.Option<? extends Traversable<T>>
Traversable. tailOption()
Drops the first element of a non-empty Traversable and returns anOption
.<T1,T2>
Tuple2<? extends Traversable<T1>,? extends Traversable<T2>>Traversable. unzip(java.util.function.Function<? super T,Tuple2<? extends T1,? extends T2>> unzipper)
Unzips this elements by mapping this elements to pairs which are subsequently split into two distinct sets.<T1,T2>
Tuple2<? extends Traversable<T1>,? extends Traversable<T2>>Traversable. unzip(java.util.function.Function<? super T,Tuple2<? extends T1,? extends T2>> unzipper)
Unzips this elements by mapping this elements to pairs which are subsequently split into two distinct sets.<T1,T2,T3>
Tuple3<? extends Traversable<T1>,? extends Traversable<T2>,? extends Traversable<T3>>Traversable. unzip3(java.util.function.Function<? super T,Tuple3<? extends T1,? extends T2,? extends T3>> unzipper)
Unzips this elements by mapping this elements to triples which are subsequently split into three distinct sets.<T1,T2,T3>
Tuple3<? extends Traversable<T1>,? extends Traversable<T2>,? extends Traversable<T3>>Traversable. unzip3(java.util.function.Function<? super T,Tuple3<? extends T1,? extends T2,? extends T3>> unzipper)
Unzips this elements by mapping this elements to triples which are subsequently split into three distinct sets.<T1,T2,T3>
Tuple3<? extends Traversable<T1>,? extends Traversable<T2>,? extends Traversable<T3>>Traversable. unzip3(java.util.function.Function<? super T,Tuple3<? extends T1,? extends T2,? extends T3>> unzipper)
Unzips this elements by mapping this elements to triples which are subsequently split into three distinct sets.Methods in io.vavr.collection with parameters of type Traversable Modifier and Type Method Description (package private) <T> Traversable<T>
Multimap.ContainerType. add(Traversable<?> container, T elem)
Traversable<V>
AbstractMultimap. getOrElse(K key, Traversable<? extends V> defaultValue)
Traversable<V>
Multimap. getOrElse(K key, Traversable<? extends V> defaultValue)
Returns the value associated with a key, or a default value if the key is not contained in the mapprivate static <T,C>
java.util.Set<java.util.Map.Entry<C,java.util.Collection<T>>>Collections. groupBy(Traversable<T> source, java.util.function.Function<? super T,? extends C> classifier)
(package private) static <T,C,R extends java.lang.Iterable<T>>
Map<C,R>Collections. groupBy(Traversable<T> source, java.util.function.Function<? super T,? extends C> classifier, java.util.function.Function<? super java.lang.Iterable<T>,R> mapper)
(package private) static <T> T
Collections. last(Traversable<T> source)
static <T> Traversable<T>
Traversable. narrow(Traversable<? extends T> traversable)
Narrows a widenedTraversable<? extends T>
toTraversable<T>
by performing a type-safe cast.(package private) <T> Traversable<T>
Multimap.ContainerType. remove(Traversable<?> container, T elem)
(package private) static <T,U,R extends Traversable<U>>
RCollections. scanLeft(Traversable<? extends T> source, U zero, java.util.function.BiFunction<? super U,? super T,? extends U> operation, java.util.function.Function<Iterator<U>,R> finisher)
(package private) static <T,U,R extends Traversable<U>>
RCollections. scanRight(Traversable<? extends T> source, U zero, java.util.function.BiFunction<? super T,? super U,? extends U> operation, java.util.function.Function<Iterator<U>,R> finisher)
Method parameters in io.vavr.collection with type arguments of type Traversable Modifier and Type Method Description protected abstract <K2,V2>
Multimap<K2,V2>AbstractMultimap. createFromMap(Map<K2,Traversable<V2>> back)
protected <K2,V2>
HashMultimap<K2,V2>HashMultimap. createFromMap(Map<K2,Traversable<V2>> back)
protected <K2,V2>
LinkedHashMultimap<K2,V2>LinkedHashMultimap. createFromMap(Map<K2,Traversable<V2>> back)
protected <K2,V2>
TreeMultimap<K2,V2>TreeMultimap. createFromMap(Map<K2,Traversable<V2>> back)
<K2 extends K,V2 extends V>
MAbstractMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
<K2 extends K,V2 extends V>
MAbstractMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
<K2 extends K,V2 extends V>
MAbstractMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
<K2 extends K,V2 extends V>
Multimap<K,V>Multimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
Creates a new multimap which by merging the entries ofthis
multimap andthat
multimap.<K2 extends K,V2 extends V>
Multimap<K,V>Multimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
Creates a new multimap which by merging the entries ofthis
multimap andthat
multimap.<K2 extends K,V2 extends V>
Multimap<K,V>Multimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
Creates a new multimap which by merging the entries ofthis
multimap andthat
multimap.<K2 extends K,V2 extends V>
SortedMultimap<K,V>SortedMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
<K2 extends K,V2 extends V>
SortedMultimap<K,V>SortedMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
<K2 extends K,V2 extends V>
SortedMultimap<K,V>SortedMultimap. merge(Multimap<K2,V2> that, java.util.function.BiFunction<Traversable<V>,Traversable<V2>,Traversable<V>> collisionResolution)
(package private) static <K,V,M extends Map<K,V>>
MMaps. scan(M map, Tuple2<K,V> zero, java.util.function.BiFunction<? super Tuple2<K,V>,? super Tuple2<K,V>,? extends Tuple2<K,V>> operation, java.util.function.Function<Iterator<Tuple2<K,V>>,Traversable<Tuple2<K,V>>> finisher)
-