org.rosuda.util
Class GlobalConfig

java.lang.Object
  extended by org.rosuda.util.GlobalConfig

public class GlobalConfig
extends java.lang.Object


Constructor Summary
GlobalConfig()
           
 
Method Summary
 java.lang.Object[] getAllParameters()
          each parameter name consists of the plugin name and the parameter name, separated by a dot.
static GlobalConfig getGlobalConfig()
           
 java.lang.String getParS(java.lang.String Par)
          get String-valued parameter
static java.lang.String getS(java.lang.String Par)
           
 boolean loadSettings()
          load settings from the current config file
 boolean loadSettings(java.lang.String fName)
          load settings from the specified file. note that the specified file is NOT automatically used as current config file.
 boolean saveSettings()
          save settings to the current config file
 boolean setParS(java.lang.String Par, java.lang.String Val)
          set String-valued parameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GlobalConfig

public GlobalConfig()
Method Detail

getGlobalConfig

public static GlobalConfig getGlobalConfig()

getParS

public java.lang.String getParS(java.lang.String Par)
get String-valued parameter

Parameters:
Par - name of the parameter
Returns:
parameter value or null if such parameter doesn't exist

getS

public static java.lang.String getS(java.lang.String Par)

getAllParameters

public java.lang.Object[] getAllParameters()
each parameter name consists of the plugin name and the parameter name, separated by a dot. there is no particular order in which the parameters are returned (actually it is order of creation/loading)


setParS

public boolean setParS(java.lang.String Par,
                       java.lang.String Val)
set String-valued parameter

Parameters:
Par - name of the parameter
Val - value to be set
Returns:
true if successful, false otherwise

saveSettings

public boolean saveSettings()
save settings to the current config file


loadSettings

public boolean loadSettings()
load settings from the current config file

Returns:
true on success, false otherwise

loadSettings

public boolean loadSettings(java.lang.String fName)
load settings from the specified file. note that the specified file is NOT automatically used as current config file.

Returns:
true on success, false otherwise