Class EjbDescriptor
java.lang.Object
java.util.Observable
org.glassfish.deployment.common.DynamicAttributesDescriptor
org.glassfish.deployment.common.Descriptor
com.sun.enterprise.deployment.CommonResourceDescriptor
com.sun.enterprise.deployment.EjbBeanDescriptor
org.glassfish.ejb.deployment.descriptor.EjbDescriptor
- All Implemented Interfaces:
com.sun.enterprise.deployment.EjbDescriptor,com.sun.enterprise.deployment.JndiNameEnvironment,com.sun.enterprise.deployment.NamedDescriptor,com.sun.enterprise.deployment.types.EjbReferenceContainer,com.sun.enterprise.deployment.types.MessageDestinationReferenceContainer,com.sun.enterprise.deployment.types.ResourceEnvReferenceContainer,com.sun.enterprise.deployment.types.ResourceReferenceContainer,com.sun.enterprise.deployment.types.ServiceReferenceContainer,com.sun.enterprise.deployment.WritableJndiNameEnvironment,Serializable
- Direct Known Subclasses:
DummyEjbDescriptor,EjbEntityDescriptor,EjbMessageBeanDescriptor,EjbSessionDescriptor
public abstract class EjbDescriptor
extends com.sun.enterprise.deployment.EjbBeanDescriptor
This abstract class encapsulates the meta-information describing Entity, Session and MessageDriven EJBs.
- Author:
- Danny Coward, Sanjeev Krishnan
- See Also:
-
Field Summary
Fields inherited from interface com.sun.enterprise.deployment.EjbDescriptor
BEAN_TRANSACTION_TYPE, CONTAINER_TRANSACTION_TYPE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAroundInvokeDescriptor(com.sun.enterprise.deployment.LifecycleCallbackDescriptor aroundInvokeDesc) Adds the descriptor if there is no other with the same lifecycle callback class.voidaddAroundTimeoutDescriptor(com.sun.enterprise.deployment.LifecycleCallbackDescriptor aroundTimeoutDesc) voidaddFrameworkInterceptor(com.sun.enterprise.deployment.InterceptorDescriptor interceptor) voidaddNoInterfaceLocalBeanClass(String className) Add a classname for a no-interface view of the local ejbvoidSince ejb-class is optional, in some cases the lifecycle-class for AroundInvoke, PostConstruct, etc.voidapplyInterceptors(InterceptorBindingTranslator bindingTranslator) Derive all interceptors that are applicable to this bean.voidcopyEjbDescriptor(EjbDescriptor other) com.sun.enterprise.deployment.LifecycleCallbackDescriptorgetAroundInvokeDescriptorByClass(String className) final Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor>List<com.sun.enterprise.deployment.EjbInterceptor>getAroundInvokeInterceptors(com.sun.enterprise.deployment.MethodDescriptor businessMethod) com.sun.enterprise.deployment.LifecycleCallbackDescriptorgetAroundTimeoutDescriptorByClass(String className) final Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor>List<com.sun.enterprise.deployment.EjbInterceptor>getAroundTimeoutInterceptors(com.sun.enterprise.deployment.MethodDescriptor businessMethod) List<com.sun.enterprise.deployment.EjbInterceptor>getCallbackInterceptors(com.sun.enterprise.deployment.LifecycleCallbackDescriptor.CallbackType type) abstract StringgetContainerTransactionFor(com.sun.enterprise.deployment.MethodDescriptor methodDescriptor) Fetches the assigned container transaction object for the given method object.final EjbBundleDescriptorImplList<com.sun.enterprise.deployment.InterceptorDescriptor>Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor>final Hashtable<com.sun.enterprise.deployment.MethodDescriptor,ContainerTransaction> Collection<com.sun.enterprise.deployment.MethodDescriptor>protected Collection<com.sun.enterprise.deployment.MethodDescriptor>getTransactionMethods(ClassLoader classLoader) booleanbooleanvoidprint(StringBuffer toStringBuffer) voidsetContainerTransactionFor(com.sun.enterprise.deployment.MethodDescriptor methodDescriptor, ContainerTransaction containerTx) Sets the container transaction for the given method descriptor.voidsetEjbBundleDescriptor(com.sun.enterprise.deployment.EjbBundleDescriptor bundleDescriptor) voidsetEJBLocalObjectImplClassName(String className) voidsetEJBObjectImplClassName(String className) voidsetLocalHomeImplClassName(String className) voidsetMethodContainerTransactions(Hashtable<com.sun.enterprise.deployment.MethodDescriptor, ContainerTransaction> methodContainerTransactions) Sets the container transactions for all the method descriptors of this ejb.voidsetRemoteHomeImplClassName(String className) voidsetSecurityIdentityDescription(String securityIdentityDescription) voidHave default method transaction if isBoundsChecking is on.final voidvisit(org.glassfish.deployment.common.DescriptorVisitor aVisitor) Methods inherited from class com.sun.enterprise.deployment.EjbBeanDescriptor
addAllInterfaceMethodsIn, addEjbReferenceDescriptor, addEntityManagerFactoryReferenceDescriptor, addEntityManagerReferenceDescriptor, addEnvironmentProperty, addInterceptorClass, addIORConfigurationDescriptor, addLocalBusinessClassName, addMessageDestinationReferenceDescriptor, addMethodLevelChain, addPermissionedMethod, addPostConstructDescriptor, addPreDestroyDescriptor, addRemoteBusinessClassName, addResourceDescriptor, addResourceEnvReferenceDescriptor, addResourceReferenceDescriptor, addRoleReference, addScheduledTimerDescriptor, addScheduledTimerDescriptorFromDD, addServiceReferenceDescriptor, allMechanismsRequireSSL, appendToInterceptorChain, copyEjbDescriptor, getAllResourcesDescriptors, getAllResourcesDescriptors, getApplication, getDenyAllMethodPermission, getEjbClassName, getEjbReference, getEjbReferenceDescriptors, getEjbTimeoutMethod, getEntityManagerFactoryReferenceByName, getEntityManagerFactoryReferenceDescriptors, getEntityManagerReferenceByName, getEntityManagerReferenceDescriptors, getEnvironmentProperties, getEnvironmentPropertyByName, getHomeClassName, getInjectableResourcesByClass, getInjectionInfoByClass, getInterceptorChain, getInterceptorClasses, getInterceptorClassNames, getIORConfigurationDescriptors, getJndiName, getLocalBusinessClassNames, getLocalClassName, getLocalHomeClassName, getMappedName, getMessageDestinationReferenceByName, getMessageDestinationReferenceDescriptors, getMethodDescriptors, getMethodInterceptorsMap, getMethodPermissionsFor, getMethodPermissionsFromDD, getName, getPermissionedMethodsByPermission, getPermissionedRoles, getPermitAllMethodDescriptors, getPostConstructDescriptorByClass, getPostConstructDescriptors, getPreDestroyDescriptorByClass, getPreDestroyDescriptors, getRemoteBusinessClassNames, getRemoteClassName, getResourceDescriptors, getResourceEnvReferenceByName, getResourceEnvReferenceDescriptors, getResourceReferenceByName, getResourceReferenceDescriptors, getResourceReferenceDescriptors, getRoleReferenceByName, getRoleReferences, getRunAsIdentity, getScheduledTimerDescriptors, getSecurityBusinessMethodDescriptors, getServiceReferenceByName, getServiceReferenceDescriptors, getStyledPermissionedMethodsByPermission, getTransactionType, getTxBusinessMethodDescriptors, getUniqueId, getUsesCallerIdentity, getWebServiceEndpointInterfaceName, hasInterceptorClass, hasScheduledTimerMethodFromDD, hasWebServiceEndpointInterface, isLocalBean, isLocalBusinessInterfacesSupported, isLocalInterfacesSupported, isRemoteBusinessInterfacesSupported, isRemoteInterfacesSupported, isTimedObject, notifyNewModule, removeEjbReferenceDescriptor, removeEnvironmentProperty, removeMessageDestinationReferenceDescriptor, removePermissionedMethod, removeResourceDescriptor, removeResourceEnvReferenceDescriptor, removeResourceReferenceDescriptor, removeRole, removeRoleReference, removeServiceReferenceDescriptor, setEjbClassName, setEjbTimeoutMethod, setHomeClassName, setInterceptorChain, setInterceptorClasses, setJndiName, setLocalBean, setLocalClassName, setLocalHomeClassName, setMappedName, setMethodInterceptorsMap, setRemoteClassName, setRunAsIdentity, setTransactionType, setUniqueId, setUsesCallerIdentity, setWebServiceEndpointInterfaceNameMethods inherited from class com.sun.enterprise.deployment.CommonResourceDescriptor
getResourceDescriptorMethods inherited from class org.glassfish.deployment.common.Descriptor
addDescriptorExtension, addPrefixMapping, createUniqueFilenameAmongst, createUniqueNameAmongst, createUniqueNameAmongstNamedDescriptors, getDeploymentExtensions, getDescription, getDescriptorExtension, getDescriptorExtensions, getDisplayName, getLargeIconUri, getLocalizedDescription, getLocalizedDescriptions, getLocalizedDisplayName, getLocalizedDisplayNames, getLocalizedLargeIconUri, getLocalizedLargeIconUris, getLocalizedSmallIconUri, getLocalizedSmallIconUris, getPrefixMapping, getSmallIconUri, isBoundsChecking, setBoundsChecking, setDescription, setDisplayName, setLargeIconUri, setLocalizedDescription, setLocalizedDisplayName, setLocalizedLargeIconUri, setLocalizedSmallIconUri, setName, setSmallIconUriMethods inherited from class org.glassfish.deployment.common.DynamicAttributesDescriptor
addExtraAttribute, getExtraAttribute, getExtraAttributes, removeExtraAttribute, toStringMethods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChangedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.sun.enterprise.deployment.EjbDescriptor
getEjbImplClassName, getEjbTypeForDisplay, getType
-
Constructor Details
-
EjbDescriptor
protected EjbDescriptor()Default constructor. -
EjbDescriptor
-
-
Method Details
-
getContainerFactoryQualifier
-
getIASEjbExtraDescriptors
- Returns:
- the extra iAS specific info (not in the RI DID) in the iAS DTD. no setter. You have to modify some fields of the returned object to change it.
-
copyEjbDescriptor
-
getEjbBundleDescriptor
-
setEjbBundleDescriptor
public void setEjbBundleDescriptor(com.sun.enterprise.deployment.EjbBundleDescriptor bundleDescriptor) -
getEJBLocalObjectImplClassName
- Returns:
- the classname of the
EJBLocalObjectimpl.
-
setEJBLocalObjectImplClassName
- Parameters:
className- theEJBLocalObjectimplementation classname of the ejb.
-
getEJBObjectImplClassName
- Returns:
- the classname of the
EJBObjectimpl.
-
setEJBObjectImplClassName
- Parameters:
className-EJBObjectimplementation classname of the ejb.
-
getLocalHomeImplClassName
- Returns:
- the classname of the Local home impl.
-
setLocalHomeImplClassName
- Parameters:
className- the Local home implementation classname of the ejb.
-
getRemoteHomeImplClassName
- Returns:
- the classname of the remote home impl.
-
setRemoteHomeImplClassName
- Parameters:
className- remote home implementation classname of the ejb.
-
getNoInterfaceLocalBeanClasses
- Returns:
- all the public classes of this no-interface local ejb
-
addNoInterfaceLocalBeanClass
Add a classname for a no-interface view of the local ejb- Parameters:
className- fully qualified class name for the interface
-
hasAroundInvokeMethod
public boolean hasAroundInvokeMethod() -
getAroundInvokeDescriptors
public final Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor> getAroundInvokeDescriptors() -
getAroundInvokeDescriptorByClass
public com.sun.enterprise.deployment.LifecycleCallbackDescriptor getAroundInvokeDescriptorByClass(String className) - Parameters:
className-- Returns:
LifecycleCallbackDescriptorwithLifecycleCallbackDescriptor.getLifecycleCallbackClass()of a given
-
getAroundInvokeInterceptors
public List<com.sun.enterprise.deployment.EjbInterceptor> getAroundInvokeInterceptors(com.sun.enterprise.deployment.MethodDescriptor businessMethod) - Parameters:
businessMethod- intercepted method- Returns:
- the ordered list of interceptor info for AroundInvoke behavior of a particular business method. This list *does* include the info on any bean class interceptor. If present, this would always be the last element in the list because of the precedence defined by the spec.
-
addAroundInvokeDescriptor
public void addAroundInvokeDescriptor(com.sun.enterprise.deployment.LifecycleCallbackDescriptor aroundInvokeDesc) Adds the descriptor if there is no other with the same lifecycle callback class.- Parameters:
aroundInvokeDesc-
-
hasAroundTimeoutMethod
public boolean hasAroundTimeoutMethod() -
getAroundTimeoutDescriptors
public final Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor> getAroundTimeoutDescriptors() -
getAroundTimeoutDescriptorByClass
public com.sun.enterprise.deployment.LifecycleCallbackDescriptor getAroundTimeoutDescriptorByClass(String className) -
getAroundTimeoutInterceptors
public List<com.sun.enterprise.deployment.EjbInterceptor> getAroundTimeoutInterceptors(com.sun.enterprise.deployment.MethodDescriptor businessMethod) - Parameters:
businessMethod- intercepted method- Returns:
- the ordered list of interceptor info for AroundTimeout behavior of a particular business method. This list *does* include the info on any bean class interceptor. If present, this would always be the last element in the list because of the precedence defined by the spec.
-
addAroundTimeoutDescriptor
public void addAroundTimeoutDescriptor(com.sun.enterprise.deployment.LifecycleCallbackDescriptor aroundTimeoutDesc) -
getFrameworkInterceptors
-
addFrameworkInterceptor
public void addFrameworkInterceptor(com.sun.enterprise.deployment.InterceptorDescriptor interceptor) -
getSecurityIdentityDescription
- Returns:
- the description field of security-identity
-
setSecurityIdentityDescription
- Parameters:
securityIdentityDescription- the description field of security-identity
-
setUsesDefaultTransaction
public void setUsesDefaultTransaction()Have default method transaction if isBoundsChecking is on. -
applyDefaultClassToLifecycleMethods
public void applyDefaultClassToLifecycleMethods()Since ejb-class is optional, in some cases the lifecycle-class for AroundInvoke, PostConstruct, etc. methods on the bean-class is not known at processing time and must be applied lazily. As such, this method should only be called if the ejb-class has been set on this EjbDescriptor. -
getLifecycleCallbackDescriptors
public Set<com.sun.enterprise.deployment.LifecycleCallbackDescriptor> getLifecycleCallbackDescriptors() -
applyInterceptors
Derive all interceptors that are applicable to this bean. -
getCallbackInterceptors
public List<com.sun.enterprise.deployment.EjbInterceptor> getCallbackInterceptors(com.sun.enterprise.deployment.LifecycleCallbackDescriptor.CallbackType type) - Parameters:
type-LifecycleCallbackDescriptor.CallbackTypeused as a filter- Returns:
- the ordered list of interceptor info for a particular callback event type. This list *does* include the info on any bean class callback. If present, this would always be the last element in the list because of the precedence defined by the spec.
-
getMethodContainerTransactions
public final Hashtable<com.sun.enterprise.deployment.MethodDescriptor,ContainerTransaction> getMethodContainerTransactions()- Returns:
- a copy of the mapping held internally of method descriptors to container transaction objects.
-
setMethodContainerTransactions
public void setMethodContainerTransactions(Hashtable<com.sun.enterprise.deployment.MethodDescriptor, ContainerTransaction> methodContainerTransactions) throws IllegalArgumentExceptionSets the container transactions for all the method descriptors of this ejb. The Hashtable is keyed by method descriptor and the values are the corresponding container transaction objects..- Throws:
IllegalArgumentException- if this ejb has transaction type BEAN_TRANSACTION_TYPE.
-
setContainerTransactionFor
public void setContainerTransactionFor(com.sun.enterprise.deployment.MethodDescriptor methodDescriptor, ContainerTransaction containerTx) throws IllegalArgumentException Sets the container transaction for the given method descriptor.- Throws:
IllegalArgumentException- if this ejb has transaction type BEAN_TRANSACTION_TYPE.
-
getContainerTransactionFor
public ContainerTransaction getContainerTransactionFor(com.sun.enterprise.deployment.MethodDescriptor methodDescriptor) Fetches the assigned container transaction object for the given method object.- Returns:
ContainerTransactionor null.
-
getTransactionMethodDescriptors
- Returns:
- the collection of MethodDescriptors to which ContainerTransactions may be assigned.
-
getTransactionMethods
protected Collection<com.sun.enterprise.deployment.MethodDescriptor> getTransactionMethods(ClassLoader classLoader) - Returns:
- a collection of MethodDescriptor for methods which may have a associated transaction attribute
-
getMethods
- Returns:
- the ejb method objects, i.e. the methods on the home and remote interfaces.
-
print
- Overrides:
printin classcom.sun.enterprise.deployment.EjbBeanDescriptor
-
visit
public final void visit(org.glassfish.deployment.common.DescriptorVisitor aVisitor) - Overrides:
visitin classorg.glassfish.deployment.common.Descriptor
-