Class Parse


  • public class Parse
    extends Object
    Miscellaneous XML parsing methods created Jul 3, 2007
    • Constructor Detail

      • Parse

        public Parse()
    • Method Detail

      • readRootElement

        public static org.jdom2.Element readRootElement​(String location)
                                                 throws IOException
        Read an XML Document from a URL and return the root element.
        Parameters:
        location - the URL location
        Returns:
        the root element of the Document
        Throws:
        IOException - on read error
      • cleanCharacterData

        public static String cleanCharacterData​(String text)
        Make sure that text is XML safe
        Parameters:
        text - check this
        Returns:
        original text if ok, else with bad characters removed