Package org.xml.sax.helpers

Examples of org.xml.sax.helpers.XMLFilterImpl


        handler = new WhitespaceStripper(handler,errorReceiver,entityResolver);
        handler = new VersionChecker(handler,errorReceiver,entityResolver);

        // insert the reference finder so that
        // included/imported schemas will be also parsed
        XMLFilterImpl f = logic.createExternalReferenceFinder(this);
        f.setContentHandler(handler);

        if(errorReceiver!=null)
            f.setErrorHandler(errorReceiver);
        if(entityResolver!=null)
            f.setEntityResolver(entityResolver);

        return f;
    }
View Full Code Here


    /**
     * Creates a {@link SAXSource} that, when parsed, reads from this {@link DOMForest}
     * (instead of parsing the original source identified by the system ID.)
     */
    public @NotNull SAXSource createSAXSource(String systemId) {
        ContentHandlerNamespacePrefixAdapter reader = new ContentHandlerNamespacePrefixAdapter(new XMLFilterImpl() {
            // XMLReader that uses XMLParser to parse. We need to use XMLFilter to indrect
            // handlers, since SAX allows handlers to be changed while parsing.
            @Override
            public void parse(InputSource input) throws SAXException, IOException {
                createParser().parse(input, this, this, this);
View Full Code Here

        ContentHandler handler = new WhitespaceStripper(dombuilder, errorReceiver, entityResolver);
        handler = new VersionChecker(handler, errorReceiver, entityResolver);

        // insert the reference finder so that
        // included/imported schemas will be also parsed
        XMLFilterImpl f = logic.createExternalReferenceFinder(this);
        f.setContentHandler(handler);
        if (errorReceiver != null)
            f.setErrorHandler(errorReceiver);
        f.setEntityResolver(entityResolver);

        reader.setContentHandler(f);
        if (errorReceiver != null)
            reader.setErrorHandler(errorReceiver);
        reader.setEntityResolver(entityResolver);
View Full Code Here

TOP

Related Classes of org.xml.sax.helpers.XMLFilterImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.