users@jaxb.java.net

Re: Question on JAXB 2.0 ValidationEventHandler

From: Srikanth R Chinthala <csr_1978_at_yahoo.com>
Date: Tue, 30 Mar 2010 05:39:36 -0700 (PDT)

Laun,

Does JAXB 2.0 use SAX parser by default? How do i make it to use DOM parser?

Could you please provide a sample code snippet. Sorry if i am asking a silly
question. Please care to reply.

Thanks,


Unmarshalling with a SAX parser won't produce DOM nodes, which would be
returned
by Locator.getNode(). You might try to create a DOM tree from the XML file
and
unmarshal from that.

It's strange that you might be able to "perform some business logic" on a
broken
XML document (except diagnose the error, of course).

-W

-- 
View this message in context: http://old.nabble.com/Question-on-JAXB-2.0-ValidationEventHandler-tp28076972p28081915.html
Sent from the java.net - jaxb users mailing list archive at Nabble.com.