|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.objectweb.jonas_lib.deployment.api.DescriptionGroupDesc org.objectweb.jonas_lib.deployment.api.JndiEnvRefsGroupDesc org.objectweb.jonas_ejb.deployment.api.BeanDesc
public abstract class BeanDesc
Class to hold meta-information related to any enterprise-beans
Field Summary | |
---|---|
protected static int |
BEAN_TRANSACTION_TYPE
Bean transaction type |
protected java.lang.String |
beanIdentification
bean identification string |
protected BeanFactory |
bf
BeanFactory when the bean has been loaded. |
protected int |
cacheMax
Maximum Bean Cache size |
protected java.lang.String |
clusterHomeDistributor
Cluster - velocity template of the CMI class for the Home interface |
protected java.lang.String |
clusterRemoteDistributor
Cluster - velocity template of the CMI class for the Remote interface |
protected boolean |
clusterReplicated
Cluster - true if the bean has to be replicated |
protected static int |
CONTAINER_TRANSACTION_TYPE
Container transaction type |
protected DeploymentDesc |
deploymentDesc
DeploymentDesc parent of this BeanDesc |
protected java.lang.String |
derivedBeanName
Bean classname |
protected java.util.Properties |
ejb10EnvProps
EJB 1.0 Environment as Properties |
protected java.lang.Class |
ejbClass
Bean Class |
protected java.lang.String |
ejbName
name of the Bean |
protected java.lang.String |
ejbTimeoutSignature
|
protected java.lang.String |
fullDerivedBeanName
Bean fully qualified classname |
static java.lang.String |
GENERATED_PREFIX
Package prefix for generated files |
protected java.lang.Class |
home
Home Class |
protected java.lang.String |
jndiLocalName
JNDI local name of the Bean |
protected java.lang.String |
jndiName
JNDI name of the Bean |
protected java.lang.Class |
local
Local Class |
protected java.lang.Class |
localhome
LocalHome Class |
protected org.objectweb.util.monolog.api.Logger |
logger
logger |
protected int |
poolMin
Minimum Bean Pool size |
protected java.lang.Class |
remote
Remote Class |
protected java.util.List |
securityRoleRefDescList
List of SecurityRoleRefDesc for JACC |
protected int |
timerTxAttribute
|
protected static java.lang.String[] |
TRANS
|
Fields inherited from class org.objectweb.jonas_lib.deployment.api.DescriptionGroupDesc |
---|
description, displayName, largeIcon, smallIcon |
Constructor Summary | |
---|---|
BeanDesc(java.lang.ClassLoader classLoader,
CommonEjb ejb,
JonasCommonEjb jonasEjb,
AssemblyDescriptor asd,
JLinkedList jMDRList,
java.lang.String fileName)
Constructor to be used by parent node |
Method Summary | |
---|---|
protected int |
addEJBMethodDesc(int len)
Permit Methods addition from subtypes Protected method that need to be overridden in subclasses |
protected MethodDesc |
addMethodDesc(java.lang.reflect.Method meth,
java.lang.Class classDef)
Add a new method descriptor to the bean |
void |
check()
Check that the bean descriptor is valid |
void |
checkRemoteException(java.lang.reflect.Method m,
boolean shouldThrow)
Check if method throws RemoteException (or not). |
void |
checkRunAsMapping()
Check that the runAs role mapping is correct |
protected abstract void |
checkTxAttribute(MethodDesc md)
Check that trans-attribute is valid for a bean's method. |
void |
checkValidTypesForRmi(java.lang.reflect.Method m)
Check if argument and return types are valid types for RMI-IIOP. |
BeanFactory |
getBeanFactory()
|
int |
getCacheMax()
|
java.lang.String |
getClusterHomeDistributor()
|
java.lang.String |
getClusterRemoteDistributor()
|
DeploymentDesc |
getDeploymentDesc()
|
java.lang.String |
getDerivedBeanName()
|
java.util.Properties |
getEjb10Environment()
Get bean's EJB 1.0 environment properties. |
java.lang.Class |
getEjbClass()
Get bean's class. |
java.lang.String |
getEjbName()
Get the enterprise bean's name. |
java.lang.String |
getEjbTimeoutSignature()
|
java.lang.String |
getFullDerivedBeanName()
|
java.lang.String |
getFullWrpHandleName()
|
java.lang.String |
getFullWrpHomeName()
|
java.lang.String |
getFullWrpLocalHomeName()
|
java.lang.String |
getFullWrpLocalName()
|
java.lang.String |
getFullWrpRemoteName()
|
protected java.lang.String |
getHashCodeForIdentifier()
Gets an hashcode for this bean Return hashcode for jndiname + jndi localname |
java.lang.Class |
getHomeClass()
Get bean's home interface. |
java.lang.String |
getIdentifier()
Build a valid java identifier for the bean. |
java.lang.String |
getJndiLocalName()
Get the name to associate with the enterprise Bean in the JNDI name space for local access (inside the same JOnAS Server) |
java.lang.String |
getJndiName()
Get the name to associate with the enterprise Bean in the JNDI name space. |
java.lang.Class |
getLocalClass()
Get bean's local interface. |
java.lang.Class |
getLocalHomeClass()
Get bean's local home interface. |
MethodDesc |
getMethodDesc(int index)
get a MethodDesc from its index. |
MethodDesc |
getMethodDesc(java.lang.reflect.Method method)
Get descriptor attached to a given method. |
java.util.Iterator |
getMethodDescIterator()
get an iterator for all MethodDesc of the bean. |
protected java.lang.Class |
getParentClass(java.lang.String intfType)
Returns the parent Class for a method given an interface type. |
int |
getPoolMin()
|
java.lang.Class |
getRemoteClass()
Get bean's remote interface. |
java.lang.String |
getRunAsPrincipalName()
|
java.lang.String |
getRunAsRole()
|
org.objectweb.carol.util.csiv2.SasComponent |
getSasComponent()
|
java.util.List |
getSecurityRoleRefDescList()
Gets the security-role-ref of the beans can access to the EJBRoleRefPermission and role-link. |
int |
getTimerTxAttribute()
|
java.lang.String |
getWrpHandleName()
|
java.lang.String |
getWrpHomeName()
|
java.lang.String |
getWrpLocalHomeName()
|
java.lang.String |
getWrpLocalName()
|
java.lang.String |
getWrpRemoteName()
|
boolean |
hasDefinedLocalInterface()
|
boolean |
isClusterReplicated()
|
protected void |
loadExtraClasses(CommonEjb ce,
java.lang.ClassLoader loader)
Permit classes loading from subtypes. |
protected MethodDesc |
newMethodDescInstance(java.lang.reflect.Method meth,
java.lang.Class classDef,
int index)
MethodDesc constructor factory method to ovewrite |
void |
setBeanFactory(BeanFactory factory)
Set the BeanFactory, when the bean is loaded in container. |
void |
setClusterReplicated(boolean replicated)
Set the cluster replicated attribute |
void |
setDeploymentDesc(DeploymentDesc deploymentDesc)
Set the parent deployment descriptor |
void |
setSasComponent(org.objectweb.carol.util.csiv2.SasComponent sasComponent)
|
java.lang.String |
toString()
String representation of the object for test purpose |
protected void |
verifyRoleName(AssemblyDescriptor asd)
Check that there are always corresponding role-name element in security-role and method-permission elements. |
Methods inherited from class org.objectweb.jonas_lib.deployment.api.JndiEnvRefsGroupDesc |
---|
getEjbLocalRefDesc, getEjbRefDesc, getEnvEntryDesc, getMessageDestinationRefDesc, getResourceEnvRefDesc, getResourceRefDesc, getServiceRefDesc |
Methods inherited from class org.objectweb.jonas_lib.deployment.api.DescriptionGroupDesc |
---|
getDescription, getDisplayName, getLargeIcon, getSAXMsg, getSmallIcon |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static final int BEAN_TRANSACTION_TYPE
protected static final int CONTAINER_TRANSACTION_TYPE
protected static final java.lang.String[] TRANS
public static final java.lang.String GENERATED_PREFIX
protected java.lang.String ejbName
protected java.lang.String jndiName
protected java.lang.String jndiLocalName
protected java.lang.Class home
protected java.lang.Class remote
protected java.lang.Class localhome
protected java.lang.Class local
protected java.lang.Class ejbClass
protected java.lang.String beanIdentification
protected java.util.Properties ejb10EnvProps
protected org.objectweb.util.monolog.api.Logger logger
protected java.util.List securityRoleRefDescList
protected DeploymentDesc deploymentDesc
protected java.lang.String fullDerivedBeanName
protected java.lang.String derivedBeanName
protected int poolMin
protected int cacheMax
protected int timerTxAttribute
protected java.lang.String ejbTimeoutSignature
protected BeanFactory bf
protected java.lang.String clusterHomeDistributor
protected java.lang.String clusterRemoteDistributor
protected boolean clusterReplicated
Constructor Detail |
---|
public BeanDesc(java.lang.ClassLoader classLoader, CommonEjb ejb, JonasCommonEjb jonasEjb, AssemblyDescriptor asd, JLinkedList jMDRList, java.lang.String fileName) throws DeploymentDescException
classLoader
- ClassLoader used to load Bean's classesejb
- XML Element from standard Deployment DescriptorjonasEjb
- XML Element from jonas specific Deployment Descriptorasd
- XML Element for the AssemblyDescriptorfileName
- jar filename
DeploymentDescException
- when BeanDesc cannot be instanciated
(class loading problem, ...)Method Detail |
---|
protected void loadExtraClasses(CommonEjb ce, java.lang.ClassLoader loader) throws DeploymentDescException
ce
- XML Element representing EJB Descriptorloader
- ClassLoader used to load classes
DeploymentDescException
- when a class cannot be loadedprotected int addEJBMethodDesc(int len) throws DeploymentDescException
len
- method array length
DeploymentDescException
- when java reflection cannot be used on
classesprotected java.lang.Class getParentClass(java.lang.String intfType) throws DeploymentDescException
intfType
- type of the interface (Home/Remote/LocalHome/Local or
ServiceEndpoint)
DeploymentDescException
- when intfType is unknownprotected java.lang.String getHashCodeForIdentifier()
public java.lang.String getIdentifier()
public void checkRemoteException(java.lang.reflect.Method m, boolean shouldThrow) throws DeploymentDescException
m
- the method to examineshouldThrow
- boolean value indicating if the method should or
shouldn't throw RemoteException
DeploymentDescException
- thrown for non-valid methodpublic void checkValidTypesForRmi(java.lang.reflect.Method m)
m
- the methode to examinepublic void check() throws DeploymentDescException
DeploymentDescException
- thrown for non-valid beanpublic void checkRunAsMapping() throws DeploymentDescException
DeploymentDescException
- if role mapping is incorrectprotected abstract void checkTxAttribute(MethodDesc md) throws DeploymentDescException
md
- MethodDesc to check
DeploymentDescException
- When MethodDesc is not validprotected void verifyRoleName(AssemblyDescriptor asd) throws DeploymentDescException
asd
- the AssemblyDescriptor used to check bean's role names
DeploymentDescException
- When verification failspublic java.lang.String getEjbName()
public java.lang.String getJndiName()
public java.lang.String getJndiLocalName()
public java.lang.Class getHomeClass()
public java.lang.Class getRemoteClass()
public java.lang.Class getLocalHomeClass()
public java.lang.Class getLocalClass()
public java.lang.Class getEjbClass()
public java.util.Properties getEjb10Environment()
public MethodDesc getMethodDesc(java.lang.reflect.Method method)
method
- Method from the Home/Remote/MessageListener interface
public java.util.Iterator getMethodDescIterator()
public MethodDesc getMethodDesc(int index)
index
- MethodDesc index
public java.util.List getSecurityRoleRefDescList()
public int getPoolMin()
public int getCacheMax()
public java.lang.String getRunAsRole()
public int getTimerTxAttribute()
public java.lang.String getEjbTimeoutSignature()
public BeanFactory getBeanFactory()
public void setBeanFactory(BeanFactory factory)
factory
- The bean factorypublic java.lang.String toString()
toString
in interface DescriptionGroup
toString
in class DescriptionGroupDesc
protected MethodDesc newMethodDescInstance(java.lang.reflect.Method meth, java.lang.Class classDef, int index)
meth
- the method to be wrapped into a MethodDesc instanceindex
- index of the method inside the MethodDesc List
protected MethodDesc addMethodDesc(java.lang.reflect.Method meth, java.lang.Class classDef)
meth
- method to add inside MethodDescs list
public java.lang.String getFullWrpRemoteName()
public java.lang.String getFullWrpLocalName()
public java.lang.String getWrpRemoteName()
public java.lang.String getWrpLocalName()
public java.lang.String getFullWrpHandleName()
public java.lang.String getWrpHandleName()
public java.lang.String getFullWrpHomeName()
public java.lang.String getFullWrpLocalHomeName()
public java.lang.String getWrpHomeName()
public java.lang.String getWrpLocalHomeName()
public java.lang.String getFullDerivedBeanName()
public java.lang.String getDerivedBeanName()
public DeploymentDesc getDeploymentDesc()
public void setDeploymentDesc(DeploymentDesc deploymentDesc)
deploymentDesc
- parent DeploymentDescpublic java.lang.String getRunAsPrincipalName()
public boolean hasDefinedLocalInterface()
public org.objectweb.carol.util.csiv2.SasComponent getSasComponent()
public void setSasComponent(org.objectweb.carol.util.csiv2.SasComponent sasComponent)
sasComponent
- The sasComponent to set.public java.lang.String getClusterHomeDistributor()
public java.lang.String getClusterRemoteDistributor()
public boolean isClusterReplicated()
public void setClusterReplicated(boolean replicated)
replicated
- true if the replicated mode is enabled
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |