Package | Description |
---|---|
com.google.common.collect |
This package contains generic collection interfaces and implementations, and
other utilities for working with collections.
|
com.google.common.collect.testing.google | |
com.google.common.graph |
An API for representing graph (node and edge) data.
|
com.google.common.testing |
This package contains testing utilities.
|
com.google.common.util.concurrent |
Concurrency utilities.
|
Modifier and Type | Interface and Description |
---|---|
interface |
SortedMultiset<E>
A
Multiset which maintains the ordering of its elements, according to
either their natural order or an explicit Comparator . |
(package private) interface |
SortedMultisetBridge<E>
Superinterface of
SortedMultiset to introduce a bridge method for
elementSet() , to ensure binary compatibility with older Guava versions
that specified elementSet() to return SortedSet . |
Modifier and Type | Class and Description |
---|---|
(package private) class |
AbstractMapBasedMultiset<E>
Basic implementation of
Multiset<E> backed by an instance of Map<E, Count> . |
(package private) class |
AbstractMultiset<E>
This class provides a skeletal implementation of the
Multiset
interface. |
(package private) class |
AbstractSortedMultiset<E>
This class provides a skeletal implementation of the
SortedMultiset interface. |
class |
ConcurrentHashMultiset<E>
A multiset that supports concurrent modifications and that provides atomic versions of most
Multiset operations (exceptions where noted). |
(package private) class |
DescendingImmutableSortedMultiset<E>
A descending wrapper around an
ImmutableSortedMultiset |
(package private) class |
DescendingMultiset<E>
A skeleton implementation of a descending multiset.
|
class |
EnumMultiset<E extends java.lang.Enum<E>>
Multiset implementation backed by an
EnumMap . |
(package private) class |
FilteredEntryMultimap.Keys |
class |
ForwardingMultiset<E>
A multiset which forwards all its method calls to another multiset.
|
class |
ForwardingSortedMultiset<E>
A sorted multiset which forwards all its method calls to another sorted multiset.
|
protected class |
ForwardingSortedMultiset.StandardDescendingMultiset
A skeleton implementation of a descending multiset view.
|
class |
HashMultiset<E>
Multiset implementation backed by a
HashMap . |
(package private) class |
ImmutableMultimap.Keys |
class |
ImmutableMultiset<E>
A
Multiset whose contents will never change, with many other important properties
detailed at ImmutableCollection . |
class |
ImmutableSortedMultiset<E>
A
SortedMultiset whose contents will never change, with many other important properties
detailed at ImmutableCollection . |
(package private) class |
ImmutableSortedMultisetFauxverideShim<E>
"Overrides" the
ImmutableMultiset static methods that lack
ImmutableSortedMultiset equivalents with deprecated, exception-throwing versions. |
class |
LinkedHashMultiset<E>
A
Multiset implementation with predictable iteration order. |
(package private) static class |
Multimaps.Keys<K,V> |
private static class |
Multisets.FilteredMultiset<E> |
(package private) static class |
Multisets.UnmodifiableMultiset<E> |
(package private) class |
RegularImmutableMultiset<E>
Implementation of
ImmutableMultiset with zero or more elements. |
(package private) class |
RegularImmutableSortedMultiset<E>
An immutable sorted multiset with one or more distinct elements.
|
private static class |
Synchronized.SynchronizedMultiset<E> |
class |
TreeMultiset<E>
A multiset which maintains the ordering of its elements, according to either their natural order
or an explicit
Comparator . |
(package private) class |
UnmodifiableSortedMultiset<E>
Implementation of
Multisets.unmodifiableSortedMultiset(SortedMultiset) ,
split out into its own file so it can be GWT emulated (to deal with the differing
elementSet() types in GWT and non-GWT). |
Modifier and Type | Field and Description |
---|---|
(package private) Multiset<E> |
ImmutableMultiset.Builder.contents |
(package private) Multiset<? extends E> |
Multisets.UnmodifiableMultiset.delegate |
private Multiset<K> |
AbstractMultimap.keys |
(package private) Multiset<K> |
Synchronized.SynchronizedMultimap.keys |
(package private) Multiset<K> |
Multimaps.UnmodifiableMultimap.keys |
private Multiset<E> |
Multisets.MultisetIteratorImpl.multiset |
(package private) Multiset<E> |
Multisets.FilteredMultiset.unfiltered |
Modifier and Type | Method and Description |
---|---|
(package private) static <T> Multiset<T> |
Multisets.cast(java.lang.Iterable<T> iterable)
Used to avoid http://bugs.sun.com/view_bug.do?bug_id=6558557
|
(package private) Multiset<K> |
AbstractMultimap.createKeys() |
(package private) Multiset<K> |
FilteredEntryMultimap.createKeys() |
(package private) Multiset<K> |
FilteredKeyMultimap.createKeys() |
protected Multiset<E> |
DescendingMultiset.delegate() |
(package private) Multiset<E> |
Synchronized.SynchronizedMultiset.delegate() |
protected Multiset<E> |
Multisets.UnmodifiableMultiset.delegate() |
protected abstract Multiset<E> |
ForwardingMultiset.delegate() |
static <E> Multiset<E> |
Multisets.difference(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the difference of two multisets.
|
static <E> Multiset<E> |
Multisets.filter(Multiset<E> unfiltered,
Predicate<? super E> predicate)
Returns a view of the elements of
unfiltered that satisfy a predicate. |
static <E> Multiset<E> |
Multisets.intersection(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the intersection of two multisets.
|
Multiset<K> |
Multimap.keys()
Returns a view collection containing the key from each key-value pair in
this multimap, without collapsing duplicates.
|
Multiset<K> |
AbstractMultimap.keys() |
Multiset<K> |
ForwardingMultimap.keys() |
Multiset<K> |
Synchronized.SynchronizedMultimap.keys() |
Multiset<K> |
Multimaps.UnmodifiableMultimap.keys() |
Multiset<K> |
Multimaps.TransformedEntriesMultimap.keys() |
(package private) Multiset<E> |
AbstractMultiset.ElementSet.multiset() |
(package private) Multiset<E> |
AbstractMultiset.EntrySet.multiset() |
(package private) abstract Multiset<E> |
Multisets.ElementSet.multiset() |
(package private) abstract Multiset<E> |
Multisets.EntrySet.multiset() |
(package private) Multiset<E> |
ForwardingMultiset.StandardElementSet.multiset() |
(package private) Multiset<K> |
Multimaps.Keys.KeysEntrySet.multiset() |
(package private) static <E> Multiset<E> |
Synchronized.multiset(Multiset<E> multiset,
java.lang.Object mutex) |
static <E> Multiset<E> |
Multisets.sum(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the sum of two multisets.
|
static <E> Multiset<E> |
Multisets.union(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the union of two multisets.
|
static <E> Multiset<E> |
Multisets.unmodifiableMultiset(ImmutableMultiset<E> multiset)
Deprecated.
no need to use this
|
static <E> Multiset<E> |
Multisets.unmodifiableMultiset(Multiset<? extends E> multiset)
Returns an unmodifiable view of the specified multiset.
|
Modifier and Type | Method and Description |
---|---|
(package private) static <E> boolean |
Multisets.addAllImpl(Multiset<E> self,
java.util.Collection<? extends E> elements)
An implementation of
Collection.addAll(java.util.Collection<? extends E>) . |
static boolean |
Multisets.containsOccurrences(Multiset<?> superMultiset,
Multiset<?> subMultiset)
Returns
true if subMultiset.count(o) <=
superMultiset.count(o) for all o . |
static boolean |
Multisets.containsOccurrences(Multiset<?> superMultiset,
Multiset<?> subMultiset)
Returns
true if subMultiset.count(o) <=
superMultiset.count(o) for all o . |
static <E> ImmutableMultiset<E> |
Multisets.copyHighestCountFirst(Multiset<E> multiset)
Returns a copy of
multiset as an ImmutableMultiset whose iteration order is
highest count first, with ties broken by the iteration order of the original multiset. |
static <E> Multiset<E> |
Multisets.difference(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the difference of two multisets.
|
static <E> Multiset<E> |
Multisets.difference(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the difference of two multisets.
|
(package private) static boolean |
Multisets.equalsImpl(Multiset<?> multiset,
java.lang.Object object)
An implementation of
equals(java.lang.Object) . |
static <E> Multiset<E> |
Multisets.filter(Multiset<E> unfiltered,
Predicate<? super E> predicate)
Returns a view of the elements of
unfiltered that satisfy a predicate. |
static <E> Multiset<E> |
Multisets.intersection(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the intersection of two multisets.
|
static <E> Multiset<E> |
Multisets.intersection(Multiset<E> multiset1,
Multiset<?> multiset2)
Returns an unmodifiable view of the intersection of two multisets.
|
(package private) static <E> java.util.Iterator<E> |
Multisets.iteratorImpl(Multiset<E> multiset)
An implementation of
iterator() . |
(package private) static <E> Multiset<E> |
Synchronized.multiset(Multiset<E> multiset,
java.lang.Object mutex) |
(package private) static <E> void |
Serialization.populateMultiset(Multiset<E> multiset,
java.io.ObjectInputStream stream)
Populates a multiset by reading an input stream, as part of
deserialization.
|
(package private) static <E> void |
Serialization.populateMultiset(Multiset<E> multiset,
java.io.ObjectInputStream stream,
int distinctElements)
Populates a multiset by reading an input stream, as part of
deserialization.
|
(package private) static boolean |
Multisets.removeAllImpl(Multiset<?> self,
java.util.Collection<?> elementsToRemove)
An implementation of
removeAll(java.util.Collection<?>) . |
static boolean |
Multisets.removeOccurrences(Multiset<?> multisetToModify,
java.lang.Iterable<?> occurrencesToRemove)
For each occurrence of an element
e in occurrencesToRemove ,
removes one occurrence of e in multisetToModify . |
static boolean |
Multisets.removeOccurrences(Multiset<?> multisetToModify,
Multiset<?> occurrencesToRemove)
For each occurrence of an element
e in occurrencesToRemove ,
removes one occurrence of e in multisetToModify . |
static boolean |
Multisets.removeOccurrences(Multiset<?> multisetToModify,
Multiset<?> occurrencesToRemove)
For each occurrence of an element
e in occurrencesToRemove ,
removes one occurrence of e in multisetToModify . |
(package private) static boolean |
Multisets.retainAllImpl(Multiset<?> self,
java.util.Collection<?> elementsToRetain)
An implementation of
retainAll(java.util.Collection<?>) . |
static boolean |
Multisets.retainOccurrences(Multiset<?> multisetToModify,
Multiset<?> multisetToRetain)
Modifies
multisetToModify so that its count for an element
e is at most multisetToRetain.count(e) . |
static boolean |
Multisets.retainOccurrences(Multiset<?> multisetToModify,
Multiset<?> multisetToRetain)
Modifies
multisetToModify so that its count for an element
e is at most multisetToRetain.count(e) . |
private static <E> boolean |
Multisets.retainOccurrencesImpl(Multiset<E> multisetToModify,
Multiset<?> occurrencesToRetain)
Delegate implementation which cares about the element type.
|
private static <E> boolean |
Multisets.retainOccurrencesImpl(Multiset<E> multisetToModify,
Multiset<?> occurrencesToRetain)
Delegate implementation which cares about the element type.
|
(package private) static <E> int |
Multisets.setCountImpl(Multiset<E> self,
E element,
int count)
An implementation of
setCount(Object, int) . |
(package private) static <E> boolean |
Multisets.setCountImpl(Multiset<E> self,
E element,
int oldCount,
int newCount)
An implementation of
setCount(Object, int, int) . |
(package private) static int |
Multisets.sizeImpl(Multiset<?> multiset)
An implementation of
Collection.size() . |
static <E> Multiset<E> |
Multisets.sum(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the sum of two multisets.
|
static <E> Multiset<E> |
Multisets.sum(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the sum of two multisets.
|
static <E> Multiset<E> |
Multisets.union(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the union of two multisets.
|
static <E> Multiset<E> |
Multisets.union(Multiset<? extends E> multiset1,
Multiset<? extends E> multiset2)
Returns an unmodifiable view of the union of two multisets.
|
static <E> Multiset<E> |
Multisets.unmodifiableMultiset(Multiset<? extends E> multiset)
Returns an unmodifiable view of the specified multiset.
|
(package private) static <E> void |
Serialization.writeMultiset(Multiset<E> multiset,
java.io.ObjectOutputStream stream)
Stores the contents of a multiset in an output stream, as part of
serialization.
|
Constructor and Description |
---|
Builder(Multiset<E> contents) |
FilteredMultiset(Multiset<E> unfiltered,
Predicate<? super E> predicate) |
MultisetIteratorImpl(Multiset<E> multiset,
java.util.Iterator<Multiset.Entry<E>> entryIterator) |
SerializedForm(Multiset<?> multiset) |
SynchronizedMultiset(Multiset<E> delegate,
java.lang.Object mutex) |
UnmodifiableMultiset(Multiset<? extends E> delegate) |
Modifier and Type | Method and Description |
---|---|
protected abstract Multiset<AnEnum> |
TestEnumMultisetGenerator.create(AnEnum[] elements) |
Multiset<E> |
MultisetTestSuiteBuilder.ReserializedMultisetGenerator.create(java.lang.Object... elements) |
Multiset<E> |
SortedMultisetTestSuiteBuilder.ForwardingTestMultisetGenerator.create(java.lang.Object... elements) |
Multiset<AnEnum> |
TestEnumMultisetGenerator.create(java.lang.Object... elements) |
Multiset<K> |
MultimapTestSuiteBuilder.KeysGenerator.create(java.lang.Object... elements) |
Multiset<E> |
TestMultisetGenerator.create(java.lang.Object... elements) |
Multiset<java.lang.String> |
TestStringMultisetGenerator.create(java.lang.Object... elements) |
protected abstract Multiset<java.lang.String> |
TestStringMultisetGenerator.create(java.lang.String[] elements) |
protected Multiset<E> |
AbstractMultisetTester.getMultiset() |
Modifier and Type | Method and Description |
---|---|
java.util.Set<Feature<? super Multiset>> |
MultisetFeature.getImpliedFeatures() |
Modifier and Type | Method and Description |
---|---|
static <E> void |
UnmodifiableCollectionTests.assertMultisetIsUnmodifiable(Multiset<E> multiset,
E sampleElement)
Verifies that a multiset is immutable.
|
(package private) static <T> SortedMultiset<T> |
MultisetNavigationTester.cast(Multiset<T> iterable)
Used to avoid http://bugs.sun.com/view_bug.do?bug_id=6558557
|
Modifier and Type | Field and Description |
---|---|
private java.lang.ref.Reference<Multiset<N>> |
UndirectedMultiNetworkConnections.adjacentNodesReference |
private java.lang.ref.Reference<Multiset<N>> |
DirectedMultiNetworkConnections.predecessorsReference |
private java.lang.ref.Reference<Multiset<N>> |
DirectedMultiNetworkConnections.successorsReference |
Modifier and Type | Method and Description |
---|---|
private Multiset<N> |
UndirectedMultiNetworkConnections.adjacentNodesMultiset() |
private Multiset<N> |
DirectedMultiNetworkConnections.predecessorsMultiset() |
private Multiset<N> |
DirectedMultiNetworkConnections.successorsMultiset() |
Modifier and Type | Method and Description |
---|---|
private static <E> Multiset<E> |
FreshValueGenerator.generateMultiset(E freshElement) |
Modifier and Type | Field and Description |
---|---|
(package private) Multiset<Service.State> |
ServiceManager.ServiceManagerState.states |