|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.catalina.core.NamingContextListener
Helper class used to initialize and populate the JNDI context associated with each context and server.
Field Summary | |
protected javax.naming.Context |
compCtx
Comp context. |
protected java.lang.Object |
container
Associated container. |
protected int |
debug
Debugging level. |
protected javax.naming.Context |
envCtx
Env context. |
protected boolean |
initialized
Initialized flag. |
protected java.lang.String |
name
Name of the associated naming context. |
protected NamingContext |
namingContext
Associated JNDI context. |
protected NamingResources |
namingResources
Associated naming resources. |
protected static StringManager |
sm
The string manager for this package. |
Constructor Summary | |
NamingContextListener()
Create a new naming context listener. |
Method Summary | |
void |
addEjb(ContextEjb ejb)
Set the specified EJBs in the naming context. |
void |
addEnvironment(ContextEnvironment env)
Set the specified environment entries in the naming context. |
void |
addLocalEjb(ContextLocalEjb localEjb)
Set the specified local EJBs in the naming context. |
void |
addResource(ContextResource resource)
Set the specified resources in the naming context. |
void |
addResourceEnvRef(java.lang.String name,
java.lang.String type)
Set the specified resources in the naming context. |
void |
addResourceLink(ContextResourceLink resourceLink)
Set the specified resource link in the naming context. |
void |
containerEvent(ContainerEvent event)
Acknowledge the occurrence of the specified event. |
int |
getDebug()
Return the "debug" property. |
java.lang.String |
getName()
Return the "name" property. |
NamingContext |
getNamingContext()
Return the associated naming context. |
void |
lifecycleEvent(LifecycleEvent event)
Acknowledge the occurrence of the specified event. |
protected void |
log(java.lang.String message)
Log the specified message to our current Logger (if any). |
protected void |
log(java.lang.String message,
java.lang.Throwable throwable)
Log the specified message and exception to our current Logger (if any). |
protected java.lang.String |
logName()
Return the abbreviated name of this container for logging messsages |
void |
propertyChange(java.beans.PropertyChangeEvent event)
Process property change events. |
void |
removeEjb(java.lang.String name)
Set the specified EJBs in the naming context. |
void |
removeEnvironment(java.lang.String name)
Set the specified environment entries in the naming context. |
void |
removeLocalEjb(java.lang.String name)
Set the specified local EJBs in the naming context. |
void |
removeResource(java.lang.String name)
Set the specified resources in the naming context. |
void |
removeResourceEnvRef(java.lang.String name)
Set the specified resources in the naming context. |
void |
removeResourceLink(java.lang.String name)
Set the specified resources in the naming context. |
void |
setDebug(int debug)
Set the "debug" property. |
void |
setName(java.lang.String name)
Set the "name" property. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.lang.String name
protected java.lang.Object container
protected int debug
protected boolean initialized
protected NamingResources namingResources
protected NamingContext namingContext
protected javax.naming.Context compCtx
protected javax.naming.Context envCtx
protected static StringManager sm
Constructor Detail |
public NamingContextListener()
Method Detail |
public int getDebug()
public void setDebug(int debug)
debug
- The new debug levelpublic java.lang.String getName()
public void setName(java.lang.String name)
name
- The new namepublic NamingContext getNamingContext()
public void lifecycleEvent(LifecycleEvent event)
lifecycleEvent
in interface LifecycleListener
event
- LifecycleEvent that has occurredpublic void containerEvent(ContainerEvent event)
containerEvent
in interface ContainerListener
event
- ContainerEvent that has occurredpublic void propertyChange(java.beans.PropertyChangeEvent event)
NamingResources
instance for the global naming
resources.
propertyChange
in interface java.beans.PropertyChangeListener
event
- The property change event that has occurredpublic void addEjb(ContextEjb ejb)
public void addEnvironment(ContextEnvironment env)
public void addLocalEjb(ContextLocalEjb localEjb)
public void addResource(ContextResource resource)
public void addResourceEnvRef(java.lang.String name, java.lang.String type)
public void addResourceLink(ContextResourceLink resourceLink)
public void removeEjb(java.lang.String name)
public void removeEnvironment(java.lang.String name)
public void removeLocalEjb(java.lang.String name)
public void removeResource(java.lang.String name)
public void removeResourceEnvRef(java.lang.String name)
public void removeResourceLink(java.lang.String name)
protected void log(java.lang.String message)
message
- Message to be loggedprotected void log(java.lang.String message, java.lang.Throwable throwable)
message
- Message to be loggedthrowable
- Related exceptionprotected java.lang.String logName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |