Class XmlDataSniffer


  • public class XmlDataSniffer
    extends Object
    Utility class that checks if provided byte data is a valid XML document. It does this by attempting to parse the data using a SAX parser.
    Author:
    Teodor Danciu (teodord@users.sourceforge.net)
    • Constructor Detail

      • XmlDataSniffer

        public XmlDataSniffer()
    • Method Detail

      • isXmlData

        public static boolean isXmlData​(byte[] data)
      • setParserFeature

        protected static void setParserFeature​(SAXParserFactory factory,
                                               String feature,
                                               boolean value)