+
Point of view
All features
deferred class OBSERVABLE
Summary
Part of the Observer Design Pattern. An object of this class should notify its observers whenever its state changes. Use the notify feature for that.
See also OBSERVER.
Direct parents
Insert list: ANY
Class invariant
Overview
Features
{ANY}
  • add (o: OBSERVER[OBSERVABLE])
    Add an observer that should be notified
  • remove (o: OBSERVER[OBSERVABLE])
    Remove an observer that should not be notified anymore
  • has (o: OBSERVER[OBSERVABLE]): BOOLEAN
    True if the observer will be notified when the state of Current changes
{}
  • notify
    Notify all the observers that the state of Current changed
{}
  • observers: COLLECTION[OBSERVER[OBSERVABLE]]
    The collection of observers
add (o: OBSERVER[OBSERVABLE])
effective procedure
{ANY}
Add an observer that should be notified
remove (o: OBSERVER[OBSERVABLE])
effective procedure
{ANY}
Remove an observer that should not be notified anymore
require
has (o: OBSERVER[OBSERVABLE]): BOOLEAN
effective function
{ANY}
True if the observer will be notified when the state of Current changes
notify
effective procedure
{}
Notify all the observers that the state of Current changed
observers: COLLECTION[OBSERVER[OBSERVABLE]]
writable attribute
{}
The collection of observers