Represents a Subject that takes observers implementing the IObserverNumberChanged interface. More...
Public Member Functions | |
void | SubscribeToNumberChanged (IObserverNumberChanged observer) |
void | UnsubscribeFromNumberChanged (IObserverNumberChanged observer) |
Represents a Subject that takes observers implementing the IObserverNumberChanged interface.
In more complex systems, an interface like this might have multiple subscribe/unsubscribe methods for different kinds of observers. For C#, such multiple methods might actually be one Subscribe/Unsubscribe method that uses overloading to take different observer interfaces.
This interface is use to ensure the Subject implements all the necessary methods to support observers.
Definition at line 61 of file ObserverSubject_NumberProducer.cs.
void SubscribeToNumberChanged | ( | IObserverNumberChanged | observer | ) |
Implemented in ObserverSubject_NumberProducer.
Referenced by Observer_Exercise.Run().
void UnsubscribeFromNumberChanged | ( | IObserverNumberChanged | observer | ) |
Implemented in ObserverSubject_NumberProducer.
Referenced by Observer_Exercise.Run().