Wed, 12 Mar 2008 16:25:59 -0300, /Daniel Yokomizo/:

The only issue I still have is getting the xml declaration info (e.g. version, encoding) but right now I can just ignore it.

That info you should be able to obtain through the Locator2 [1] interface. For example, in your ContentHandler implementation:

    Locator locator;

    public void setDocumentLocator(Locator locator) {
        this.locator = locator;
    }

    public void startDocument() {
        if (locator instanceof Locator2) {
             Locator2 loc = (Locator2) locator;
             loc.getXMLVersion();
             loc.getEncoding();
        }
    }

[1] http://xerces.apache.org/xerces2-j/javadocs/api/org/xml/sax/ext/Locator2.html

--
Stanimir

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to