com.rmiproxy.jndi.rmiproxy.registry
Class RegistryContextFactory
java.lang.Object
|
+--com.rmiproxy.jndi.rmiproxy.registry.RegistryContextFactory
- All Implemented Interfaces:
- javax.naming.spi.InitialContextFactory, javax.naming.spi.ObjectFactory
- public class RegistryContextFactory
- extends java.lang.Object
- implements javax.naming.spi.ObjectFactory, javax.naming.spi.InitialContextFactory
A RegistryContextFactory takes an RMI registry reference, and
creates the corresponding RMI object or registry context. In
addition, it serves as the initial context factory when using an
RMI registry as an initial context.
When an initial context is being created, the environment
property "java.naming.provider.url" should contain the RMI URL of
the appropriate registry. Otherwise, the default URL "rmi:" is used.
An RMI registry reference contains one or more StringRefAddrs of
type "URL", each containing a single RMI URL. Other addresses
are ignored. Multiple URLs represent alternative addresses for the
same logical resource. The order of the addresses is not significant.
|
Field Summary |
static java.lang.String |
ADDRESS_TYPE
The type of each address in an RMI registry reference. |
|
Method Summary |
javax.naming.Context |
getInitialContext(java.util.Hashtable env)
|
java.lang.Object |
getObjectInstance(java.lang.Object ref,
javax.naming.Name name,
javax.naming.Context nameCtx,
java.util.Hashtable env)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ADDRESS_TYPE
public static final java.lang.String ADDRESS_TYPE
- The type of each address in an RMI registry reference.
RegistryContextFactory
public RegistryContextFactory()
getInitialContext
public javax.naming.Context getInitialContext(java.util.Hashtable env)
throws javax.naming.NamingException
- Specified by:
getInitialContext in interface javax.naming.spi.InitialContextFactory
getObjectInstance
public java.lang.Object getObjectInstance(java.lang.Object ref,
javax.naming.Name name,
javax.naming.Context nameCtx,
java.util.Hashtable env)
throws javax.naming.NamingException
- Specified by:
getObjectInstance in interface javax.naming.spi.ObjectFactory
Copyright © 2000, 2003 Telekinesis Pty Ltd, Box 82/85 Grattan St, Carlton 3053, Victoria, Australia. All rights reserved.