|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
An interface for attaching and triggering Obses. Basically, each observer (Obs) may observe several combinations of (Object, Object) pairs. The first one of the objects is expected to have '==' equality, generally they will be Dims or objects inside dims. The second object is used through .equals.
This interface is meant for synchronous use: the Obs.chg() methods are called only from the callQueued method of this class.
This is mostly meant to be used inside space implementations.
Obs
Field Summary | |
static java.lang.String |
rcsid
|
Method Summary | |
void |
addObs(Obs o,
java.lang.Object obj,
java.lang.Object code)
Add an observer. |
void |
callQueued()
Call the changed observers. |
void |
chg(java.lang.Object obj,
java.lang.Object code)
Signal that the observers for the given pair should be triggered. |
void |
rmObs(Obs o)
Remove all observations that the given observer is making. |
Field Detail |
public static final java.lang.String rcsid
Method Detail |
public void addObs(Obs o, java.lang.Object obj, java.lang.Object code)
o
- The observer. If null
, nothing is done;
no error may be thrown. (Rationale: otherwise, we
would have to check for nullity in all places that
call addObs
, because they can
(almost) all be passed null
observers.)public void rmObs(Obs o)
public void chg(java.lang.Object obj, java.lang.Object code)
public void callQueued()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |