org.objectweb.jonas_ejb.deployment.api
Class DeploymentDesc

java.lang.Object
  extended byorg.objectweb.jonas_ejb.deployment.api.DeploymentDesc
Direct Known Subclasses:
DeploymentCmp2Desc, DeploymentDescEjb1_1

public abstract class DeploymentDesc
extends java.lang.Object

Class to hold meta-information related to the deployment of an ejb-jar Contributor(s): Markus Karg: Novell port. Phlippe Durieux: EJB Local References Florent Benoit & Ludovic Bert : Ear

Author:
Christophe Ney [cney@batisseurs.com]

Field Summary
protected  org.objectweb.jonas_ejb.deployment.xml.AssemblyDescriptor asd
           
protected  java.util.HashMap beanDesc
           
protected  java.lang.String displayName
           
protected  java.lang.String[] earRoleNames
          the role names in the EAR case
protected  org.objectweb.util.monolog.api.Logger logger
           
 
Constructor Summary
DeploymentDesc(java.lang.ClassLoader classLoader, org.objectweb.jonas_ejb.deployment.xml.EjbJar ejbJar, org.objectweb.jonas_ejb.deployment.xml.JonasEjbJar jonasEjbJar, org.objectweb.util.monolog.api.Logger l)
          Build the Meta-Information from the XML data binding trees containing the EJB and JOnAS deployment descriptors.
 
Method Summary
 EntityCmp2Desc asn2BeanDesc(java.lang.String asn)
          Get bean descriptor given its abstract schema name
 BeanDesc[] getBeanDesc()
          Get descriptors for all beans contained in jar file
 BeanDesc getBeanDesc(java.lang.String ejbName)
          Get bean descriptor given its name
 java.util.Iterator getBeanDescIterator()
          Get an Iterator on the Bean Desc list
 BeanDesc getBeanDescWithLocalInterface(java.lang.String itfLocalName)
          Get bean descriptor given its interface local name
 java.lang.String getDisplayName()
          Get the display name
 java.lang.String[] getEarRoleNames()
          Get the role names of the deployment desc in the EAR case
 org.objectweb.util.monolog.api.Logger getLogger()
          get the current logger
protected abstract  BeanDesc newEntityBeanDesc(java.lang.ClassLoader cl, org.objectweb.jonas_ejb.deployment.xml.Entity ent, org.objectweb.jonas_ejb.deployment.xml.AssemblyDescriptor asd, org.objectweb.jonas_ejb.deployment.xml.JonasEntity j)
           
 void setEarRoleNames(java.lang.String[] earRoleNames)
          Set the role names of the deployment desc in the EAR case
 void setLogger(org.objectweb.util.monolog.api.Logger logger)
          set the current logger
 java.lang.String toString()
          String representation of the object for test purpose
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

logger

protected org.objectweb.util.monolog.api.Logger logger

earRoleNames

protected java.lang.String[] earRoleNames
the role names in the EAR case


beanDesc

protected java.util.HashMap beanDesc

asd

protected org.objectweb.jonas_ejb.deployment.xml.AssemblyDescriptor asd

displayName

protected java.lang.String displayName
Constructor Detail

DeploymentDesc

public DeploymentDesc(java.lang.ClassLoader classLoader,
                      org.objectweb.jonas_ejb.deployment.xml.EjbJar ejbJar,
                      org.objectweb.jonas_ejb.deployment.xml.JonasEjbJar jonasEjbJar,
                      org.objectweb.util.monolog.api.Logger l)
               throws DeploymentDescException
Build the Meta-Information from the XML data binding trees containing the EJB and JOnAS deployment descriptors.

Parameters:
classLoader - The Class Loader to be used
ejbJar - The EjbJar information, from standard deployment descriptor.
jonasEjbJar - The JonasEjbJar information, from JOnAS specific deployment descriptor.
l - The logger to be used for tracing
Throws:
DeploymentDescException - Cannot deploy bean
Method Detail

getBeanDescIterator

public java.util.Iterator getBeanDescIterator()
Get an Iterator on the Bean Desc list

Returns:
Iterator on BeanDesc

getBeanDesc

public BeanDesc[] getBeanDesc()
Get descriptors for all beans contained in jar file

Returns:
Array of bean's descriptors

getBeanDesc

public BeanDesc getBeanDesc(java.lang.String ejbName)
Get bean descriptor given its name

Parameters:
ejbName - the name of the bean in the Deployment Descriptor

asn2BeanDesc

public EntityCmp2Desc asn2BeanDesc(java.lang.String asn)
Get bean descriptor given its abstract schema name

Parameters:
asn - Abstract Schema Name
Returns:
null if it doesn't exist.

getBeanDescWithLocalInterface

public BeanDesc getBeanDescWithLocalInterface(java.lang.String itfLocalName)
Get bean descriptor given its interface local name

Returns:
null if it doesn't exist.

newEntityBeanDesc

protected abstract BeanDesc newEntityBeanDesc(java.lang.ClassLoader cl,
                                              org.objectweb.jonas_ejb.deployment.xml.Entity ent,
                                              org.objectweb.jonas_ejb.deployment.xml.AssemblyDescriptor asd,
                                              org.objectweb.jonas_ejb.deployment.xml.JonasEntity j)
                                       throws DeploymentDescException
Throws:
DeploymentDescException

getDisplayName

public java.lang.String getDisplayName()
Get the display name

Returns:
the Display name string, from the deployment descriptor.

getEarRoleNames

public java.lang.String[] getEarRoleNames()
Get the role names of the deployment desc in the EAR case

Returns:
an array of role name

setEarRoleNames

public void setEarRoleNames(java.lang.String[] earRoleNames)
Set the role names of the deployment desc in the EAR case

Parameters:
earRoleNames - the role names

getLogger

public org.objectweb.util.monolog.api.Logger getLogger()
get the current logger

Returns:
the Logger

setLogger

public void setLogger(org.objectweb.util.monolog.api.Logger logger)
set the current logger


toString

public java.lang.String toString()
String representation of the object for test purpose

Returns:
String representation of this object