Package org.sosy_lab.common.collect
Class MoreCollectors
- java.lang.Object
-
- org.sosy_lab.common.collect.MoreCollectors
-
public final class MoreCollectors extends Object
AdditionalCollectorimplementation, similar toCollectors.
-
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static <T> Collector<T,?,ImmutableList<T>>toImmutableList()Deprecated.static <T> Collector<T,?,ImmutableSet<T>>toImmutableSet()Deprecated.static <T> Collector<T,?,PersistentLinkedList<T>>toPersistentLinkedList()Deprecated.
-
-
-
Method Detail
-
toPersistentLinkedList
@Deprecated @InlineMe(replacement="PersistentLinkedList.toPersistentLinkedList()", imports="org.sosy_lab.common.collect.PersistentLinkedList") public static <T> Collector<T,?,PersistentLinkedList<T>> toPersistentLinkedList()
Deprecated.Return aCollectorthat producesPersistentLinkedLists.
-
toImmutableList
@Deprecated @InlineMe(replacement="ImmutableList.toImmutableList()", imports="com.google.common.collect.ImmutableList") public static <T> Collector<T,?,ImmutableList<T>> toImmutableList()
Deprecated.Return aCollectorthat producesImmutableLists.Prefer to use this over
Collectors.toList()! The latter does neither guarantee mutability nor immutability, so if you want immutability, use this method, and if you need mutability, useCollectors.toCollection(ArrayList::new).
-
toImmutableSet
@Deprecated @InlineMe(replacement="ImmutableSet.toImmutableSet()", imports="com.google.common.collect.ImmutableSet") public static <T> Collector<T,?,ImmutableSet<T>> toImmutableSet()
Deprecated.Return aCollectorthat producesImmutableSets. Just like the usual methods for ImmutableSets, this collector guarantees to keep the order.Prefer to use this over
Collectors.toSet()! The latter does neither guarantee mutability nor immutability, so if you want immutability, use this method, and if you need mutability, useCollectors.toCollection(HashSet::new).
-
-