Class DelegatingMultimap<K,V>

java.lang.Object
org.openjdk.jmh.util.DelegatingMultimap<K,V>
All Implemented Interfaces:
Serializable, Multimap<K,V>
Direct Known Subclasses:
HashMultimap, HashsetMultimap, TreeMultimap

public class DelegatingMultimap<K,V> extends Object implements Multimap<K,V>, Serializable
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • createValueCollection

      protected Collection<V> createValueCollection()
    • put

      public void put(K key, V value)
      Description copied from interface: Multimap
      Put the element pair.
      Specified by:
      put in interface Multimap<K,V>
      Parameters:
      key - key
      value - value
    • putAll

      public void putAll(K key, Collection<V> vvs)
      Description copied from interface: Multimap
      Put multiple pairs.
      Specified by:
      putAll in interface Multimap<K,V>
      Parameters:
      key - key
      vvs - values
    • get

      public Collection<V> get(K key)
      Description copied from interface: Multimap
      Get all values associated with the key
      Specified by:
      get in interface Multimap<K,V>
      Parameters:
      key - key
      Returns:
      collection of values
    • isEmpty

      public boolean isEmpty()
      Description copied from interface: Multimap
      Checks if multimap is empty
      Specified by:
      isEmpty in interface Multimap<K,V>
      Returns:
      true, if empty
    • clear

      public void clear()
      Description copied from interface: Multimap
      Clears the multimap
      Specified by:
      clear in interface Multimap<K,V>
    • keys

      public Collection<K> keys()
      Description copied from interface: Multimap
      Keys in the map
      Specified by:
      keys in interface Multimap<K,V>
      Returns:
      collection of keys
    • values

      public Collection<V> values()
      Specified by:
      values in interface Multimap<K,V>
    • entrySet

      public Collection<Map.Entry<K,Collection<V>>> entrySet()
      Description copied from interface: Multimap
      Get all associations of the multimap. The method is intended for read-only view.
      Specified by:
      entrySet in interface Multimap<K,V>
      Returns:
      entry set of the multimap
    • remove

      public void remove(K key)
      Specified by:
      remove in interface Multimap<K,V>
    • merge

      public void merge(Multimap<K,V> other)
      Specified by:
      merge in interface Multimap<K,V>
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object