Class WeakReferenceObservable

    • Constructor Detail

      • WeakReferenceObservable

        public WeakReferenceObservable​(IObservable observable)
        Creates a new WeakReferenceObservable object with a given IObservable object.
        Parameters:
        observable - the object to observe.
    • Method Detail

      • addObserver

        public void addObserver​(IObserver observer)
        Description copied from interface: IObservable
        Attaches a observer to the Observable. After attachment the observer gets informed about changes in the Observable.
        Specified by:
        addObserver in interface IObservable
        Overrides:
        addObserver in class BaseObservable
        Parameters:
        observer - The observer to attach to the observable
      • deleteObserver

        public void deleteObserver​(IObserver observer)
        Description copied from interface: IObservable
        Detaches a previously attached observer to the observable. After detachment the observer does no longer receive change notifications from the observable.
        Specified by:
        deleteObserver in interface IObservable
        Overrides:
        deleteObserver in class BaseObservable
        Parameters:
        observer - The observer to detach from the observable