org.gjt.rec.util
Class BaseSettings

java.lang.Object
  |
  +--org.gjt.rec.util.AbstractSettings
        |
        +--org.gjt.rec.util.BaseSettings
All Implemented Interfaces:
Serializable, Settings

public class BaseSettings
extends AbstractSettings
implements Serializable

BaseSettings is a default implementation of the Settings interface.

Author:
Neil Stockbridge
See Also:
Settings, Serialized Form

Field Summary
static String REVISION
           
 
Constructor Summary
BaseSettings()
           
 
Method Summary
 Object get(String name)
          Looks up the value of a setting.
 Iterator getNames()
          Returns an Iterator over the names of each setting in this settings object.
 void remove(String name)
          Removes a setting.
 void set(String name, Object value)
          Sets the value of a setting.
 
Methods inherited from class org.gjt.rec.util.AbstractSettings
addSettingsListener, fireSettingsChanged, removeSettingsListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REVISION

public static final String REVISION
See Also:
Constant Field Values
Constructor Detail

BaseSettings

public BaseSettings()
Method Detail

getNames

public Iterator getNames()
Description copied from interface: Settings
Returns an Iterator over the names of each setting in this settings object.

Specified by:
getNames in interface Settings

get

public Object get(String name)
Description copied from interface: Settings
Looks up the value of a setting.

Specified by:
get in interface Settings
Parameters:
name - the name of the setting to look up
Returns:
the value of the named setting or null if there was no setting by the that name.

set

public void set(String name,
                Object value)
Description copied from interface: Settings
Sets the value of a setting.

Specified by:
set in interface Settings
Parameters:
name - the name of the setting to set the value of
value - the (new) value of the setting

remove

public void remove(String name)
Description copied from interface: Settings
Removes a setting.

Specified by:
remove in interface Settings
Parameters:
name - the name of the setting to remove