com.jproxy.proxy
Class NamingContextFactory

java.lang.Object
  extended bycom.jproxy.proxy.NamingContextFactory
All Implemented Interfaces:
javax.naming.spi.InitialContextFactory, javax.naming.spi.ObjectFactory

public class NamingContextFactory
extends java.lang.Object
implements javax.naming.spi.InitialContextFactory, javax.naming.spi.ObjectFactory

JNDI Naming Sevice SPI implementation for Tunneling. It is a proxy Naming Service to real service declared in INITIAL_CONTEXT_FACTORY


Constructor Summary
NamingContextFactory()
           
 
Method Summary
 javax.naming.Context getInitialContext(java.util.Hashtable env)
          Returns context for JNDI server declared in INITIAL_CONTEXT_FACTORY.
 java.lang.Object getObjectInstance(java.lang.Object obj, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable environment)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NamingContextFactory

public NamingContextFactory()
Method Detail

getInitialContext

public javax.naming.Context getInitialContext(java.util.Hashtable env)
                                       throws javax.naming.NamingException
Returns context for JNDI server declared in INITIAL_CONTEXT_FACTORY. If Callbacks are enabled then it creates instance of HttpCallbackServer remote object and binds the object to obtained naming context. Supports multiple comma separated URLs in property "java.naming.provider.url". The feature allows client perform several connection attempts to different servers before throwing exception.

Specified by:
getInitialContext in interface javax.naming.spi.InitialContextFactory
Parameters:
env - environment
Throws:
javax.naming.NamingException

getObjectInstance

public java.lang.Object getObjectInstance(java.lang.Object obj,
                                          javax.naming.Name name,
                                          javax.naming.Context nameCtx,
                                          java.util.Hashtable environment)
                                   throws java.lang.Exception
Specified by:
getObjectInstance in interface javax.naming.spi.ObjectFactory
Throws:
java.lang.Exception


Copyright © JProxy LLC. All Rights Reserved.