|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.Observable com.jfw.status.UpdateObservable
public final class UpdateObservable
All the classes need to be updated must observer this class.
Is a singleton, the only instance is return by method getInstance()
.
Method Summary | |
---|---|
void |
addObserver(java.lang.Object thisClass)
Call method addObserver(Object,String,String) . |
void |
addObserver(java.lang.Object thisClass,
java.lang.String className2Add,
java.lang.String description)
Used for add an instance as observer of this class. |
void |
deleteObserver(java.lang.Object observer)
Call the method deleteObserver(Object,String) . |
void |
deleteObserver(java.lang.Object observer,
java.lang.String className2Del)
Used for remove an observer. |
static UpdateObservable |
getInstance()
Get the attribute updateObservable |
java.util.HashMap |
getObservers()
Get a clone of the attribute observers . |
void |
update()
Notify the observers to be update. |
Methods inherited from class java.util.Observable |
---|
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static UpdateObservable getInstance()
updateObservable
public java.util.HashMap getObservers()
observers
.
observers
.public void addObserver(java.lang.Object thisClass, java.lang.String className2Add, java.lang.String description)
thisClass
- the instance to add as observer.className2Add
- the name of the observer class.description
- the description of the observer.public void addObserver(java.lang.Object thisClass)
addObserver(Object,String,String)
. The values of
parameters className2Add and description are the blank string.
thisClass
- the instance to add as observer.public void deleteObserver(java.lang.Object observer, java.lang.String className2Del)
observer
- the observer to remove.className2Del
- if the value is not null then this name is used
for remove the oberver class.public void deleteObserver(java.lang.Object observer)
deleteObserver(Object,String)
. The value of
parameter className2Del is null.
observer
- the observer to remove.public void update()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |