public class PropertiesMap extends java.lang.Object implements java.util.Map<java.lang.String,java.lang.String>, IConfigSettings
Constructor and Description |
---|
PropertiesMap() |
PropertiesMap(java.util.Properties properties) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
boolean |
containsKey(java.lang.Object key) |
boolean |
containsValue(java.lang.Object value) |
java.util.Set<java.util.Map.Entry<java.lang.String,java.lang.String>> |
entrySet() |
java.lang.String |
get(java.lang.Object key) |
protected java.util.Properties |
getInternalProperties() |
java.util.Collection<java.lang.String> |
getNames()
Returns all names (maybe empty but never null).
|
java.util.Properties |
getProperties()
Returns the data as Properties object (a copy).
|
java.lang.String |
getProperty(java.lang.String key)
Searches for the property with the specified key in this property list.
|
java.lang.String |
getProperty(java.lang.String key,
java.lang.String defaultValue)
Searches for the property with the specified key in this property list.
|
java.lang.String |
getValue(java.lang.String name)
Returns the value associated with the given name.
|
boolean |
isEmpty()
Returns true if the receiver does not contain any data.
|
java.util.Set<java.lang.String> |
keySet() |
java.lang.String |
put(java.lang.String key,
java.lang.String value) |
void |
putAll(java.util.Map<? extends java.lang.String,? extends java.lang.String> map) |
java.lang.String |
remove(java.lang.Object key) |
void |
setProperty(java.lang.String key,
java.lang.String value)
Sets the given value as ne property value for the given key.
|
int |
size() |
java.util.Set<java.lang.String> |
stringPropertyNames()
Returns a set of keys in this property list where the key and its corresponding
value are strings, including distinct keys in the default property list if a key
of the same name has not already been found from the main properties list.
|
java.util.Collection<java.lang.String> |
values() |
public PropertiesMap()
public PropertiesMap(java.util.Properties properties)
public java.util.Properties getProperties()
public int size()
size
in interface java.util.Map<java.lang.String,java.lang.String>
public boolean isEmpty()
IReadOnlyNamedValues
isEmpty
in interface java.util.Map<java.lang.String,java.lang.String>
isEmpty
in interface IReadOnlyNamedValues<java.lang.String>
public boolean containsKey(java.lang.Object key)
containsKey
in interface java.util.Map<java.lang.String,java.lang.String>
public boolean containsValue(java.lang.Object value)
containsValue
in interface java.util.Map<java.lang.String,java.lang.String>
public java.lang.String get(java.lang.Object key)
get
in interface java.util.Map<java.lang.String,java.lang.String>
public java.lang.String put(java.lang.String key, java.lang.String value)
put
in interface java.util.Map<java.lang.String,java.lang.String>
public java.lang.String remove(java.lang.Object key)
remove
in interface java.util.Map<java.lang.String,java.lang.String>
public void putAll(java.util.Map<? extends java.lang.String,? extends java.lang.String> map)
putAll
in interface java.util.Map<java.lang.String,java.lang.String>
public void clear()
clear
in interface java.util.Map<java.lang.String,java.lang.String>
public java.util.Set<java.lang.String> keySet()
keySet
in interface java.util.Map<java.lang.String,java.lang.String>
public java.util.Collection<java.lang.String> values()
values
in interface java.util.Map<java.lang.String,java.lang.String>
public java.util.Set<java.util.Map.Entry<java.lang.String,java.lang.String>> entrySet()
entrySet
in interface java.util.Map<java.lang.String,java.lang.String>
public java.lang.String getProperty(java.lang.String key)
public java.lang.String getProperty(java.lang.String key, java.lang.String defaultValue)
public void setProperty(java.lang.String key, java.lang.String value)
public java.util.Set<java.lang.String> stringPropertyNames()
public java.util.Collection<java.lang.String> getNames()
IReadOnlyNamedValues
getNames
in interface IReadOnlyNamedValues<java.lang.String>
public java.lang.String getValue(java.lang.String name)
IReadOnlyNamedValues
getValue
in interface IReadOnlyNamedValues<java.lang.String>
name
- The identifier for which the associated value must be returned (must not be null).protected java.util.Properties getInternalProperties()