Qore DataProvider Module Reference
2.7
|
This class represents an observable subject that will notify all of its registered observers. More...
Public Member Methods | |
bool | deregisterObserver (object observer) |
The method deregisters the given observer. More... | |
bool | deregisterObserver (Observer observer) |
The method deregisters the given observer. More... | |
log (int level, string fmt) | |
Reimplement this method to implement logging. More... | |
notifyObservers (string event_id, hash< auto > data_) | |
The method notifies all subscribed observers. More... | |
registerObserver (object observer) | |
The method registers the given observer. More... | |
registerObserver (Observer observer) | |
The method registers the given observer. More... | |
registerObserverWithFilter (object observer, AbstractEventFilter filter) | |
The method registers the given observer. More... | |
registerObserverWithFilter (Observer observer, AbstractEventFilter filter) | |
The method registers the given observer. More... | |
Private Member Methods | |
hash< ObserverEventInfo > | registerObserverEventsArgs (hash< ObserverEventInfo > info, list< auto > events) |
Registers observer events. | |
Private Attributes | |
hash< string, hash< ObserverEventInfo > > | observer_map |
maps from object hash -> object | |
This class represents an observable subject that will notify all of its registered observers.
bool DataProvider::Observable::deregisterObserver | ( | object | observer | ) |
The method deregisters the given observer.
observer | the observer to be deregistered |
bool DataProvider::Observable::deregisterObserver | ( | Observer | observer | ) |
The method deregisters the given observer.
observer | the observer to be deregistered |
Reimplement this method to implement logging.
level | the Logger level |
fmt | the format string |
... | any arguments for any format placeholders in fmt |
The method notifies all subscribed observers.
event_id | unique ID identifying an event |
data_ | hash representing new data to be passed to observers' update() methods |
DataProvider::Observable::registerObserver | ( | object | observer | ) |
The method registers the given observer.
observer | the observer to be registered |
... | event IDs for notifications; if no additional arguments are passed, then the observer is notified for all events |
DataProvider::Observable::registerObserver | ( | Observer | observer | ) |
The method registers the given observer.
observer | the observer to be registered |
... | event IDs for notifications; if no additional arguments are passed, then the observer is notified for all events |
EVENT-ERROR | type error; additional argument is not a string event ID |
DataProvider::Observable::registerObserverWithFilter | ( | object | observer, |
AbstractEventFilter | filter | ||
) |
The method registers the given observer.
observer | the observer to be registered |
filter | the filter object for events |
... | event IDs for notifications; if no additional arguments are passed, then the observer is notified for all events |
DataProvider::Observable::registerObserverWithFilter | ( | Observer | observer, |
AbstractEventFilter | filter | ||
) |
The method registers the given observer.
observer | the observer to be registered |
filter | the filter object for events |
... | event IDs for notifications; if no additional arguments are passed, then the observer is notified for all events |
EVENT-ERROR | type error; additional argument is not a string event ID |