ibis.rmi.registry
Interface Registry

All Superinterfaces:
Remote

public interface Registry
extends Remote

A Registry is a remote interface to a remote-object registry. It provides methods for binding and looking-up remote object references bound to names.


Field Summary
static int REGISTRY_PORT
          Well known port for RMI registry.
 
Method Summary
 void bind(String name, Remote obj)
          Binds the specified remote reference to the specified name.
 String[] list()
          Returns an array of names bound in this registry.
 Remote lookup(String name)
          Returns the remote reference bound to the specified name.
 void rebind(String name, Remote obj)
          Rebinds the specified remote reference to the specified name.
 void unbind(String name)
          Removes the binding for the specified name.
 

Field Detail

REGISTRY_PORT

static final int REGISTRY_PORT
Well known port for RMI registry.

See Also:
Constant Field Values
Method Detail

lookup

Remote lookup(String name)
              throws RemoteException,
                     NotBoundException
Returns the remote reference bound to the specified name.

Parameters:
name - the name to look up
Returns:
a reference to the remote object
Throws:
NotBoundException - if the name is not bound
RemoteException - if communication with the registry failed.

bind

void bind(String name,
          Remote obj)
          throws RemoteException,
                 AlreadyBoundException
Binds the specified remote reference to the specified name.

Parameters:
name - the name to bind the reference to
obj - the remote reference
Throws:
AlreadyBoundException - is the name is already bound
RemoteException - if communication with the registry failed.

unbind

void unbind(String name)
            throws RemoteException,
                   NotBoundException
Removes the binding for the specified name.

Parameters:
name - the name to unbind
Throws:
NotBoundException - if the name is not bound
RemoteException - if communication with the registry failed.

rebind

void rebind(String name,
            Remote obj)
            throws RemoteException
Rebinds the specified remote reference to the specified name. Any existing binding for the name is replaced.

Parameters:
name - the name to bind the reference to
obj - the remote reference
Throws:
RemoteException - if communication with the registry failed.

list

String[] list()
              throws RemoteException
Returns an array of names bound in this registry.

Returns:
an array of names
Throws:
RemoteException - if communication with the registry failed.


The Ibis project