Package com.saperion.util.configuration
Class CaseInsensitiveProperties
java.lang.Object
java.util.Dictionary<K,V>
java.util.Hashtable<Object,Object>
java.util.Properties
com.saperion.util.configuration.CaseInsensitiveProperties
- All Implemented Interfaces:
Serializable
,Cloneable
,Map<Object,
Object>
A case-insensitive properties class. All strings will be converted to upper-case when a new
property is added or when a property is retrieved. Note that the keys prop1 and Prop1 will be
treated as equal.
- See Also:
-
Field Summary
Fields inherited from class java.util.Properties
defaults
-
Constructor Summary
ConstructorsConstructorDescriptionCaseInsensitiveProperties
(Properties properties) Creates a new case-insensitive properties instance. -
Method Summary
Methods inherited from class java.util.Properties
clear, clone, compute, computeIfAbsent, computeIfPresent, contains, containsKey, containsValue, elements, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keys, keySet, list, list, load, load, loadFromXML, merge, propertyNames, putIfAbsent, rehash, remove, remove, replace, replace, replaceAll, save, setProperty, size, store, store, storeToXML, storeToXML, storeToXML, stringPropertyNames, toString, values
-
Constructor Details
-
CaseInsensitiveProperties
Creates a new case-insensitive properties instance. The entries in the specified properties instance will be copied to the new instance with their keys converted to upper-case. Note that by doing this, properties might get overwritten if the specified properties instance contains keys that differ only in upper-/lowercase.- Parameters:
properties
- set of properties to copy
-
-
Method Details
-
put
Adds a new entry to the underlying map. If the key is of type string, it will be converted to upper-case. -
putAll
-
getProperty
- Overrides:
getProperty
in classProperties
- See Also:
-
getProperty
- Overrides:
getProperty
in classProperties
- See Also:
-