Class TomcatContextXml

  • All Implemented Interfaces:
    Serializable, Cloneable, Descriptor, org.jdom2.NamespaceAware, org.jdom2.Parent

    public class TomcatContextXml
    extends AbstractDescriptor
    Encapsulates the DOM representation of a web deployment descriptor META-INF/context.xml to provide convenience methods for easy access and manipulation.
    See Also:
    Serialized Form
    • Constructor Detail

      • TomcatContextXml

        public TomcatContextXml​(org.jdom2.Element rootElement,
                                DescriptorType type)
        rootElement - The root element of the context
        type - the document descriptor type
    • Method Detail

      • getPath

        public String getPath()
        the context path element found in the context.xml file (available in the path attribute) or null if not defined
      • getParameters

        public Map<org.jdom2.Attribute,​org.jdom2.Attribute> getParameters()
        Gets all the parameters that match XPath "Context/Parameter".
        Always non-null (but possibly empty) map keyed by Context/Parameter/@name and value is Context/Parameter/@value
      • getFileName

        public String getFileName()
        Returns the file name of this descriptor. For example "web.xml", "weblogic.xml", etc.
        the file name