Package | Description |
---|---|
ex2 |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
Test.DurationObserver
ListObserver implementation for keeping track of all events that have a
duration bigger than a threshold.
|
(package private) static class |
Test.PrintObserver
ListObserver implementation for printing to stdout all information about
the events, when it's notified of their occurrence.
|
Modifier and Type | Field and Description |
---|---|
protected List<ListObserver> |
MyArrayList.observers
The objects that monitor this list aka observers that the list will
notify when an event occurs.
|
Modifier and Type | Method and Description |
---|---|
void |
MyArrayList.addObserver(ListObserver o)
Registers an observer that will receive notifications about the
list's events.
|
void |
Observable.addObserver(ListObserver o)
Register an observer.
|
void |
MyArrayList.removeObserver(ListObserver o)
Removes an observer.
|
void |
Observable.removeObserver(ListObserver o)
Unregister an observer.
|