FileDocCategorySizeDatePackage
PersistentPanel.javaAPI DocExample2294Sat Feb 01 07:40:10 GMT 1997imaginary.gui

PersistentPanel

public abstract class PersistentPanel extends Panel implements imaginary.util.RemoteObserver, ChangeObserver
The PersistentPanel class is a Java panel that observes changes in Persistent instances.

Fields Summary
private imaginary.persist.RemoteLockHolder
lock_holder
private imaginary.persist.RemotePersistent
observed
Constructors Summary
public PersistentPanel(imaginary.persist.RemoteLockHolder h)
Constructs a PersistentPanel for the specified lock holder.

param
h the lock holder owning this panel
exception
java.rmi.RemoteException An error occurred exporting the panel.


                                 
         
        super();
        UnicastRemoteObject.exportObject(this);
        observed = null;
        lock_holder = h;
    
public PersistentPanel(imaginary.persist.RemoteLockHolder h, imaginary.persist.RemotePersistent p)
Constructs a PersistentPanel observing the specified persistent.

param
h the lock holder owning this panel
param
p the persistent being observed
exception
java.rmi.RemoteException An error occurred exporting the panel.

        super();
        UnicastRemoteObject.exportObject(this);
        observed = p;
        lock_holder = h;
        p.addObserver(this);
    
Methods Summary
protected imaginary.persist.RemoteLockHoldergetLockHolder()

return
the lock holder

        return lock_holder;
    
public imaginary.persist.RemotePersistentgetObserved()
The persistent being observed

        return observed;
    
public voidupdate(imaginary.util.RemoteObservable target, java.lang.Object arg)
Implementation of the observer method for receiving updates. This in turn places the notification in an asynchronous queue that allows it to be processed later.

param
target the changed object
param
arg any args passed to this for the change

	ChangeMonitor.postChange(this);