public class PropertiesHolder
extends java.util.HashMap<java.lang.String,java.lang.String>
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
NL |
Constructor and Description |
---|
PropertiesHolder()
Creates a new instance of PropertiesHolder with default prefix and suffix
values.
The prefix in this case is the token "set " and the suffix is the newline character. |
PropertiesHolder(java.lang.String prefix,
java.lang.String suffix)
Creates a new instance of PropertiesHolder with given prefix and suffix
tokens.
|
Modifier and Type | Method and Description |
---|---|
void |
appendProperties(java.lang.StringBuilder bf)
Retrieve the list of the stored key-value pairs in this object.
|
void |
set(java.lang.String key)
Set a specific key to this object, without a value
|
void |
set(java.lang.String key,
java.lang.String value)
Add a specific key-value pair to this object.
|
void |
unset(java.lang.String key)
Remove a key from this object
|
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values
public PropertiesHolder()
public PropertiesHolder(java.lang.String prefix, java.lang.String suffix)
prefix
- The prefix to usesuffix
- The suffix to use.public void set(java.lang.String key, java.lang.String value)
key
- The key to usevalue
- The value of the specified parameter.public void set(java.lang.String key)
key
- The key to add to this objectpublic void unset(java.lang.String key)
key
- The key to be removedpublic void appendProperties(java.lang.StringBuilder bf)
bf
- The StringBuilder to store the representation of this object.