@Equality public class Setting extends Object
The equality constraint is required to aid factorisation.
Constructor and Description |
---|
Setting(String key,
String strValue,
String strDflt)
Constructs a setting.
|
Modifier and Type | Method and Description |
---|---|
Setting |
appendSuffix(String suffix)
Creates a new setting object which resembles this one,
but whose parameter name is modified by addition of a given
trailing string.
|
boolean |
equals(Object o) |
Credibility |
getCredibility()
Returns the credibility of this setting.
|
String |
getKey()
Returns this setting's parameter name.
|
Object |
getObjectValue()
Returns the typed value for this setting, if known.
|
String |
getStringDefault()
Returns the string representation of the default value for
this setting.
|
String |
getStringValue()
Returns the string representation of this setting's value.
|
int |
hashCode() |
boolean |
isDefaultValue()
Indicates whether this setting's value is the same as the
default value.
|
Setting |
resetDefault(String strDflt)
Creates a new setting object which resembles this one,
except it has a different default value.
|
void |
setCredibility(Credibility cred)
Sets the credibility of this setting.
|
void |
setObjectValue(Object objValue)
Sets the typed value associated with this setting.
|
static String |
shellQuote(String txt)
Quotes a string as required for use on a shell command line.
|
String |
toString() |
public Setting(String key, String strValue, String strDflt)
key
- stilts parameter namestrValue
- string representation of stilts parameter value;
corresponds to actual valuestrDflt
- string representation of stilts parameter defaultpublic String getKey()
public String getStringValue()
public String getStringDefault()
public boolean isDefaultValue()
public void setObjectValue(Object objValue)
objValue
- typed value for settingpublic Object getObjectValue()
public void setCredibility(Credibility cred)
Credibility.YES
.cred
- credibility levelpublic Credibility getCredibility()
Credibility.YES
.public Setting appendSuffix(String suffix)
suffix
- string to append to parameter namepublic Setting resetDefault(String strDflt)
strDflt
- new default stringpublic static String shellQuote(String txt)
txt
- string to quoteCopyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.