com.xenonsoft.bridgetown.app
Class JNDILookupServiceBean

java.lang.Object
  extended bycom.xenonsoft.bridgetown.app.JNDILookupServiceBean

public class JNDILookupServiceBean
extends java.lang.Object

A basic class to look for a object inside the JNDI provider and return to the users

In order to use to this lookup bean simply define environment properties for your particular application server.

The following defines a secure WebLogic JNDI Provider:

 java.naming.factory.initial = weblogic.jndi.WLInitialContextFactory
 java.naming.provider.url = t3://localhost:7001
 java.naming.security.principal = username
 java.naming.security.credentials = password
 java.naming.security.protocol = ssl
 

The last three properties are optional, if the JNDI provider is not secured by a login user and obviously SSL.

Version:
$Id$
Author:
Peter Pilgrim, 07-Feb-2005 19:42:51
See Also:
Context

Field Summary
protected  java.util.Properties environment
          The properties optionally defined for JNDI initial context
protected  java.lang.String lookupName
          The name bean to retrieve using JNDI
 
Constructor Summary
JNDILookupServiceBean()
          Default constructor
 
Method Summary
 java.util.Properties getEnvironment()
          Gets the environment
 java.lang.String getLookupName()
          Gets the lookupName
 java.lang.Object getTarget()
          Retrieve the target object using the JNDI name
 void setEnvironment(java.util.Properties environment)
          Sets the environment
 void setLookupName(java.lang.String lookupName)
          Sets the lookupName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lookupName

protected java.lang.String lookupName
The name bean to retrieve using JNDI


environment

protected java.util.Properties environment
The properties optionally defined for JNDI initial context

Constructor Detail

JNDILookupServiceBean

public JNDILookupServiceBean()
Default constructor

Method Detail

getEnvironment

public java.util.Properties getEnvironment()
Gets the environment

Returns:
Returns the environment.

setEnvironment

public void setEnvironment(java.util.Properties environment)
Sets the environment

Parameters:
environment - the new value for environment

getLookupName

public java.lang.String getLookupName()
Gets the lookupName

Returns:
Returns the lookupName.

setLookupName

public void setLookupName(java.lang.String lookupName)
Sets the lookupName

Parameters:
lookupName - the new value for lookupName

getTarget

public java.lang.Object getTarget()
                           throws java.lang.Exception
Retrieve the target object using the JNDI name

Returns:
the target object or null
Throws:
java.lang.Exception - if operation of Japan. fails
the - target object


Copyright © 2005 XeNoNSoFT.com. All Rights Reserved.