net.sourceforge.jaulp.designpattern.observer
Class AbstractObserver<T>

java.lang.Object
  extended by net.sourceforge.jaulp.designpattern.observer.AbstractObserver<T>
All Implemented Interfaces:
DisplayViewElement, Observer<T>

public abstract class AbstractObserver<T>
extends java.lang.Object
implements Observer<T>, DisplayViewElement

An abstract generic implementation from the Observer-Pattern.


Constructor Summary
AbstractObserver(Subject<T> subject)
          This method is called when information about an Abstract which was previously requested using an asynchronous interface becomes available.
 
Method Summary
 T getObservable()
          This method is called when information about an Abstract which was previously requested using an asynchronous interface becomes available.
 void update(T observable)
          Update.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.sourceforge.jaulp.designpattern.observer.ifaces.DisplayViewElement
displayView
 

Constructor Detail

AbstractObserver

public AbstractObserver(Subject<T> subject)
This method is called when information about an Abstract which was previously requested using an asynchronous interface becomes available.

Parameters:
subject - the subject
Method Detail

getObservable

public T getObservable()
This method is called when information about an Abstract which was previously requested using an asynchronous interface becomes available.

Returns:
the observable

update

public void update(T observable)
Update.

Specified by:
update in interface Observer<T>
Parameters:
observable - the observable
See Also:
Observer.update(java.lang.Object)


Copyright © 2010. All Rights Reserved.