java.lang.Object
de.hybris.platform.servicelayer.internal.model.LocMap<K,T>
All Implemented Interfaces:
Serializable, Map<K,T>

public class LocMap<K,T> extends Object implements Map<K,T>, Serializable
Thread-safe localized value map to be used in AbstractItemModel.

Please note this class was necessary to be created since ConcurrentHashMap is not capable to store NULL values.

Internally all calls are delegated to a instance of ConcurrentHashMap but NULL values are masked by a specific token that is being translated upon read access.

See Also:
  • Constructor Details

    • LocMap

      public LocMap()
  • Method Details

    • put

      public T put(K locale, T value)
      Specified by:
      put in interface Map<K,T>
    • size

      public int size()
      Specified by:
      size in interface Map<K,T>
    • isEmpty

      public boolean isEmpty()
      Specified by:
      isEmpty in interface Map<K,T>
    • containsKey

      public boolean containsKey(Object key)
      Specified by:
      containsKey in interface Map<K,T>
    • containsValue

      public boolean containsValue(Object value)
      Specified by:
      containsValue in interface Map<K,T>
    • get

      public T get(Object key)
      Specified by:
      get in interface Map<K,T>
    • remove

      public T remove(Object key)
      Specified by:
      remove in interface Map<K,T>
    • putAll

      public void putAll(Map<? extends K,? extends T> map)
      Specified by:
      putAll in interface Map<K,T>
    • clear

      public void clear()
      Specified by:
      clear in interface Map<K,T>
    • keySet

      public Set<K> keySet()
      Specified by:
      keySet in interface Map<K,T>
    • values

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

      public Set<Map.Entry<K,T>> entrySet()
      Specified by:
      entrySet in interface Map<K,T>
    • toString

      public String toString()
      Overrides:
      toString in class Object