public class ApplicationXml extends AbstractDescriptor implements J2eeDescriptor
application.xml
) to
provide convenience methods for easy access and manipulation.Constructor and Description |
---|
ApplicationXml(org.jdom.Element rootElement,
DescriptorType type)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addEjbModule(String name)
Adds a ejb module to the deployment descriptor.
|
void |
addWebModule(String uri,
String context)
Adds a web module to the deployment descriptor.
|
Iterator |
getEjbModules()
Returns an iterator over the ejb modules defined in the descriptor.
|
Iterator |
getElements(ApplicationXmlTag tag)
Returns an iterator over the elements that match the specified tag.
|
String |
getFileName()
Returns the file name of this descriptor.
|
Iterator |
getVendorDescriptors()
Returns all vendor descriptors associated with this J2EE deployment descriptor.
|
ApplicationXmlVersion |
getVersion() |
org.jdom.Element |
getWebModule(String webUri)
Returns the element that contains the definition of a specific web module, or
null if a web module with the specified web-uri is not defined. |
String |
getWebModuleContextRoot(String webUri)
Returns the context root of the the specified web module.
|
Iterator |
getWebModuleUris()
Returns an iterator over the URIs of the web modules defined in the descriptor.
|
addElement, checkElement, createNestedText, getChildText, getChildText, getDescriptorType, getDocument, getElements, getElements, getImmediateChild, getInsertionPointFor, getNestedElements, getNestedText, getTagByIdentifier, getTagByIdentifier, getTags, getTags, getText
addContent, addContent, addContent, addContent, clone, cloneContent, detachRootElement, equals, getBaseURI, getContent, getContent, getContent, getContentSize, getDescendants, getDescendants, getDocType, getParent, getProperty, getRootElement, hashCode, hasRootElement, indexOf, removeContent, removeContent, removeContent, removeContent, setBaseURI, setContent, setContent, setContent, setContent, setDocType, setProperty, setRootElement, toString
finalize, getClass, notify, notifyAll, wait, wait, wait
addElement, getDescriptorType, getDocument, getRootElement, getTagByIdentifier, getTags
public ApplicationXml(org.jdom.Element rootElement, DescriptorType type)
rootElement
- the root element for this descriptortype
- the type of this descriptorpublic ApplicationXmlVersion getVersion()
public org.jdom.Element getWebModule(String webUri)
null
if a web module with the specified web-uri is not defined.webUri
- The uri of the web modulepublic String getWebModuleContextRoot(String webUri)
webUri
- The uri of the web modulepublic Iterator getWebModuleUris()
public Iterator getEjbModules()
public Iterator getElements(ApplicationXmlTag tag)
tag
- The descriptor tag of which the elements should be returnedpublic void addWebModule(String uri, String context)
uri
- the uri of the new modulecontext
- the context of the new modulepublic void addEjbModule(String name)
name
- the name of the new modulepublic Iterator getVendorDescriptors()
web.xml
is
jboss-web.xml
.getVendorDescriptors
in interface J2eeDescriptor
J2eeDescriptor.getVendorDescriptors()
public String getFileName()
getFileName
in interface Descriptor
Descriptor.getFileName()
Copyright © 2004-2013 Codehaus. All Rights Reserved.