Package org.apache.commons.collections4.properties

# Class OrderedProperties

java.lang.Object
java.util.Dictionary<Object,Object>
java.util.Hashtable<Object,Object>
java.util.Properties
org.apache.commons.collections4.properties.OrderedProperties

All Implemented Interfaces:
  `Serializable`, `Cloneable`, `Map<Object,Object>`

public class OrderedProperties extends Properties
A drop-in replacement for `Properties` for ordered keys.

Overrides methods to keep keys in insertion order. Allows other methods in the superclass to work with ordered keys.

Since:
  4.5.0-M1
See Also:
  - `OrderedPropertiesFactory.INSTANCE`
  - Serialized Form

- ## Nested Class Summary

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

  `Map.Entry<K,V>`

- ## Field Summary

  ### Fields inherited from class java.util.Properties

  `defaults`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `OrderedProperties()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `clear()`
  `Object`
  `compute(Object key, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)`
  `Object`
  `computeIfAbsent(Object key, Function<? super Object,? extends Object> mappingFunction)`
  `Set<Map.Entry<Object,Object>>`
  `entrySet()`
  `void`
  `forEach(BiConsumer<? super Object,? super Object> action)`
  `Enumeration<Object>`
  `keys()`
  `Set<Object>`
  `keySet()`
  `Object`
  `merge(Object key, Object value, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)`
  `Enumeration<?>`
  `propertyNames()`
  `Object`
  `put(Object key, Object value)`
  `void`
  `putAll(Map<? extends Object,? extends Object> t)`
  `Object`
  `putIfAbsent(Object key, Object value)`
  `Object`
  `remove(Object key)`
  `boolean`
  `remove(Object key, Object value)`
  `String`
  `toString()`

  ### Methods inherited from class java.util.Properties

  `getProperty, getProperty, list, list, load, load, loadFromXML, save, setProperty, store, store, storeToXML, storeToXML, stringPropertyNames`

  ### Methods inherited from class java.util.Hashtable

  `clone, computeIfPresent, contains, containsKey, containsValue, elements, equals, get, getOrDefault, hashCode, isEmpty, rehash, replace, replace, replaceAll, size, values`

  ### Methods inherited from class java.lang.Object

  `finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### OrderedProperties

    public OrderedProperties()

- ## Method Details

  - ### clear

    public void clear()
    Specified by:
      `clear` in interface `Map<Object,Object>`
    Overrides:
      `clear` in class `Hashtable<Object,Object>`

  - ### compute

    public Object compute(Object key, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)
    Specified by:
      `compute` in interface `Map<Object,Object>`
    Overrides:
      `compute` in class `Hashtable<Object,Object>`

  - ### computeIfAbsent

    public Object computeIfAbsent(Object key, Function<? super Object,? extends Object> mappingFunction)
    Specified by:
      `computeIfAbsent` in interface `Map<Object,Object>`
    Overrides:
      `computeIfAbsent` in class `Hashtable<Object,Object>`

  - ### entrySet

    public Set<Map.Entry<Object,Object>> entrySet()
    Specified by:
      `entrySet` in interface `Map<Object,Object>`
    Overrides:
      `entrySet` in class `Hashtable<Object,Object>`

  - ### forEach

    public void forEach(BiConsumer<? super Object,? super Object> action)
    Specified by:
      `forEach` in interface `Map<Object,Object>`
    Overrides:
      `forEach` in class `Hashtable<Object,Object>`

  - ### keys

    public Enumeration<Object> keys()
    Overrides:
      `keys` in class `Hashtable<Object,Object>`

  - ### keySet

    public Set<Object> keySet()
    Specified by:
      `keySet` in interface `Map<Object,Object>`
    Overrides:
      `keySet` in class `Hashtable<Object,Object>`

  - ### merge

    public Object merge(Object key, Object value, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)
    Specified by:
      `merge` in interface `Map<Object,Object>`
    Overrides:
      `merge` in class `Hashtable<Object,Object>`

  - ### propertyNames

    public Enumeration<?> propertyNames()
    Overrides:
      `propertyNames` in class `Properties`

  - ### put

    public Object put(Object key, Object value)
    Specified by:
      `put` in interface `Map<Object,Object>`
    Overrides:
      `put` in class `Hashtable<Object,Object>`

  - ### putAll

    public void putAll(Map<? extends Object,? extends Object> t)
    Specified by:
      `putAll` in interface `Map<Object,Object>`
    Overrides:
      `putAll` in class `Hashtable<Object,Object>`

  - ### putIfAbsent

    public Object putIfAbsent(Object key, Object value)
    Specified by:
      `putIfAbsent` in interface `Map<Object,Object>`
    Overrides:
      `putIfAbsent` in class `Hashtable<Object,Object>`

  - ### remove

    public Object remove(Object key)
    Specified by:
      `remove` in interface `Map<Object,Object>`
    Overrides:
      `remove` in class `Hashtable<Object,Object>`

  - ### remove

    public boolean remove(Object key, Object value)
    Specified by:
      `remove` in interface `Map<Object,Object>`
    Overrides:
      `remove` in class `Hashtable<Object,Object>`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Hashtable<Object,Object>`