Package com.google.common.collect
Class ImmutableSet.CachingAsList<E>
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- com.google.common.collect.ImmutableCollection<E>
-
- com.google.common.collect.ImmutableSet<E>
-
- com.google.common.collect.ImmutableSet.CachingAsList<E>
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Iterable<E>,java.util.Collection<E>,java.util.Set<E>
- Direct Known Subclasses:
ImmutableMapEntrySet,ImmutableSet.Indexed,ImmutableSortedSetFauxverideShim,IndexedImmutableSet,RegularImmutableSet
- Enclosing class:
- ImmutableSet<E>
abstract static class ImmutableSet.CachingAsList<E> extends ImmutableSet<E>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.common.collect.ImmutableSet
ImmutableSet.Builder<E>, ImmutableSet.CachingAsList<E>, ImmutableSet.Indexed<E>
-
-
Field Summary
Fields Modifier and Type Field Description private ImmutableList<E>asList-
Fields inherited from class com.google.common.collect.ImmutableSet
MAX_TABLE_SIZE, SPLITERATOR_CHARACTERISTICS
-
-
Constructor Summary
Constructors Constructor Description CachingAsList()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImmutableList<E>asList()Returns anImmutableListcontaining the same elements, in the same order, as this collection.(package private) ImmutableList<E>createAsList()-
Methods inherited from class com.google.common.collect.ImmutableSet
builder, builderWithExpectedSize, chooseTableSize, copyOf, copyOf, copyOf, copyOf, equals, hashCode, isHashCodeFast, iterator, of, of, of, of, of, of, of, toImmutableSet, writeReplace
-
Methods inherited from class com.google.common.collect.ImmutableCollection
add, addAll, clear, contains, copyIntoArray, internalArray, internalArrayEnd, internalArrayStart, isPartialView, remove, removeAll, removeIf, retainAll, spliterator, toArray, toArray
-
-
-
-
Field Detail
-
asList
@CheckForNull private transient ImmutableList<E> asList
-
-
Method Detail
-
asList
public ImmutableList<E> asList()
Description copied from class:ImmutableCollectionReturns anImmutableListcontaining the same elements, in the same order, as this collection.Performance note: in most cases this method can return quickly without actually copying anything. The exact circumstances under which the copy is performed are undefined and subject to change.
- Overrides:
asListin classImmutableCollection<E>
-
createAsList
ImmutableList<E> createAsList()
-
-