|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A proxy for some value that can be read and written, and to which interested listeners may subscribe to receive change notification. SourceSink serves a similar function to the Swing ListModel and TreeModel classes in that it abstracts notions of reading, modifying, and change notification away from the value objects themselves. But where ListModel and TreeModel perform this function for values organized in list or tree form, SourceSink provides it for individual values.
Method Summary | |
void |
addChangeListener(ChangeListener l)
Add the specified listener to the list of interested change listeners. |
Object |
get()
Retrieve some value. |
void |
removeChangeListener(ChangeListener l)
Remove the specified listener from the list of interested change listeners. |
void |
set(Object value)
Store some value. |
Method Detail |
public Object get()
public void set(Object value)
value
- The value to be stored. In general, if a value
is stored via set(), the value retrieved by a subsequent
get() call will equal the set value as defined by the value's
equals() method.public void addChangeListener(ChangeListener l)
l
- The listener to add.public void removeChangeListener(ChangeListener l)
l
- The listener to remove.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |