Class XHTML


  • public class XHTML
    extends Object
    Reads/inserts an attribute from/to a given XHTML-Tag
    Author:
    Matthias Herlitzius
    • Constructor Detail

      • XHTML

        public XHTML()
    • Method Detail

      • removeAttr

        public static String removeAttr​(String tag,
                                        String attr)
        Removes the attribute from the tag
        Parameters:
        tag -
        attr -
        Returns:
        the tag without the attribute
      • setAttr

        public static String setAttr​(String tag,
                                     String attr,
                                     String value)
        Sets the attribute of the tag
        Parameters:
        tag -
        attr -
        value -
        Returns:
        the tag with the attribute set
      • setBody

        public static String setBody​(String tag,
                                     String value)
        Sets the body content for the tag
        Parameters:
        tag -
        value -
        Returns:
        the tag with the body content
      • getAttr

        public static String getAttr​(String tag,
                                     String attr)
        Retrieves the attribute of the tag
        Parameters:
        tag -
        attr -
        Returns:
        the attribute value
      • getTag

        public static String getTag​(String tag)
        Retrieves the tag's name
        Parameters:
        tag -
        Returns:
        the tag's name