I have a class that implements observer, and of course it needs to have the update function:
public void update(Observable obs, Object obj);
The observer's update(Observable obs,Object obj) method receives through the notifyObservers the object(second parameter) who has changed(in the Observable).