com.caucho.jca.cfg
Class Resource

java.lang.Object
  extended by com.caucho.jca.cfg.Resource

public class Resource
extends java.lang.Object

Configuration for the init-param pattern.


Nested Class Summary
 class Resource.MBeanInit
           
 class Resource.MBeanListener
           
 
Constructor Summary
Resource()
           
 
Method Summary
 void addArg(java.lang.Object arg)
          Adds an argument.
 void addInit(ContainerProgram init)
          Adds the init program
 java.lang.Object createListener()
          Adds the listener program
 java.lang.Object createMbeanListener()
          Adds the listener program
 java.lang.String getJndiName()
          Gets the JNDI name
 java.lang.String getMbeanName()
          Gets the mbean name
 java.lang.String getName()
          Gets the WebBeans name
 java.lang.Class<?> getType()
          Gets the type;
 void init()
          Initialize the resource.
 void setClass(java.lang.Class<?> resourceClass)
          Sets the class
 void setJndiName(java.lang.String name)
          Sets the JNDI name
 void setLocalTransactionOptimization(boolean enable)
          Sets the local-transaction-optimization flag
 void setMbeanInterface(java.lang.Class<?> cl)
          Sets the class
 void setMbeanName(java.lang.String name)
          Sets the mbean name
 void setName(java.lang.String name)
          Sets the WebBeans name
 void setShareable(boolean shareable)
          Sets the shareable
 void setType(java.lang.Class<?> resourceClass)
          Sets the class
 void setVar(java.lang.String var)
          Sets the config variable name.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Resource

public Resource()
Method Detail

setVar

public void setVar(java.lang.String var)
Sets the config variable name.


setJndiName

public void setJndiName(java.lang.String name)
Sets the JNDI name


getJndiName

public java.lang.String getJndiName()
Gets the JNDI name


setName

public void setName(java.lang.String name)
Sets the WebBeans name


getName

public java.lang.String getName()
Gets the WebBeans name


setMbeanName

public void setMbeanName(java.lang.String name)
Sets the mbean name


getMbeanName

public java.lang.String getMbeanName()
Gets the mbean name


setType

public void setType(java.lang.Class<?> resourceClass)
Sets the class


setClass

public void setClass(java.lang.Class<?> resourceClass)
Sets the class


getType

public java.lang.Class<?> getType()
Gets the type;


setMbeanInterface

public void setMbeanInterface(java.lang.Class<?> cl)
Sets the class


addArg

public void addArg(java.lang.Object arg)
Adds an argument.


setLocalTransactionOptimization

public void setLocalTransactionOptimization(boolean enable)
Sets the local-transaction-optimization flag


setShareable

public void setShareable(boolean shareable)
Sets the shareable


addInit

public void addInit(ContainerProgram init)
Adds the init program


createListener

public java.lang.Object createListener()
                                throws java.lang.Exception
Adds the listener program

Throws:
java.lang.Exception

createMbeanListener

public java.lang.Object createMbeanListener()
                                     throws java.lang.Exception
Adds the listener program

Throws:
java.lang.Exception

init

@PostConstruct
public void init()
          throws java.lang.Throwable
Initialize the resource.

Throws:
java.lang.Throwable

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object