Uploaded image for project: 'XMLBeans'
  1. XMLBeans
  2. XMLBEANS-378

Add system property to allow override of default piccolo parser

    XMLWordPrintableJSON

Details

    • Wish
    • Status: Closed
    • Minor
    • Resolution: Abandoned
    • Version 2.3
    • None
    • XmlObject
    • None

    Description

      It would be useful to allow the default piccolo parser to be replaced by other SAX2 conformant parsers that may other more features/performance without having to make application code changes.

      This can be done by some minor changes to the Store Locale.java mechanism that caches piccolo parsers per thread. In a trial implementation (see attached patch) an xmlbeans specific system property is added which has the same meaning as the 'org.xml.sax.driver' property, i.e. it specifies the name of a org.xml.sax.XMLReader class. If the property is set this parser is instantiated instead of a piccolo parser.

      The patch passes checkintest when the property "org.apache.xmlbeans.xmlreader" is set to "com.sun.org.apache.xerces.internal.parsers.SAXParser" on a jdk1.5.0_15 on WIN32.

      Attachments

        1. xmlbeans-system-default-xml-reader.diff
          2 kB
          Rodrigo Setti
        2. patch_alt_parser
          3 kB
          Kevin Jones

        Activity

          People

            Unassigned Unassigned
            kjouk Kevin Jones
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: