Subject
module wntr.network.controls
-
class Subject[source]
Bases: object
A subject base class for the observer design pattern
-
__init__()[source]
-
notify()[source]
Call the update method for all observers of this subject.
-
subscribe(observer)[source]
Subscribe observer to this subject. The update method of any observers of this subject will be called when
notify is called on this subject.
- Parameters:
observer (Observer)
-
unsubscribe(observer)[source]
Unsubscribe observer from this subject.
- Parameters:
observer (Observer)