public class ParameterStd extends java.lang.Object implements ParameterStore
ParameterStore.Entry
Modifier and Type | Field and Description |
---|---|
static ParameterStore.Entry |
BACKUP_DIRECTORY |
static ParameterStore.Entry |
BACKUP_FILE |
static ParameterStore.Entry |
BACKUP_TIME |
static ParameterStore.Entry |
CSV_STANDARD_CHARSET |
static ParameterStore.Entry |
HTML_TABLE_BORDER |
protected DataObject |
parameterDataObject |
Constructor and Description |
---|
ParameterStd(DataObject parameterDataObject) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
getBoolean() |
protected boolean |
getBoolean(ParameterStore.Entry entry) |
protected java.sql.Date |
getDate() |
protected int |
getInt() |
java.lang.String |
getLastBackupDir()
Returns the last backup directory even if multiple directories have been memorized,
|
protected long |
getLong() |
protected java.lang.String |
getText() |
protected java.lang.String |
getText(ParameterStore.Entry parm) |
protected java.lang.String |
getText(java.lang.String key,
java.lang.String defaultValue)
Thread-safe retrieval of parameter values.
|
java.lang.String |
getValue(ParameterStore.Entry parmEntry)
Returns the parameter value associated with the specified entry or the default value if parameter is empty.
|
java.lang.String |
getValue(java.lang.String key)
Returns the parameter value associated with the specified key.
|
boolean |
getValueAsBoolean(ParameterStore.Entry parmEntry) |
boolean |
getValueAsBoolean(java.lang.String key)
Returns the parameter value associated with the specified key as boolean.
|
double |
getValueAsDouble(ParameterStore.Entry parmEntry) |
double |
getValueAsDouble(java.lang.String key)
Returns the parameter value associated with the specified key as double.
|
int |
getValueAsInt(ParameterStore.Entry parmEntry) |
int |
getValueAsInt(java.lang.String key)
Returns the parameter value associated with the specified key as integer.
|
long |
getValueAsLong(ParameterStore.Entry parmEntry) |
protected boolean |
load(java.lang.String key) |
static ParameterStore.Entry |
register(ParameterStore.Entry entry)
Registers a parameter entry and returns it.
|
void |
set(ParameterStore.Entry parm,
boolean value) |
void |
set(ParameterStore.Entry parm,
double value) |
void |
set(ParameterStore.Entry parm,
int value) |
void |
set(ParameterStore.Entry parm,
long value) |
void |
set(ParameterStore.Entry parm,
java.lang.String value) |
protected void |
set(java.lang.String key,
boolean value) |
protected void |
set(java.lang.String key,
java.sql.Date value) |
protected void |
set(java.lang.String key,
double value) |
protected void |
set(java.lang.String key,
int value) |
protected void |
set(java.lang.String key,
long value) |
protected void |
set(java.lang.String key,
java.lang.String value) |
void |
setLastBackupDirectory(java.lang.String directory)
Sets last backup directory while keeping other memorized former backup directories
|
void |
setValue(java.lang.String key,
boolean value)
Sets the parameter value.
|
void |
setValue(java.lang.String key,
double value)
Sets the parameter value.
|
void |
setValue(java.lang.String key,
int value)
Sets the parameter value.
|
void |
setValue(java.lang.String key,
java.lang.String value)
Sets the parameter value.
|
static void |
setValueColumnName(java.lang.String valueColumnName) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
setValue
public static final ParameterStore.Entry HTML_TABLE_BORDER
public static final ParameterStore.Entry BACKUP_DIRECTORY
public static final ParameterStore.Entry BACKUP_FILE
public static final ParameterStore.Entry BACKUP_TIME
public static final ParameterStore.Entry CSV_STANDARD_CHARSET
protected DataObject parameterDataObject
public ParameterStd(DataObject parameterDataObject)
public static void setValueColumnName(java.lang.String valueColumnName)
public static ParameterStore.Entry register(ParameterStore.Entry entry)
entry
- the entry to registeredprotected boolean load(java.lang.String key)
protected java.lang.String getText()
protected java.lang.String getText(ParameterStore.Entry parm)
protected java.lang.String getText(java.lang.String key, java.lang.String defaultValue)
key
- the parameter keydefaultValue
- the parameters default valueprotected void set(java.lang.String key, java.lang.String value)
public void set(ParameterStore.Entry parm, java.lang.String value)
public void set(ParameterStore.Entry parm, boolean value)
protected int getInt()
protected void set(java.lang.String key, int value)
public void set(ParameterStore.Entry parm, int value)
protected void set(java.lang.String key, double value)
public void set(ParameterStore.Entry parm, double value)
protected long getLong()
protected void set(java.lang.String key, long value)
public void set(ParameterStore.Entry parm, long value)
protected boolean getBoolean()
protected boolean getBoolean(ParameterStore.Entry entry)
protected void set(java.lang.String key, boolean value)
protected java.sql.Date getDate()
protected void set(java.lang.String key, java.sql.Date value)
public java.lang.String getValue(ParameterStore.Entry parmEntry)
ParameterStore
getValue
in interface ParameterStore
parmEntry
- the entry whose parameter is to receivepublic java.lang.String getValue(java.lang.String key)
ParameterStore
getValue
in interface ParameterStore
key
- the key of the parameter to be retrievedpublic boolean getValueAsBoolean(ParameterStore.Entry parmEntry)
public boolean getValueAsBoolean(java.lang.String key)
ParameterStore
getValueAsBoolean
in interface ParameterStore
key
- the key of the parameter to be retrievedpublic long getValueAsLong(ParameterStore.Entry parmEntry)
public int getValueAsInt(ParameterStore.Entry parmEntry)
public int getValueAsInt(java.lang.String key)
ParameterStore
getValueAsInt
in interface ParameterStore
key
- the key of the parameter to be retrievedpublic double getValueAsDouble(ParameterStore.Entry parmEntry)
public double getValueAsDouble(java.lang.String key)
ParameterStore
getValueAsDouble
in interface ParameterStore
key
- the key of the parameter to be retrievedpublic void setValue(java.lang.String key, java.lang.String value)
ParameterStore
setValue
in interface ParameterStore
key
- the key of the parameter to setvalue
- the value of the parameter to setpublic void setValue(java.lang.String key, int value)
ParameterStore
setValue
in interface ParameterStore
key
- the key of the parameter to setvalue
- the value of the parameter to setpublic void setValue(java.lang.String key, double value)
ParameterStore
setValue
in interface ParameterStore
key
- the key of the parameter to setvalue
- the value of the parameter to setpublic void setValue(java.lang.String key, boolean value)
ParameterStore
setValue
in interface ParameterStore
key
- the key of the parameter to setvalue
- the value of the parameter to setpublic java.lang.String getLastBackupDir()
public void setLastBackupDirectory(java.lang.String directory)
directory
- the last backup directory to setCopyright 1998-2023 Christoph Mueller, Kaerntner Str. 56, D-70469 Stuttgart, Germany, https://www.perpus.de