Class OrderedProperties

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, java.util.Map<java.lang.Object,​java.lang.Object>

    public class OrderedProperties
    extends java.util.Properties
    Class extending java.util.Properties to preserve order by redirecting calls to an internal linked hash map.
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.LinkedHashMap<java.lang.Object,​java.lang.Object> map
      The internal map.
      • Fields inherited from class java.util.Properties

        defaults
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()
      Delegate.
      boolean containsKey​(java.lang.Object key)
      Delegate.
      boolean containsValue​(java.lang.Object value)
      Delegate.
      java.util.Set<java.util.Map.Entry<java.lang.Object,​java.lang.Object>> entrySet()
      Delegate.
      java.lang.Object get​(java.lang.Object key)
      Delegate.
      boolean isEmpty()
      Delegate.
      java.util.Set<java.lang.Object> keySet()
      Delegate.
      java.lang.Object put​(java.lang.Object key, java.lang.Object value)
      Delegate.
      void putAll​(java.util.Map<? extends java.lang.Object,​? extends java.lang.Object> m)
      Delegate.
      java.lang.Object remove​(java.lang.Object key)
      Delegate.
      int size()
      Delegate.
      java.util.Collection<java.lang.Object> values()
      Delegate.
      • Methods inherited from class java.util.Properties

        clone, compute, computeIfAbsent, computeIfPresent, contains, elements, equals, forEach, getOrDefault, getProperty, getProperty, hashCode, keys, list, list, load, load, loadFromXML, merge, propertyNames, putIfAbsent, rehash, remove, replace, replace, replaceAll, save, setProperty, store, store, storeToXML, storeToXML, storeToXML, stringPropertyNames, toString
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • map

        protected java.util.LinkedHashMap<java.lang.Object,​java.lang.Object> map
        The internal map.
    • Constructor Detail

      • OrderedProperties

        public OrderedProperties()
    • Method Detail

      • size

        public int size()
        Delegate.
        Specified by:
        size in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        size in class java.util.Properties
      • isEmpty

        public boolean isEmpty()
        Delegate.
        Specified by:
        isEmpty in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        isEmpty in class java.util.Properties
      • containsKey

        public boolean containsKey​(java.lang.Object key)
        Delegate.
        Specified by:
        containsKey in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        containsKey in class java.util.Properties
      • containsValue

        public boolean containsValue​(java.lang.Object value)
        Delegate.
        Specified by:
        containsValue in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        containsValue in class java.util.Properties
      • get

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

        public java.lang.Object put​(java.lang.Object key,
                                    java.lang.Object value)
        Delegate.
        Specified by:
        put in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        put in class java.util.Properties
      • remove

        public java.lang.Object remove​(java.lang.Object key)
        Delegate.
        Specified by:
        remove in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        remove in class java.util.Properties
      • putAll

        public void putAll​(java.util.Map<? extends java.lang.Object,​? extends java.lang.Object> m)
        Delegate.
        Specified by:
        putAll in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        putAll in class java.util.Properties
      • clear

        public void clear()
        Delegate.
        Specified by:
        clear in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        clear in class java.util.Properties
      • keySet

        public java.util.Set<java.lang.Object> keySet()
        Delegate.
        Specified by:
        keySet in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        keySet in class java.util.Properties
      • values

        public java.util.Collection<java.lang.Object> values()
        Delegate.
        Specified by:
        values in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        values in class java.util.Properties
      • entrySet

        public java.util.Set<java.util.Map.Entry<java.lang.Object,​java.lang.Object>> entrySet()
        Delegate.
        Specified by:
        entrySet in interface java.util.Map<java.lang.Object,​java.lang.Object>
        Overrides:
        entrySet in class java.util.Properties