Class MapStack<K>

  • All Implemented Interfaces:
    java.util.Map<K,​java.lang.Object>, LocalizedMap<java.lang.Object>

    public class MapStack<K>
    extends MapContext<K,​java.lang.Object>
    Map Stack
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String module  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected MapStack()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static <K> MapStack<K> create()  
      static <K> MapStack<K> create​(java.util.Map<K,​java.lang.Object> baseMap)  
      static <K> MapStack<K> create​(MapStack<K> source)
      Does a shallow copy of the internal stack of the passed MapStack; enables simultaneous stacks that share common parent Maps
      java.lang.Object get​(java.lang.Object key)  
      java.lang.Object get​(java.lang.String name, java.util.Locale locale)  
      java.lang.Object put​(K key, java.lang.Object value)  
      MapStack<K> standAloneChildStack()
      Creates a MapStack object that has the same Map objects on its stack, but with a new Map pushed on the top; meant to be used to enable a situation where a parent and child context are operating simultaneously using two different MapStack objects, but sharing the Maps in common
      MapStack<K> standAloneStack()
      Creates a MapStack object that has the same Map objects on its stack; meant to be used to enable a situation where a parent and child context are operating simultaneously using two different MapStack objects, but sharing the Maps in common
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
    • Field Detail

      • module

        public static final java.lang.String module
    • Constructor Detail

      • MapStack

        protected MapStack()
    • Method Detail

      • create

        public static <K> MapStack<K> create()
      • create

        public static <K> MapStack<K> create​(java.util.Map<K,​java.lang.Object> baseMap)
      • create

        public static <K> MapStack<K> create​(MapStack<K> source)
        Does a shallow copy of the internal stack of the passed MapStack; enables simultaneous stacks that share common parent Maps
      • standAloneStack

        public MapStack<K> standAloneStack()
        Creates a MapStack object that has the same Map objects on its stack; meant to be used to enable a situation where a parent and child context are operating simultaneously using two different MapStack objects, but sharing the Maps in common
      • standAloneChildStack

        public MapStack<K> standAloneChildStack()
        Creates a MapStack object that has the same Map objects on its stack, but with a new Map pushed on the top; meant to be used to enable a situation where a parent and child context are operating simultaneously using two different MapStack objects, but sharing the Maps in common
      • get

        public java.lang.Object get​(java.lang.Object key)
        Specified by:
        get in interface java.util.Map<K,​java.lang.Object>
        Overrides:
        get in class MapContext<K,​java.lang.Object>
      • get

        public java.lang.Object get​(java.lang.String name,
                                    java.util.Locale locale)
        Specified by:
        get in interface LocalizedMap<K>
        Overrides:
        get in class MapContext<K,​java.lang.Object>
      • put

        public java.lang.Object put​(K key,
                                    java.lang.Object value)
        Specified by:
        put in interface java.util.Map<K,​java.lang.Object>
        Overrides:
        put in class MapContext<K,​java.lang.Object>