Package proguard.util

Class MultiValueMap<K,​V>

  • Type Parameters:
    K - the key type
    V - the value type

    public class MultiValueMap<K,​V>
    extends java.lang.Object
    A key-values map that can have multiple values associated with each key.

    There is an efficient lookup method to retrieve all values of all keys.

    • Constructor Summary

      Constructors 
      Constructor Description
      MultiValueMap()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      protected java.util.Map<K,​java.util.Set<V>> createKeyMap()  
      protected java.util.Set<V> createValueSet()  
      java.util.Set<java.util.Map.Entry<K,​java.util.Set<V>>> entrySet()  
      java.util.Set<V> get​(K key)  
      java.util.Set<V> getValues()
      Returns a Set with all values of all keys.
      java.util.Set<K> keySet()  
      void put​(K key, V value)  
      void putAll​(java.util.Set<K> keys, java.util.Set<V> values)  
      void putAll​(java.util.Set<K> key, V value)  
      void putAll​(K key, java.util.Set<V> values)  
      boolean remove​(K key, V value)  
      int size()  
      java.util.Collection<java.util.Set<V>> values()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MultiValueMap

        public MultiValueMap()
    • Method Detail

      • createValueSet

        protected java.util.Set<V> createValueSet()
      • createKeyMap

        protected java.util.Map<K,​java.util.Set<V>> createKeyMap()
      • size

        public int size()
      • keySet

        public java.util.Set<K> keySet()
      • values

        public java.util.Collection<java.util.Set<V>> values()
      • entrySet

        public java.util.Set<java.util.Map.Entry<K,​java.util.Set<V>>> entrySet()
      • put

        public void put​(K key,
                        V value)
      • putAll

        public void putAll​(java.util.Set<K> key,
                           V value)
      • putAll

        public void putAll​(java.util.Set<K> keys,
                           java.util.Set<V> values)
      • putAll

        public void putAll​(K key,
                           java.util.Set<V> values)
      • remove

        public boolean remove​(K key,
                              V value)
      • get

        public java.util.Set<V> get​(K key)
      • getValues

        public java.util.Set<V> getValues()
        Returns a Set with all values of all keys.
        Returns:
        a Set with all values of all keys.
      • clear

        public void clear()