|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Settings is a shorter word for Properties. It's also an an interface, which is different from Properties. It also adds support for setting change notification.
Field Summary | |
static String |
REVISION
|
Method Summary | |
void |
addSettingsListener(SettingsListener listener)
Registers a listener with this settings object so that it receives notification when this settings object changes. |
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 |
removeSettingsListener(SettingsListener listener)
Removes a listener from the list of objects that are notified when this settings object changes. |
void |
set(String name,
Object value)
Sets the value of a setting. |
Field Detail |
public static final String REVISION
Method Detail |
public Iterator getNames()
public Object get(String name)
name
- the name of the setting to look up
IllegalArgumentException
- if the supplied setting name is
nullpublic void set(String name, Object value)
name
- the name of the setting to set the value ofvalue
- the (new) value of the setting
IllegalArgumentException
- if either of the supplied
arguments are null
UnsupportedOperationException
- if settings cannot be set on
this settings object.public void remove(String name)
name
- the name of the setting to remove
IllegalArgumentException
- if the supplied setting name is
null
UnsupportedOperationException
- if settings cannot be removed
from this settings object.public void addSettingsListener(SettingsListener listener)
listener
- the listener to register
IllegalArgumentException
- if the specified listener is nullpublic void removeSettingsListener(SettingsListener listener)
listener
- the listener to unregister
IllegalArgumentException
- if the specified listener is null
or if it was not null but was not
previously registered as a
listener with this settings
object.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |