com.sun.enterprise.deployment
Class Application

java.lang.Object
  extended by java.util.Observable
      extended by com.sun.enterprise.deployment.DynamicAttributesDescriptor
          extended by com.sun.enterprise.deployment.Descriptor
              extended by com.sun.enterprise.deployment.RootDeploymentDescriptor
                  extended by com.sun.enterprise.deployment.BundleDescriptor
                      extended by com.sun.enterprise.deployment.Application
All Implemented Interfaces:
JndiNameEnvironment, Roles, EjbReferenceContainer, MessageDestinationReferenceContainer, ResourceEnvReferenceContainer, ResourceReferenceContainer, RoleMappingContainer, ServiceReferenceContainer, WritableJndiNameEnvironment, java.io.Serializable

public class Application
extends BundleDescriptor
implements RoleMappingContainer, WritableJndiNameEnvironment, EjbReferenceContainer, ResourceEnvReferenceContainer, ResourceReferenceContainer, ServiceReferenceContainer, MessageDestinationReferenceContainer

Objects of this type encapsulate the data and behaviour of a J2EE application.

Author:
Danny Coward
See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.sun.enterprise.deployment.RootDeploymentDescriptor
classLoader, extensions, moduleDescriptor, moduleID
 
Fields inherited from class com.sun.enterprise.deployment.Descriptor
DESCRIPTION_CHANGED, DESCRIPTOR_CHANGED, docType, LARGE_ICON_CHANGED, NAME_CHANGED, SMALL_ICON_CHANGED
 
Constructor Summary
Application(org.jvnet.hk2.component.Habitat habitat)
           
 
Method Summary
 void addApplication(Application application)
          Add all the deployment information about the given application to me.
 void addApplicationParam(ApplicationParameter appParam)
          Adds a new context parameter to my list.
 void addAppRole(SecurityRoleDescriptor descriptor)
           
 void addBundleDescriptor(BundleDescriptor bundleDescriptor)
          Add a web bundle descriptor to this application.
 void addDataSourceDefinitionDescriptor(DataSourceDefinitionDescriptor reference)
          Adds the specified data-source-definition to the receiver.
 void addEjbReferenceDescriptor(EjbReference ejbReference)
          Adds a reference to another ejb to me.
 void addEntityManagerFactory(java.lang.String unitName, java.lang.String persistenceRootUri, javax.persistence.EntityManagerFactory emf)
          Set the physical entity manager factory for a persistence unit within this application.
 void addEntityManagerFactoryReferenceDescriptor(EntityManagerFactoryReferenceDescriptor reference)
           
 void addEntityManagerReferenceDescriptor(EntityManagerReferenceDescriptor reference)
           
 void addEnvironmentProperty(EnvironmentProperty environmentProperty)
          Adds the specified environment property to the receiver.
 void addJmsDestinationReferenceDescriptor(JmsDestinationReferenceDescriptor jmsDestReference)
          Adds the specified JMS destination reference to the receiver.
 void addMessageDestinationReferenceDescriptor(MessageDestinationReferenceDescriptor messageDestRef)
          Adds the specified message destination reference to the receiver.
 void addModule(ModuleDescriptor<BundleDescriptor> descriptor)
           
 void addPostConstructDescriptor(LifecycleCallbackDescriptor postConstructDesc)
          Adds the specified post-construct descriptor to the receiver.
 void addPreDestroyDescriptor(LifecycleCallbackDescriptor preDestroyDesc)
          Adds the specified pre-destroy descriptor to the receiver.
 void addResourceAdapter(java.lang.String raName)
          add a resource-adapter to referred resource-adapters list
 void addResourceReferenceDescriptor(ResourceReferenceDescriptor resourceReference)
          Adds a resource reference to me.
 void addRole(Role role)
          Adds a new abstract role
 void addSecurityRoleMapping(SecurityRoleMapping roleMapping)
           
 void addServiceReferenceDescriptor(ServiceReferenceDescriptor serviceRef)
          Adds the specified service reference to the receiver.
 void addWLModule(WLModuleDescriptor wlModule)
          Adds a new context parameter to my list.
 void addWLRoleAssignments(WLSecurityRoleAssignment wlRoleAssignment)
           
 boolean containsCMPEntity()
           
static Application createApplication(org.jvnet.hk2.component.Habitat habitat, java.lang.String name, ModuleDescriptor<BundleDescriptor> newModule)
          Creates a new application to hold a standalone module
 ApplicationClientDescriptor getApplicationClientByName(java.lang.String name)
          Obtain the application client in this application of the given display name.
 ApplicationClientDescriptor getApplicationClientByUri(java.lang.String name)
          Obtain an application client descriptor in this application of the given URI.
 java.util.Set<ApplicationClientDescriptor> getApplicationClientDescriptors()
          Return the Set of app client deploymenbt objects.
 java.util.Set<ApplicationParameter> getApplicationParams()
           
 java.lang.String getAppName()
          Returns the value of the app-name element in the application.xml if it's defined.
 java.util.Set<Role> getAppRoles()
          Return the set of com.sun.enterprise.deployment.Role objects I have (the ones defined in application xml).
 java.util.Set getArchivableDescriptors()
          Return all my subcomponents that have a file format (EJB, WAR and AppCLient JAR).
 java.lang.String getArchiveName()
          Returns the value of the archive-name element in the sun-application.xml When the app-name is not present in application.xml and archive-name is present in sun-application.xml, the value of archive-name minus file extension will be used as the default name of the app-name.
 java.util.Set<BundleDescriptor> getBundleDescriptors()
          Obtain a set of all bundle descriptors, regardless of type
<T extends BundleDescriptor>
java.util.Set<T>
getBundleDescriptors(java.lang.Class<T> type)
          Obtain a full set of bundle descriptors for a particular type
 java.lang.ClassLoader getClassLoader()
           
 EjbCMPEntityDescriptor getCMPDescriptorFor(java.lang.String className)
          Return the EjbCMPEntityDescriptor for a bean for the given classname.
 java.lang.String getCompatibility()
           
 java.util.Set<DataSourceDefinitionDescriptor> getDataSourceDefinitionDescriptors()
          Return a set of data-source-definition descriptors.
 java.lang.String getDefaultSpecVersion()
           
 EjbBundleDescriptor getEjbBundleByName(java.lang.String name)
          Obtain the EJB-JAR in this application of the given name.
 EjbBundleDescriptor getEjbBundleByUri(java.lang.String name)
          Get EJB-JAR of the given URI (filename within EAR)
 java.util.Set<EjbBundleDescriptor> getEjbBundleDescriptors()
          Obtain the full set of all the Ejb JAR deployment information in this application.
 EjbDescriptor getEjbByName(java.lang.String ejbName)
          Obtain the EJB in this application of the given display name.
 int getEjbComponentCount()
          The number of EJB JARs in this application.
 java.util.Vector getEjbDescriptors()
          Return the Vector of ejb deployment objects.
 EjbReference getEjbReference(java.lang.String name)
          Looks up an ejb reference with the given name.
 EjbReference getEjbReferenceByName(java.lang.String name)
          Return a reference to another ejb by the same name or throw an IllegalArgumentException.
 java.util.Set<EjbReference> getEjbReferenceDescriptors()
          Returns the generated XML directory feturn the set of ejb references this ejb declares.
 java.util.Set<javax.persistence.EntityManagerFactory> getEntityManagerFactories()
          Returns the set of physical entity manager factories associated with persistence units in this application.
 javax.persistence.EntityManagerFactory getEntityManagerFactory(java.lang.String unitName, BundleDescriptor declaringModule)
          Retrieve the physical entity manager factory associated with the unitName of an application-level persistence unit.
 EntityManagerFactoryReferenceDescriptor getEntityManagerFactoryReferenceByName(java.lang.String name)
          Return the entity manager factory reference descriptor corresponding to the given name.
 java.util.Set<EntityManagerFactoryReferenceDescriptor> getEntityManagerFactoryReferenceDescriptors()
          Return a set of entity manager factory reference descriptors.
 EntityManagerReferenceDescriptor getEntityManagerReferenceByName(java.lang.String name)
          Return the entity manager factory reference descriptor corresponding to the given name.
 java.util.Set<EntityManagerReferenceDescriptor> getEntityManagerReferenceDescriptors()
          Return a set of entity manager reference descriptors.
 java.util.Set<EnvironmentProperty> getEnvironmentProperties()
          Return a copy of the structure holding the environment properties.
 EnvironmentProperty getEnvironmentPropertyByName(java.lang.String name)
          Returns the environment property object searching on the supplied key.
 java.lang.String getGeneratedXMLDirectory()
           
 java.util.List<InjectionCapable> getInjectableResourcesByClass(java.lang.String className)
           
 InjectionInfo getInjectionInfoByClass(java.lang.Class clazz)
           
 JmsDestinationReferenceDescriptor getJmsDestinationReferenceByName(java.lang.String name)
          Return a reference to another ejb by the same name or throw an IllegalArgumentException.
 java.util.Set<JmsDestinationReferenceDescriptor> getJmsDestinationReferenceDescriptors()
          Return the set of JMS destination references this ejb declares.
 java.util.Set<JndiNameEnvironment> getJndiNameEnvironments()
          Obtain the full set of all the subcomponents of this application that use a JNDI name environment..
 boolean getKeepState()
           
 boolean getKeepStateResolved()
          Returns the resolved keepstate value.
 java.lang.String getLibraryDirectory()
          Returns an "intelligent" value for the library directory setting, meaning the current value if it has been set to a non-null, non-empty value; the default value if the value has never been set, and null if the value has been set to empty.
 java.lang.String getLibraryDirectoryRawValue()
           
 MessageDestinationReferenceDescriptor getMessageDestinationReferenceByName(java.lang.String name)
          Looks up an message destination reference with the given name.
 java.util.Set<MessageDestinationReferenceDescriptor> getMessageDestinationReferenceDescriptors()
          Return a set of message destination reference descriptors.
<T extends BundleDescriptor>
T
getModuleByTypeAndUri(java.lang.Class<T> type, java.lang.String uri)
           
 BundleDescriptor getModuleByUri(java.lang.String uri)
          Lookup module by uri.
 ModuleDescriptor<BundleDescriptor> getModuleDescriptorByUri(java.lang.String uri)
          Lookup module by uri.
 java.util.Collection<ModuleDescriptor<BundleDescriptor>> getModuleDescriptorsByType(XModuleType type)
          Lookup module by uri.
 java.lang.String getModuleID()
           
 java.util.Set<ModuleDescriptor<BundleDescriptor>> getModules()
          Obtain a full set of module descriptors
 XModuleType getModuleType()
           
 boolean getPassByReference()
          Gets the value of pass-by-reference property for this application Checks to see if the pass-by-reference property is defined.
 LifecycleCallbackDescriptor getPostConstructDescriptorByClass(java.lang.String className)
          Return the post-construct descriptor corresponding to the given name.
 java.util.Set<LifecycleCallbackDescriptor> getPostConstructDescriptors()
          Return a set of post-construct descriptors.
 LifecycleCallbackDescriptor getPreDestroyDescriptorByClass(java.lang.String className)
          Return the pre-destroy descriptor corresponding to the given name.
 java.util.Set<LifecycleCallbackDescriptor> getPreDestroyDescriptors()
          Return a set of pre-destroy descriptors.
 int getRarComponentCount()
           
 ConnectorDescriptor getRarDescriptorByUri(java.lang.String name)
          Obtain the RAR in this application of the given URI.
 java.util.Set<ConnectorDescriptor> getRarDescriptors()
          Obtain the full set of all the Ejb JAR deployment information in this application.
 java.lang.String getRealm()
           
 java.lang.String getRegistrationName()
          Returns the registration name of this application.
 BundleDescriptor getRelativeBundle(BundleDescriptor origin, java.lang.String relativeTargetUri)
          Get a target bundle descriptor based on an input bundle descriptor and a relative uri from the perspective of the input bundle descriptor.
 java.lang.String getRelativeUri(BundleDescriptor origin, BundleDescriptor target)
          Return the relative uri between two modules, from the perspective of the first bundle.
 java.util.Set<java.lang.String> getResourceAdapters()
          get the list of resource-adapters referred by the application
 java.util.List<Resource> getResourceList()
           
 ResourceReferenceDescriptor getResourceReferenceByName(java.lang.String name)
          Return the resource object corresponding to the supplied name or throw an illegal argument exception.
 java.util.Set<ResourceReferenceDescriptor> getResourceReferenceDescriptors()
          Return the set of resource references this ejb declares.
 SecurityRoleMapper getRoleMapper()
          Return my mapping of rolename to users and groups on a particular server.
 java.util.Set<Role> getRoles()
          Return the set of roles used in this application.
 java.util.List<SecurityRoleMapping> getSecurityRoleMappings()
           
 ServiceReferenceDescriptor getServiceReferenceByName(java.lang.String name)
          Looks up an service reference with the given name.
 java.util.Set<ServiceReferenceDescriptor> getServiceReferenceDescriptors()
          Return a set of service reference descriptors.
 EjbDescriptor[] getSortedEjbDescriptors()
          Returns all the ejb descriptor in this application in ordered form.
 BundleDescriptor getStandaloneBundleDescriptor()
          if this application object is virtual, return the standalone bundle descriptor it is wrapping otherwise return null
 java.lang.String getTargetUri(BundleDescriptor origin, java.lang.String relativeTargetUri)
          Get the uri of a target based on a source module and a a relative uri from the perspective of that source module.
 long getUniqueId()
          Returns the unique id used for this application.
 WebBundleDescriptor getWebBundleDescriptorByName(java.lang.String name)
          Obtain the WAR in this application of the given display name.
 WebBundleDescriptor getWebBundleDescriptorByUri(java.lang.String name)
          Get WAR of a given URI (filename within EAR)
 java.util.Set<WebBundleDescriptor> getWebBundleDescriptors()
          Obtain the full set of all the WARs in this application.
 int getWebComponentCount()
          The number of Web Components in this application.
 java.util.Set<WebService> getWebServiceDescriptors()
          Return a set of all com.sun.enterprise.deployment.WebService descriptors in the application.
 java.util.Set<WLModuleDescriptor> getWLModules()
           
 java.util.List<WLSecurityRoleAssignment> getWlRoleAssignments()
           
 boolean hasEjbByName(java.lang.String ejbName)
          Return whether the application contains the given ejb by name..
 boolean hasRuntimeInformation()
          Return true if I have information to do with deployment on a particular operational environment.
 boolean isApplication()
           
 boolean isDirty()
          A flag to indicate that my data has changed since the last save.
 boolean isEmpty()
          Return true if this root deployment descriptor does not describe anything
 boolean isInitializeInOrder()
           
 boolean isLoadedFromApplicationXml()
           
 boolean isPassByReferenceDefined()
           
 boolean isUniqueIdSet()
           
 boolean isVirtual()
          Returns the virtual status of this application.
 void print(java.lang.StringBuffer toStringBuffer)
          A formatted String representing my state.
 void removeBundleDescriptor(BundleDescriptor bundleDescriptor)
          Remove a web bundle descriptor from this application.
 void removeDataSourceDefinitionDescriptor(DataSourceDefinitionDescriptor reference)
          Removes the specified data-source-definition from the receiver.
 void removeEjbReferenceDescriptor(EjbReference ejbReference)
          Removes the specificed ejb reference from the receiver.
 void removeEnvironmentProperty(EnvironmentProperty environmentProperty)
          Removes the given environment property from me.
 void removeJmsDestinationReferenceDescriptor(JmsDestinationReferenceDescriptor jmsDestReference)
          Removes the specified JMS destination reference from the receiver.
 void removeMessageDestinationReferenceDescriptor(MessageDestinationReferenceDescriptor msgDestRef)
          Removes the specified message destination reference from the receiver.
 void removeModule(ModuleDescriptor<BundleDescriptor> descriptor)
           
 void removeResourceReferenceDescriptor(ResourceReferenceDescriptor resourceReference)
          Removes the given resource reference from me.
 void removeRole(Role role)
          Removes the given role.
 void removeServiceReferenceDescriptor(ServiceReferenceDescriptor serviceRef)
          Removes the specified service reference from the receiver.
 void setAppName(java.lang.String appName)
          Sets the EE app name
 void setArchiveName(java.lang.String archiveName)
          Sets the archive name using the archive-name element defined in sun-application.xml
 void setCompatibility(java.lang.String compatValue)
           
 void setGeneratedXMLDirectory(java.lang.String xmlDir)
           
 void setInitializeInOrder(boolean initializeInOrder)
          Sets the initializeInOrder flag
 void setKeepStateResolved(java.lang.String keepStateResolved)
          Sets the resolved keepstate value.
 void setLibraryDirectory(java.lang.String value)
           
 void setLoadedFromApplicationXml(boolean bool)
          This method records how this Application object is constructed.
 void setName(java.lang.String name)
          Reset the display name of this application.
 void setPassByReference(boolean passByReference)
          Sets the pass-by-reference property for this application.
 void setRealm(java.lang.String realm)
          Sets the realm for this application
 void setRegistrationName(java.lang.String appId)
          Sets the registration name for this application.
 void setResourceList(java.util.List<Resource> rList)
           
 void setRoleMapper(SecurityRoleMapper roleMapper)
          Sets the mapping of rolename to users and groups on a particular server.
 void setUniqueId(long id)
          Sets the unique id for this application.
 void setVirtual(boolean virtual)
          Sets the virtual status of this application.
 void visit(ApplicationVisitor aVisitor)
          visit the descriptor and all sub descriptors with a DOL visitor implementation
 void visit(DescriptorVisitor aVisitor)
          visit the descriptor and all sub descriptors with a DOL visitor implementation
 
Methods inherited from class com.sun.enterprise.deployment.BundleDescriptor
addEntityManagerFactory, addManagedBean, addMessageDestination, addRole, findDefaultPU, findReferencedPU, findReferencedPUs, findReferencedPUsViaPCRefs, findReferencedPUsViaPURefs, findReferencedPUViaEMFRef, findReferencedPUViaEMRef, getApplication, getDeploymentDescriptorDir, getEntityManagerFactory, getInjectableResources, getInjectableResourcesByClass, getInjectionInfoByClass, getManagedBeanByBeanClass, getManagedBeans, getMessageDestinationByName, getMessageDestinations, getModuleName, getNamedDescriptorsFrom, getNamedReferencePairsFrom, getPostConstructDescriptorByClass, getPreDestroyDescriptorByClass, getUniqueFriendlyId, getVisiblePUs, getWebServiceEndpointByName, getWebServices, getWsdlDir, hasManagedBeanByBeanClass, hasMessageDestinationByName, hasWebServiceClients, hasWebServices, isPackagedAsSingleModule, isPolicyModified, isStandalone, removeMessageDestination, setApplication, setKeepState, setPolicyModified
 
Methods inherited from class com.sun.enterprise.deployment.RootDeploymentDescriptor
addExtensionDescriptor, getDisplayName, getExtensionsDescriptors, getExtensionsDescriptors, getExtensionsDescriptors, getMainDescriptor, getModuleDescriptor, getName, getSchemaLocation, getSpecVersion, isDDWithNoAnnotationAllowed, isExtensionDescriptor, isFullAttribute, isFullFlag, setClassLoader, setDisplayName, setFullAttribute, setFullFlag, setModuleDescriptor, setModuleID, setSchemaLocation, setSpecVersion
 
Methods inherited from class com.sun.enterprise.deployment.Descriptor
addDeploymentExtension, addPrefixMapping, createUniqueFilenameAmongst, createUniqueNameAmongst, createUniqueNameAmongstNamedDescriptors, fillDocType, getDeploymentExtensions, getDescription, getDocType, getLargeIconUri, getLocalizedDescription, getLocalizedDescriptions, getLocalizedDisplayName, getLocalizedDisplayNames, getLocalizedLargeIconUri, getLocalizedLargeIconUris, getLocalizedSmallIconUri, getLocalizedSmallIconUris, getPrefixMapping, getSmallIconUri, isBoundsChecking, setBoundsChecking, setDescription, setLargeIconUri, setLocalizedDescription, setLocalizedDisplayName, setLocalizedLargeIconUri, setLocalizedSmallIconUri, setSmallIconUri
 
Methods inherited from class com.sun.enterprise.deployment.DynamicAttributesDescriptor
addExtraAttribute, getExtraAttribute, getExtraAttributes, removeExtraAttribute, toString
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Application

public Application(org.jvnet.hk2.component.Habitat habitat)
Method Detail

getDefaultSpecVersion

public java.lang.String getDefaultSpecVersion()
Specified by:
getDefaultSpecVersion in class RootDeploymentDescriptor
Returns:
the default version of the deployment descriptor loaded by this descriptor

isEmpty

public boolean isEmpty()
Description copied from class: RootDeploymentDescriptor
Return true if this root deployment descriptor does not describe anything

Specified by:
isEmpty in class RootDeploymentDescriptor
Returns:
true if this root descriptor is empty

createApplication

public static Application createApplication(org.jvnet.hk2.component.Habitat habitat,
                                            java.lang.String name,
                                            ModuleDescriptor<BundleDescriptor> newModule)
Creates a new application to hold a standalone module

Parameters:
name - the application name
newModule - the standalone module descriptor
Returns:
the application

getEjbReferenceDescriptors

public java.util.Set<EjbReference> getEjbReferenceDescriptors()
Returns the generated XML directory feturn the set of ejb references this ejb declares.

Specified by:
getEjbReferenceDescriptors in interface JndiNameEnvironment
Specified by:
getEjbReferenceDescriptors in interface EjbReferenceContainer
Returns:
java.util.Set of EjbReferenceDescriptor objects

addEjbReferenceDescriptor

public void addEjbReferenceDescriptor(EjbReference ejbReference)
Adds a reference to another ejb to me.

Specified by:
addEjbReferenceDescriptor in interface EjbReferenceContainer
Specified by:
addEjbReferenceDescriptor in interface WritableJndiNameEnvironment
Parameters:
ejbReference - the EjbReferenceDescriptor to add.

removeEjbReferenceDescriptor

public void removeEjbReferenceDescriptor(EjbReference ejbReference)
Description copied from interface: WritableJndiNameEnvironment
Removes the specificed ejb reference from the receiver.

Specified by:
removeEjbReferenceDescriptor in interface WritableJndiNameEnvironment
Parameters:
ejbReference - the EjbReferenceDescriptor to remove.

getEjbReferenceByName

public EjbReference getEjbReferenceByName(java.lang.String name)
Return a reference to another ejb by the same name or throw an IllegalArgumentException.


getEjbReference

public EjbReference getEjbReference(java.lang.String name)
Description copied from interface: EjbReferenceContainer
Looks up an ejb reference with the given name. Throws an IllegalArgumentException if it is not found.

Specified by:
getEjbReference in interface EjbReferenceContainer

getServiceReferenceDescriptors

public java.util.Set<ServiceReferenceDescriptor> getServiceReferenceDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of service reference descriptors.

Specified by:
getServiceReferenceDescriptors in interface JndiNameEnvironment
Specified by:
getServiceReferenceDescriptors in interface ServiceReferenceContainer
Specified by:
getServiceReferenceDescriptors in class BundleDescriptor
Returns:
a set of service-ref from this bundle or an empty set if none

addServiceReferenceDescriptor

public void addServiceReferenceDescriptor(ServiceReferenceDescriptor serviceRef)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified service reference to the receiver.

Specified by:
addServiceReferenceDescriptor in interface ServiceReferenceContainer
Specified by:
addServiceReferenceDescriptor in interface WritableJndiNameEnvironment

removeServiceReferenceDescriptor

public void removeServiceReferenceDescriptor(ServiceReferenceDescriptor serviceRef)
Description copied from interface: WritableJndiNameEnvironment
Removes the specified service reference from the receiver.

Specified by:
removeServiceReferenceDescriptor in interface ServiceReferenceContainer
Specified by:
removeServiceReferenceDescriptor in interface WritableJndiNameEnvironment

getServiceReferenceByName

public ServiceReferenceDescriptor getServiceReferenceByName(java.lang.String name)
Looks up an service reference with the given name. Throws an IllegalArgumentException if it is not found.

Specified by:
getServiceReferenceByName in interface JndiNameEnvironment
Specified by:
getServiceReferenceByName in interface ServiceReferenceContainer
Returns:
ServiceReferenceDescriptor object

getMessageDestinationReferenceDescriptors

public java.util.Set<MessageDestinationReferenceDescriptor> getMessageDestinationReferenceDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of message destination reference descriptors.

Specified by:
getMessageDestinationReferenceDescriptors in interface JndiNameEnvironment
Specified by:
getMessageDestinationReferenceDescriptors in interface MessageDestinationReferenceContainer
Returns:
java.util.Set of MessageDestinationReferenceDescriptor objects

addMessageDestinationReferenceDescriptor

public void addMessageDestinationReferenceDescriptor(MessageDestinationReferenceDescriptor messageDestRef)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified message destination reference to the receiver.

Specified by:
addMessageDestinationReferenceDescriptor in interface MessageDestinationReferenceContainer
Specified by:
addMessageDestinationReferenceDescriptor in interface WritableJndiNameEnvironment

removeMessageDestinationReferenceDescriptor

public void removeMessageDestinationReferenceDescriptor(MessageDestinationReferenceDescriptor msgDestRef)
Description copied from interface: WritableJndiNameEnvironment
Removes the specified message destination reference from the receiver.

Specified by:
removeMessageDestinationReferenceDescriptor in interface MessageDestinationReferenceContainer
Specified by:
removeMessageDestinationReferenceDescriptor in interface WritableJndiNameEnvironment

getMessageDestinationReferenceByName

public MessageDestinationReferenceDescriptor getMessageDestinationReferenceByName(java.lang.String name)
Looks up an message destination reference with the given name. Throws an IllegalArgumentException if it is not found.

Specified by:
getMessageDestinationReferenceByName in interface JndiNameEnvironment
Specified by:
getMessageDestinationReferenceByName in interface MessageDestinationReferenceContainer
Returns:
MessageDestinationReferenceDescriptor object

getJmsDestinationReferenceDescriptors

public java.util.Set<JmsDestinationReferenceDescriptor> getJmsDestinationReferenceDescriptors()
Return the set of JMS destination references this ejb declares.

Specified by:
getJmsDestinationReferenceDescriptors in interface JndiNameEnvironment
Specified by:
getJmsDestinationReferenceDescriptors in interface ResourceEnvReferenceContainer
Returns:
java.util.Set of JmsDestinationReferenceDescriptor objects

addJmsDestinationReferenceDescriptor

public void addJmsDestinationReferenceDescriptor(JmsDestinationReferenceDescriptor jmsDestReference)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified JMS destination reference to the receiver.

Specified by:
addJmsDestinationReferenceDescriptor in interface ResourceEnvReferenceContainer
Specified by:
addJmsDestinationReferenceDescriptor in interface WritableJndiNameEnvironment

removeJmsDestinationReferenceDescriptor

public void removeJmsDestinationReferenceDescriptor(JmsDestinationReferenceDescriptor jmsDestReference)
Description copied from interface: WritableJndiNameEnvironment
Removes the specified JMS destination reference from the receiver.

Specified by:
removeJmsDestinationReferenceDescriptor in interface WritableJndiNameEnvironment

getJmsDestinationReferenceByName

public JmsDestinationReferenceDescriptor getJmsDestinationReferenceByName(java.lang.String name)
Return a reference to another ejb by the same name or throw an IllegalArgumentException.

Specified by:
getJmsDestinationReferenceByName in interface JndiNameEnvironment
Specified by:
getJmsDestinationReferenceByName in interface ResourceEnvReferenceContainer
Returns:
JmsDestinationReferenceDescriptor object

getResourceReferenceDescriptors

public java.util.Set<ResourceReferenceDescriptor> getResourceReferenceDescriptors()
Return the set of resource references this ejb declares.

Specified by:
getResourceReferenceDescriptors in interface JndiNameEnvironment
Specified by:
getResourceReferenceDescriptors in interface ResourceReferenceContainer
Returns:
java.util.Set of ResourceReferenceDescriptor objects

addResourceReferenceDescriptor

public void addResourceReferenceDescriptor(ResourceReferenceDescriptor resourceReference)
Adds a resource reference to me.

Specified by:
addResourceReferenceDescriptor in interface ResourceReferenceContainer
Specified by:
addResourceReferenceDescriptor in interface WritableJndiNameEnvironment
Parameters:
resourceReference - the ResourceReferenceDescriptor to add.

removeResourceReferenceDescriptor

public void removeResourceReferenceDescriptor(ResourceReferenceDescriptor resourceReference)
Removes the given resource reference from me.

Specified by:
removeResourceReferenceDescriptor in interface WritableJndiNameEnvironment
Parameters:
resourceReference - the ResourceReferenceDescriptor to remove.

getResourceReferenceByName

public ResourceReferenceDescriptor getResourceReferenceByName(java.lang.String name)
Return the resource object corresponding to the supplied name or throw an illegal argument exception.

Specified by:
getResourceReferenceByName in interface ResourceReferenceContainer

getEnvironmentPropertyByName

public EnvironmentProperty getEnvironmentPropertyByName(java.lang.String name)
Returns the environment property object searching on the supplied key. throws an illegal argument exception if no such environment property exists.

Specified by:
getEnvironmentPropertyByName in interface JndiNameEnvironment
Returns:
EnvironmentProperty descriptor

getEnvironmentProperties

public java.util.Set<EnvironmentProperty> getEnvironmentProperties()
Return a copy of the structure holding the environment properties.

Specified by:
getEnvironmentProperties in interface JndiNameEnvironment
Returns:
java.util.Set of EnvironmentProperty objects

addEnvironmentProperty

public void addEnvironmentProperty(EnvironmentProperty environmentProperty)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified environment property to the receiver.

Specified by:
addEnvironmentProperty in interface WritableJndiNameEnvironment
Parameters:
environmentProperty - the EnvironmentProperty to add.

removeEnvironmentProperty

public void removeEnvironmentProperty(EnvironmentProperty environmentProperty)
Removes the given environment property from me.

Specified by:
removeEnvironmentProperty in interface WritableJndiNameEnvironment
Parameters:
environmentProperty - the EnvironmentProperty to remove.

getEntityManagerFactoryReferenceDescriptors

public java.util.Set<EntityManagerFactoryReferenceDescriptor> getEntityManagerFactoryReferenceDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of entity manager factory reference descriptors.

Specified by:
getEntityManagerFactoryReferenceDescriptors in interface JndiNameEnvironment

getEntityManagerFactoryReferenceByName

public EntityManagerFactoryReferenceDescriptor getEntityManagerFactoryReferenceByName(java.lang.String name)
Return the entity manager factory reference descriptor corresponding to the given name.

Specified by:
getEntityManagerFactoryReferenceByName in interface JndiNameEnvironment

addEntityManagerFactoryReferenceDescriptor

public void addEntityManagerFactoryReferenceDescriptor(EntityManagerFactoryReferenceDescriptor reference)
Specified by:
addEntityManagerFactoryReferenceDescriptor in interface WritableJndiNameEnvironment

getEntityManagerReferenceDescriptors

public java.util.Set<EntityManagerReferenceDescriptor> getEntityManagerReferenceDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of entity manager reference descriptors.

Specified by:
getEntityManagerReferenceDescriptors in interface JndiNameEnvironment

getEntityManagerReferenceByName

public EntityManagerReferenceDescriptor getEntityManagerReferenceByName(java.lang.String name)
Return the entity manager factory reference descriptor corresponding to the given name.

Specified by:
getEntityManagerReferenceByName in interface JndiNameEnvironment

addEntityManagerReferenceDescriptor

public void addEntityManagerReferenceDescriptor(EntityManagerReferenceDescriptor reference)
Specified by:
addEntityManagerReferenceDescriptor in interface WritableJndiNameEnvironment

getDataSourceDefinitionDescriptors

public java.util.Set<DataSourceDefinitionDescriptor> getDataSourceDefinitionDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of data-source-definition descriptors.

Specified by:
getDataSourceDefinitionDescriptors in interface JndiNameEnvironment
Returns:
java.util.Set of data-source-definition objects

addDataSourceDefinitionDescriptor

public void addDataSourceDefinitionDescriptor(DataSourceDefinitionDescriptor reference)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified data-source-definition to the receiver.

Specified by:
addDataSourceDefinitionDescriptor in interface WritableJndiNameEnvironment
Parameters:
reference - DataSourceDefinitionDescriptor to add.

removeDataSourceDefinitionDescriptor

public void removeDataSourceDefinitionDescriptor(DataSourceDefinitionDescriptor reference)
Description copied from interface: WritableJndiNameEnvironment
Removes the specified data-source-definition from the receiver.

Specified by:
removeDataSourceDefinitionDescriptor in interface WritableJndiNameEnvironment
Parameters:
reference - DataSourceDefinitionDescriptor to remove.

getPostConstructDescriptors

public java.util.Set<LifecycleCallbackDescriptor> getPostConstructDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of post-construct descriptors.

Specified by:
getPostConstructDescriptors in interface JndiNameEnvironment
Returns:
java.util.Set of LifecycleCallbackDescriptor post-construct objects

addPostConstructDescriptor

public void addPostConstructDescriptor(LifecycleCallbackDescriptor postConstructDesc)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified post-construct descriptor to the receiver.

Specified by:
addPostConstructDescriptor in interface WritableJndiNameEnvironment

getPostConstructDescriptorByClass

public LifecycleCallbackDescriptor getPostConstructDescriptorByClass(java.lang.String className)
Description copied from interface: JndiNameEnvironment
Return the post-construct descriptor corresponding to the given name.

Specified by:
getPostConstructDescriptorByClass in interface JndiNameEnvironment
Returns:
LifecycleCallbackDescriptor post-construct object

getPreDestroyDescriptors

public java.util.Set<LifecycleCallbackDescriptor> getPreDestroyDescriptors()
Description copied from interface: JndiNameEnvironment
Return a set of pre-destroy descriptors.

Specified by:
getPreDestroyDescriptors in interface JndiNameEnvironment
Returns:
java.util.Set of LifecycleCallbackDescriptor pre-destroy objects

addPreDestroyDescriptor

public void addPreDestroyDescriptor(LifecycleCallbackDescriptor preDestroyDesc)
Description copied from interface: WritableJndiNameEnvironment
Adds the specified pre-destroy descriptor to the receiver.

Specified by:
addPreDestroyDescriptor in interface WritableJndiNameEnvironment

getPreDestroyDescriptorByClass

public LifecycleCallbackDescriptor getPreDestroyDescriptorByClass(java.lang.String className)
Description copied from interface: JndiNameEnvironment
Return the pre-destroy descriptor corresponding to the given name.

Specified by:
getPreDestroyDescriptorByClass in interface JndiNameEnvironment
Returns:
LifecycleCallbackDescriptor pre-destroy object

getInjectableResourcesByClass

public java.util.List<InjectionCapable> getInjectableResourcesByClass(java.lang.String className)
Specified by:
getInjectableResourcesByClass in interface JndiNameEnvironment

getInjectionInfoByClass

public InjectionInfo getInjectionInfoByClass(java.lang.Class clazz)
Specified by:
getInjectionInfoByClass in interface JndiNameEnvironment

setGeneratedXMLDirectory

public void setGeneratedXMLDirectory(java.lang.String xmlDir)

getGeneratedXMLDirectory

public java.lang.String getGeneratedXMLDirectory()

setRegistrationName

public void setRegistrationName(java.lang.String appId)
Sets the registration name for this application. This name is used while deploying the application. The deployment process gurantees that this name is unique.

Parameters:
appId - the registration name used for this application

getRegistrationName

public java.lang.String getRegistrationName()
Returns the registration name of this application.

Returns:
the registration name of this application

getAppName

public java.lang.String getAppName()
Returns the value of the app-name element in the application.xml if it's defined. The default EE app name is the unqualified name of the .ear or stand-alone module, minus the file extension.

Returns:
the EE app name of this application

setAppName

public void setAppName(java.lang.String appName)
Sets the EE app name

Parameters:
appName - the EE app name of this application

getArchiveName

public java.lang.String getArchiveName()
Returns the value of the archive-name element in the sun-application.xml When the app-name is not present in application.xml and archive-name is present in sun-application.xml, the value of archive-name minus file extension will be used as the default name of the app-name.

Returns:
the EE app name of this application

setArchiveName

public void setArchiveName(java.lang.String archiveName)
Sets the archive name using the archive-name element defined in sun-application.xml

Parameters:
archiveName - archiveName to calculate default EE6 app-name

getCompatibility

public java.lang.String getCompatibility()
Overrides:
getCompatibility in class BundleDescriptor

setCompatibility

public void setCompatibility(java.lang.String compatValue)
Overrides:
setCompatibility in class BundleDescriptor

isInitializeInOrder

public boolean isInitializeInOrder()
Returns:
the initializeInOrder flag when the return value is true, the modules inside ear will be loaded by their declaration order in application.xml

setInitializeInOrder

public void setInitializeInOrder(boolean initializeInOrder)
Sets the initializeInOrder flag

Parameters:
initializeInOrder -

addEntityManagerFactory

public void addEntityManagerFactory(java.lang.String unitName,
                                    java.lang.String persistenceRootUri,
                                    javax.persistence.EntityManagerFactory emf)
Set the physical entity manager factory for a persistence unit within this application. This method takes a parameter called persistenceRootUri to support for fully-qualified persistence-unit-name syntax within persistence-unit-refs and persistence-context-refs. The syntax is similar to ejb-link and messge-destination-link. See (EJB 3 core spec: 15.10.2)

Parameters:
unitName: - Name of the persistence-unit
persistenceRootUri: - uri of the root of the persistence.xml (excluding META-INF) in which the persistence unit was defined. This uri is relative to the top of the .ear.
emf: - an entity manager factory.

getEntityManagerFactory

public javax.persistence.EntityManagerFactory getEntityManagerFactory(java.lang.String unitName,
                                                                      BundleDescriptor declaringModule)
Retrieve the physical entity manager factory associated with the unitName of an application-level persistence unit. Returns null if no matching entry is found.


getEntityManagerFactories

public java.util.Set<javax.persistence.EntityManagerFactory> getEntityManagerFactories()
Returns the set of physical entity manager factories associated with persistence units in this application.

Overrides:
getEntityManagerFactories in class BundleDescriptor

getRoles

public java.util.Set<Role> getRoles()
Return the set of roles used in this application. Currently, for release 1.0, it is an * aggregation of all the roles in the sub-modules of the application.

Specified by:
getRoles in interface Roles
Overrides:
getRoles in class BundleDescriptor
Returns:
the Set of roles in the application.

getAppRoles

public java.util.Set<Role> getAppRoles()
Return the set of com.sun.enterprise.deployment.Role objects I have (the ones defined in application xml).


addAppRole

public void addAppRole(SecurityRoleDescriptor descriptor)

addRole

public void addRole(Role role)
Adds a new abstract role

Specified by:
addRole in interface Roles
Overrides:
addRole in class BundleDescriptor

removeRole

public void removeRole(Role role)
Removes the given role.

Specified by:
removeRole in interface Roles
Overrides:
removeRole in class BundleDescriptor

setName

public void setName(java.lang.String name)
Reset the display name of this application.

Overrides:
setName in class RootDeploymentDescriptor
Parameters:
name - the display name of the application.

setLibraryDirectory

public void setLibraryDirectory(java.lang.String value)

getLibraryDirectory

public java.lang.String getLibraryDirectory()
Returns an "intelligent" value for the library directory setting, meaning the current value if it has been set to a non-null, non-empty value; the default value if the value has never been set, and null if the value has been set to empty.

Returns:
String value of the library directory setting

getLibraryDirectoryRawValue

public java.lang.String getLibraryDirectoryRawValue()

getWebComponentCount

public int getWebComponentCount()
The number of Web Components in this application. Current implementation only return the number of servlets inside the application, and not the JSPs since we cannot get that information from deployment descriptors.

Returns:
the number of Web Components

removeModule

public void removeModule(ModuleDescriptor<BundleDescriptor> descriptor)

addModule

public void addModule(ModuleDescriptor<BundleDescriptor> descriptor)

getModules

public java.util.Set<ModuleDescriptor<BundleDescriptor>> getModules()
Obtain a full set of module descriptors

Returns:
the set of bundle descriptors

getEjbComponentCount

public int getEjbComponentCount()
The number of EJB JARs in this application.

Returns:
the number of EJB JARS

getRarComponentCount

public int getRarComponentCount()

getEjbBundleByName

public EjbBundleDescriptor getEjbBundleByName(java.lang.String name)
Obtain the EJB-JAR in this application of the given name. If the JAR is not present, throw an IllegalArgumentException.

Returns:
the EjbBundleDescriptor object with the given name

getTargetUri

public java.lang.String getTargetUri(BundleDescriptor origin,
                                     java.lang.String relativeTargetUri)
Get the uri of a target based on a source module and a a relative uri from the perspective of that source module.

Parameters:
origin - bundle descriptor within this application
relativeTargetUri - relative uri from the given bundle descriptor
Returns:
target uri

getRelativeBundle

public BundleDescriptor getRelativeBundle(BundleDescriptor origin,
                                          java.lang.String relativeTargetUri)
Get a target bundle descriptor based on an input bundle descriptor and a relative uri from the perspective of the input bundle descriptor.

Parameters:
origin - bundle descriptor within this application
relativeTargetUri - relative uri from the given bundle descriptor to another bundle within the application.
Returns:
target BundleDescriptor or null if not found.

getRelativeUri

public java.lang.String getRelativeUri(BundleDescriptor origin,
                                       BundleDescriptor target)
Return the relative uri between two modules, from the perspective of the first bundle.

Returns:
relative uri or empty string if the two bundles are the same

getEjbBundleByUri

public EjbBundleDescriptor getEjbBundleByUri(java.lang.String name)
Get EJB-JAR of the given URI (filename within EAR)


getModuleDescriptorByUri

public ModuleDescriptor<BundleDescriptor> getModuleDescriptorByUri(java.lang.String uri)
Lookup module by uri.

Parameters:
uri - the module path in the application archive
Returns:
a bundle descriptor in this application identified by uri or null if not found.

getModuleDescriptorsByType

public java.util.Collection<ModuleDescriptor<BundleDescriptor>> getModuleDescriptorsByType(XModuleType type)
Lookup module by uri.

Parameters:
uri - the module path in the application archive
Returns:
a bundle descriptor in this application identified by uri or null if not found.

getModuleByUri

public BundleDescriptor getModuleByUri(java.lang.String uri)
Lookup module by uri.

Parameters:
uri - the module path in the application archive
Returns:
a bundle descriptor in this application identified by uri or null if not found.

getModuleByTypeAndUri

public <T extends BundleDescriptor> T getModuleByTypeAndUri(java.lang.Class<T> type,
                                                            java.lang.String uri)
Parameters:
type - the module type
uri - the module path in the application archive
Returns:
a bundle descriptor in this application identified by its type and uri

getEjbByName

public EjbDescriptor getEjbByName(java.lang.String ejbName)
Obtain the EJB in this application of the given display name. If the EJB is not present, throw an IllegalArgumentException.

Parameters:
ejbName - the name of the bean
Returns:
the EjbDescriptor object with the given display name

hasEjbByName

public boolean hasEjbByName(java.lang.String ejbName)
Return whether the application contains the given ejb by name..

Parameters:
ejbName - the name of the bean
Returns:
true if there is a bean matching the given name

getApplicationClientByName

public ApplicationClientDescriptor getApplicationClientByName(java.lang.String name)
Obtain the application client in this application of the given display name. If the application client is not present, throw an IllegalArgumentException.

Returns:
the ApplicationClientDescriptor object with the given display name

getApplicationClientByUri

public ApplicationClientDescriptor getApplicationClientByUri(java.lang.String name)
Obtain an application client descriptor in this application of the given URI. If the appclient is not present, throw an IllegalArgumentException.


getWebBundleDescriptorByName

public WebBundleDescriptor getWebBundleDescriptorByName(java.lang.String name)
Obtain the WAR in this application of the given display name. If the WAR is not present, throw an IllegalArgumentException.

Returns:
the WebBundleDescriptor object with the given display name

getWebBundleDescriptorByUri

public WebBundleDescriptor getWebBundleDescriptorByUri(java.lang.String name)
Get WAR of a given URI (filename within EAR)


getRarDescriptorByUri

public ConnectorDescriptor getRarDescriptorByUri(java.lang.String name)
Obtain the RAR in this application of the given URI. If the RAR is not present, throw an IllegalArgumentException.


getJndiNameEnvironments

public java.util.Set<JndiNameEnvironment> getJndiNameEnvironments()
Obtain the full set of all the subcomponents of this application that use a JNDI name environment..

Returns:
the Set of JndiNameEnvironment objects.

getWebServiceDescriptors

public java.util.Set<WebService> getWebServiceDescriptors()
Return a set of all com.sun.enterprise.deployment.WebService descriptors in the application.


getWebBundleDescriptors

public java.util.Set<WebBundleDescriptor> getWebBundleDescriptors()
Obtain the full set of all the WARs in this application.

Returns:
the Set of WebBundleDescriptor objects.

getStandaloneBundleDescriptor

public BundleDescriptor getStandaloneBundleDescriptor()
if this application object is virtual, return the standalone bundle descriptor it is wrapping otherwise return null

Returns:
the wrapped standalone bundle descriptor

getBundleDescriptors

public <T extends BundleDescriptor> java.util.Set<T> getBundleDescriptors(java.lang.Class<T> type)
Obtain a full set of bundle descriptors for a particular type

Parameters:
type - the bundle descriptor type requested
Returns:
the set of bundle descriptors

getBundleDescriptors

public java.util.Set<BundleDescriptor> getBundleDescriptors()
Obtain a set of all bundle descriptors, regardless of type

Returns:
the set of bundle descriptors

addBundleDescriptor

public void addBundleDescriptor(BundleDescriptor bundleDescriptor)
Add a web bundle descriptor to this application.

Parameters:
bundleDescriptor - the web bundle descriptor to add

removeBundleDescriptor

public void removeBundleDescriptor(BundleDescriptor bundleDescriptor)
Remove a web bundle descriptor from this application.

Parameters:
bundleDescriptor - the web bundle descriptor to remove

getEjbBundleDescriptors

public java.util.Set<EjbBundleDescriptor> getEjbBundleDescriptors()
Obtain the full set of all the Ejb JAR deployment information in this application.

Returns:
the Set of EjbBundleDescriptor objects.

getRarDescriptors

public java.util.Set<ConnectorDescriptor> getRarDescriptors()
Obtain the full set of all the Ejb JAR deployment information in this application.

Returns:
the Set of EjbBundleDescriptor objects.

getApplicationClientDescriptors

public java.util.Set<ApplicationClientDescriptor> getApplicationClientDescriptors()
Return the Set of app client deploymenbt objects.


getCMPDescriptorFor

public EjbCMPEntityDescriptor getCMPDescriptorFor(java.lang.String className)
Return the EjbCMPEntityDescriptor for a bean for the given classname. It is assumed that there is a 1-to-1 mapping from class to descriptor. This is called at runtime from the Persistence Manager.


getEjbDescriptors

public java.util.Vector getEjbDescriptors()
Return the Vector of ejb deployment objects.


containsCMPEntity

public boolean containsCMPEntity()
Returns:
true if this bundle descriptor contains at least one CMP EntityBean

getSortedEjbDescriptors

public EjbDescriptor[] getSortedEjbDescriptors()
Returns all the ejb descriptor in this application in ordered form. The comparison is done based on the descriptor's name.

Returns:
all ejb descriptors in ordered form

setVirtual

public void setVirtual(boolean virtual)
Sets the virtual status of this application. If this application object represents a stand alone module, virtaul status should be true; else false.

Parameters:
virtual - new value of this application's virtaul status

isVirtual

public boolean isVirtual()
Returns the virtual status of this application.

Returns:
true if this application obj represents a stand alone module

isUniqueIdSet

public boolean isUniqueIdSet()

setUniqueId

public void setUniqueId(long id)
Sets the unique id for this application. It traverses through all the ejbs in the application and sets the unique id for each of them. The traversal is done in ascending element order. NOTE : assumption is that the id has already been left shifted 16 bits to allow space for the component ids.

Parameters:
id - unique id for this application

getUniqueId

public long getUniqueId()
Returns the unique id used for this application.

Returns:
unique id used for this application

setPassByReference

public void setPassByReference(boolean passByReference)
Sets the pass-by-reference property for this application. EJB spec requires pass-by-value (false) which is the default. This can be set to true for non-compliant operation and possibly higher performance. For a stand-alone server, this can be used. By setting pass-by-reference in sun-application.xml, it can apply to all the enclosed ejb modules.

Parameters:
passByReference - boolean true or false - pass-by-reference property of application. true - application is pass-by-reference false - application is pass-by-value

getPassByReference

public boolean getPassByReference()
Gets the value of pass-by-reference property for this application Checks to see if the pass-by-reference property is defined. If this application's pass-by-reference property is defined, this method returns the value of the application's pass-by-reference property. Otherwise, if the application's pass-by-reference property is undefined, this method returns a default value of false.

Returns:
boolean pass-by-reference property for this application

isPassByReferenceDefined

public boolean isPassByReferenceDefined()

addApplication

public void addApplication(Application application)
Add all the deployment information about the given application to me.


getArchivableDescriptors

public java.util.Set getArchivableDescriptors()
Return all my subcomponents that have a file format (EJB, WAR and AppCLient JAR).


setRoleMapper

public void setRoleMapper(SecurityRoleMapper roleMapper)
Sets the mapping of rolename to users and groups on a particular server.


hasRuntimeInformation

public boolean hasRuntimeInformation()
Return true if I have information to do with deployment on a particular operational environment.


getRoleMapper

public SecurityRoleMapper getRoleMapper()
Return my mapping of rolename to users and groups on a particular server.

Specified by:
getRoleMapper in interface RoleMappingContainer

setRealm

public void setRealm(java.lang.String realm)
Sets the realm for this application


getRealm

public java.lang.String getRealm()
Returns:
the realm for this application

isDirty

public boolean isDirty()
A flag to indicate that my data has changed since the last save.


getClassLoader

public java.lang.ClassLoader getClassLoader()
Overrides:
getClassLoader in class BundleDescriptor
Returns:
the class loader associated with this application

print

public void print(java.lang.StringBuffer toStringBuffer)
A formatted String representing my state.

Overrides:
print in class BundleDescriptor

visit

public void visit(DescriptorVisitor aVisitor)
visit the descriptor and all sub descriptors with a DOL visitor implementation

Overrides:
visit in class Descriptor
Parameters:
aVisitor - visitor to traverse the descriptors

visit

public void visit(ApplicationVisitor aVisitor)
visit the descriptor and all sub descriptors with a DOL visitor implementation

Parameters:
aVisitor - visitor to traverse the descriptors

getModuleID

public java.lang.String getModuleID()
Overrides:
getModuleID in class BundleDescriptor
Returns:
the module ID for this module descriptor

isApplication

public boolean isApplication()
Overrides:
isApplication in class BundleDescriptor
Returns:
true if this module is an application object

getModuleType

public XModuleType getModuleType()
Specified by:
getModuleType in class BundleDescriptor
Returns:
the module type for this bundle descriptor

addSecurityRoleMapping

public void addSecurityRoleMapping(SecurityRoleMapping roleMapping)

getSecurityRoleMappings

public java.util.List<SecurityRoleMapping> getSecurityRoleMappings()

getWlRoleAssignments

public java.util.List<WLSecurityRoleAssignment> getWlRoleAssignments()

addWLRoleAssignments

public void addWLRoleAssignments(WLSecurityRoleAssignment wlRoleAssignment)

setLoadedFromApplicationXml

public void setLoadedFromApplicationXml(boolean bool)
This method records how this Application object is constructed. We keep this information to avoid additional disk access in DescriptorArchivist.write() when deciding if the application.xml should be copied or written to the generated/xml directory.


isLoadedFromApplicationXml

public boolean isLoadedFromApplicationXml()
Returns:
true if this Application is from reading application.xml from disk; false if this Application object is derived from the content of the ear file.

setResourceList

public void setResourceList(java.util.List<Resource> rList)

getResourceList

public java.util.List<Resource> getResourceList()

addResourceAdapter

public void addResourceAdapter(java.lang.String raName)
add a resource-adapter to referred resource-adapters list

Parameters:
raName - resource-adapter name

getResourceAdapters

public java.util.Set<java.lang.String> getResourceAdapters()
get the list of resource-adapters referred by the application

Returns:
resource-adapters list

getApplicationParams

public java.util.Set<ApplicationParameter> getApplicationParams()
Returns:
the Set of application paramaters.

addApplicationParam

public void addApplicationParam(ApplicationParameter appParam)
Adds a new context parameter to my list.


getWLModules

public java.util.Set<WLModuleDescriptor> getWLModules()
Returns:
the Set of weblogic modules.

addWLModule

public void addWLModule(WLModuleDescriptor wlModule)
Adds a new context parameter to my list.


getKeepState

public boolean getKeepState()
Overrides:
getKeepState in class BundleDescriptor

getKeepStateResolved

public boolean getKeepStateResolved()
Returns the resolved keepstate value.

Returns:
keepStateResolved

setKeepStateResolved

public void setKeepStateResolved(java.lang.String keepStateResolved)
Sets the resolved keepstate value.

Parameters:
keepStateResolved -


Copyright © 2012 GlassFish Community. All Rights Reserved.