SortedSetMultimap interface. It's a wrapper around AbstractMapBasedMultimap that converts the returned collections into sorted sets. The createCollection method must return a SortedSet.
| Modifier and Type | Field and Description |
|---|---|
| private static final long |
| Access | Constructor and Description |
|---|---|
| protected | AbstractSortedSetMultimap(Map<K, Collection<V>>
place to store the mapping from each key to its corresponding values map)Creates a new multimap that uses the provided map. |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides com. | |
| AbstractSortedSetMultimap | back to summary |
|---|---|
| protected AbstractSortedSetMultimap(Map<K, Collection<V>> map) Creates a new multimap that uses the provided map.
| |
| asMap | back to summary |
|---|---|
| public Map Overrides com. Implements com. Returns a map view that associates each key with the corresponding values in the multimap.
Changes to the returned map, such as element removal, will update the underlying multimap. The
map does not support When passed a key that is present in the map, Though the method signature doesn't say so explicitly, the returned map has
| |
| createCollection | back to summary |
|---|---|
| pack-priv abstract SortedSet Implements abstract com. Doc from com. Creates the collection of values for a single key. Collections with weak, soft, or phantom references are not supported. Each call to The returned collection class determines whether duplicate key-value pairs are allowed. | |
| createUnmodifiableEmptyCollection | back to summary |
|---|---|
| pack-priv SortedSet Overrides com. Doc from com. Creates an unmodifiable, empty collection of values. This is used in
| |
| get | back to summary |
|---|---|
| public SortedSet Overrides com. Implements com. Returns a collection view of all values associated with a key. If no mappings in the multimap have the provided key, an empty collection is returned. Changes to the returned collection will update the underlying multimap, and vice versa. Because a
| |
| removeAll | back to summary |
|---|---|
| public SortedSet Overrides com. Implements com. Removes all values associated with a given key. The returned collection is immutable. Because a
| |
| replaceValues | back to summary |
|---|---|
| public SortedSet Overrides com. Implements com. Stores a collection of values with the same key, replacing any existing values for that key. The returned collection is immutable. Because a Any duplicates in
| |
| unmodifiableCollectionSubclass | back to summary |
|---|---|
| pack-priv <E extends @Nullable Object> SortedSet Overrides com.
| |
| values | back to summary |
|---|---|
| public Collection Overrides com. Implements com. Doc from com. Returns a view collection containing the value from each key-value pair contained in
this multimap, without collapsing duplicates (so Changes to the returned collection will update the underlying multimap, and vice versa. However, adding to the returned collection is not possible. Consequently, the values do not follow their natural ordering or the ordering of the value comparator.
| |
| wrapCollection | back to summary |
|---|---|
| pack-priv Collection Overrides com. Doc from com. Generates a decorated collection that remains consistent with the values in the multimap for the provided key. Changes to the multimap may alter the returned collection, and vice versa.
| |