The Observer Remote Objects
In our application, the observer methods must be remotely callable by the
thermometer so that the thermometer can inform the observer(s) of any
change in its state. Thus the observers must be implemented as remote
objects also.
Next we have the code for the ThermObserver interface and the ThermObserver
implementation.
package therm;
public interface ThermObserver extends java.rmi.Remote
{
public void update(Object o, Object x) throws java.rmi.RemoteException;
}