|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.ext.jflexsett.settings.Settings
Contains all Settings Groups and there settings. The Settings class is the only class which needs to be referenced to add groups, add settings, get settings and get values of settings.
Constructor Summary | |
Settings()
|
Method Summary | |
static void |
addGroup(java.lang.String sKey,
SettingsGroup group)
Adds a group to the hashtable. |
static void |
addSetting(java.lang.String sGroupKey,
Setting setting)
Adds a setting to a specified group. |
static java.util.Vector |
getFlatSettingsGroups()
Retrieves all settings groups without an hierarchy |
static Setting |
getSetting(java.lang.String sSettingsKey)
Retrieves a setting |
static java.util.Vector |
getSettings()
Retrieves all the settings |
static java.io.File |
getSettingsFile()
|
static java.util.Hashtable |
getSettingsGroups()
Retrieves all the top-level groups |
static java.lang.Object |
getValue(java.lang.String sKey)
Retrieves a value of a settings |
static boolean |
getValueAsBoolean(java.lang.String sKey)
Returns the value of the setting as a boolean |
static java.awt.Color |
getValueAsColor(java.lang.String sKey)
Returns the value of the setting as a color object |
static java.awt.Dimension |
getValueAsDimension(java.lang.String sKey)
Returns the value of the setting as a String |
static java.awt.Font |
getValueAsFont(java.lang.String sKey)
|
static int |
getValueAsInt(java.lang.String sKey)
Returns the value of the setting as an integer |
static int[] |
getValueAsIntegerArray(java.lang.String sKey)
|
static java.lang.String |
getValueAsString(java.lang.String sKey)
Returns the value of the setting as a String |
static java.lang.String[] |
getValueAsStringArray(java.lang.String sKey)
Returns the value of the setting as a String array |
static boolean |
isSettingKeyValid(java.lang.String sKey)
|
static void |
setSettingsFile(java.io.File file)
Specifies the location and name of the settings file |
static void |
setStringAsValue(java.lang.String sKey,
java.lang.String sValue)
Sets a string as a value for the setting (by parsing the string) |
static void |
setValue(java.lang.String sKey,
java.lang.Object oValue)
Sets the value of a setting |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Settings()
Method Detail |
public static void addGroup(java.lang.String sKey, SettingsGroup group)
sKey
- unique identifier for this groupgroup
- a top-level group (parent)public static void setSettingsFile(java.io.File file)
file
- the settings filepublic static java.io.File getSettingsFile()
public static void addSetting(java.lang.String sGroupKey, Setting setting)
sGroupKey
- the key of the groupsetting
- the setting to be added to the specified grouppublic static boolean isSettingKeyValid(java.lang.String sKey)
public static Setting getSetting(java.lang.String sSettingsKey)
sSettingsKey
- the settings keypublic static java.lang.Object getValue(java.lang.String sKey)
sKey
- the settings keypublic static java.lang.String[] getValueAsStringArray(java.lang.String sKey)
sKey
- the settings keypublic static int[] getValueAsIntegerArray(java.lang.String sKey)
public static java.awt.Font getValueAsFont(java.lang.String sKey)
public static int getValueAsInt(java.lang.String sKey)
sKey
- the settings keypublic static boolean getValueAsBoolean(java.lang.String sKey)
sKey
- the settings keypublic static java.awt.Color getValueAsColor(java.lang.String sKey)
sKey
- the settings keypublic static java.awt.Dimension getValueAsDimension(java.lang.String sKey)
sKey
- the settings keypublic static java.lang.String getValueAsString(java.lang.String sKey)
sKey
- the settings keypublic static void setValue(java.lang.String sKey, java.lang.Object oValue)
sKey
- the settings keyoValue
- the valuepublic static void setStringAsValue(java.lang.String sKey, java.lang.String sValue)
sKey
- the settings keysValue
- the string value to be parsedpublic static java.util.Hashtable getSettingsGroups()
public static java.util.Vector getFlatSettingsGroups()
public static java.util.Vector getSettings()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |