Class XMLDocumentation


  • public class XMLDocumentation
    extends AbstractDocumentation
    This class represents a structured documenation.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getAttributeDefaultValue​(java.lang.String elementName, java.lang.String attributeName)
      Returns the default value of an attribute.
      java.lang.String[] getAttributeEnumValues​(java.lang.String elementName, java.lang.String attributeName)
      Returns the enumeration values of a specified attribute.
      void modifyAttributeDTD​(java.lang.String elementName, java.lang.String attributeName, java.lang.String[] values, java.lang.String defValue)
      Modifies the DTD of an attribute.
      boolean removeAttributeDTD​(java.lang.String elementName, java.lang.String attributeName)
      Removes an attribute for the specified element.
      XMLDocuNode root()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • removeAttributeDTD

        public boolean removeAttributeDTD​(java.lang.String elementName,
                                          java.lang.String attributeName)
        Removes an attribute for the specified element. The attribute is removed from the DTD of this XML documentation
        Parameters:
        elementName - Name of the element
        attributeName - Name of the attribute
        Returns:
        true if the attribute was removed or false if not found
      • getAttributeEnumValues

        public java.lang.String[] getAttributeEnumValues​(java.lang.String elementName,
                                                         java.lang.String attributeName)
        Returns the enumeration values of a specified attribute.
        Parameters:
        elementName - Name of element
        attributeName - Name of the attribute
        Returns:
        String array containing the valid values for this attribute or null if the attribute was not found or does not contain enum values
      • getAttributeDefaultValue

        public java.lang.String getAttributeDefaultValue​(java.lang.String elementName,
                                                         java.lang.String attributeName)
        Returns the default value of an attribute.
        Parameters:
        elementName - Name of the element
        attributeName - Name of the attribute
        Returns:
        default value or an empty String if no default value has been set
      • modifyAttributeDTD

        public void modifyAttributeDTD​(java.lang.String elementName,
                                       java.lang.String attributeName,
                                       java.lang.String[] values,
                                       java.lang.String defValue)
        Modifies the DTD of an attribute. If the attribute does not exist it is added to the DTD.
        Parameters:
        elementName - Name of the element
        attributeName - Name of the attribute
        values - Enumeration values or null if this attribute can contain any values
        defValue - Default value