org.sapia.regis.remote.client
Class RemoteRegistryFactory

java.lang.Object
  extended by org.sapia.regis.remote.client.RemoteRegistryFactory
All Implemented Interfaces:
RegistryFactory

public class RemoteRegistryFactory
extends Object
implements RegistryFactory

This class implements a factory that looks up a remote registry. The remote registry is a registry server stub that is made available on the network in one of two ways (using a RegistryExporter):

Then, an instance of this class is used to lookup the registry. The instance expects properties that specify either the JNDI name of the registry and connection URL of the JNDI server in which it is published; or the IP address/port to which the registry is bound.

Author:
yduchesne
See Also:
RegistryExporter

Field Summary
static String ADDRESS
          This constant corresponds to the property that specifies the address of the host on which the remote registry is bound.
static String JNDI_NAME
          This constant corresponds to the property that specifies the JNDI name under which to lookup the remote registry.
static String PORT
          This constant corresponds to the property that specifies the port to which the remote registry is bound.
 
Constructor Summary
RemoteRegistryFactory()
           
 
Method Summary
 Registry connect(Properties props)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JNDI_NAME

public static final String JNDI_NAME
This constant corresponds to the property that specifies the JNDI name under which to lookup the remote registry.

See Also:
Constant Field Values

ADDRESS

public static final String ADDRESS
This constant corresponds to the property that specifies the address of the host on which the remote registry is bound.

See Also:
Constant Field Values

PORT

public static final String PORT
This constant corresponds to the property that specifies the port to which the remote registry is bound.

See Also:
Constant Field Values
Constructor Detail

RemoteRegistryFactory

public RemoteRegistryFactory()
Method Detail

connect

public Registry connect(Properties props)
                 throws Exception
Specified by:
connect in interface RegistryFactory
Parameters:
props - the Properties to used to connect to the desired Registry.
Returns:
a Registry.
Throws:
Exception - if a problem occurs while attempting to connect.


Copyright © 2006 Sapia Open Community, Inc. All Rights Reserved.