You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Suresh Addagalla <su...@wipro.com> on 2003/07/25 09:25:28 UTC

[OT] Line numbers while parsing XML

Hi,

I am using struts-upload to upload an XML file and Xerces API to parse
the same.

I need to "compile" the XML file in the sense that I need to report any
errors back to the user along with the line numbers, like compilation
errors. These are not XML parsing errors, but application level errors;
for example, a "code" attribute of an element may be such that it is not
unique when a DB insertion is attempted.

Is this possible to implement with DOM? Or do I need to switch to SAX
and use the Locator handler to get the line number information?

Thanks,
Suresh


**************************Disclaimer************************************

Information contained in this E-MAIL being proprietary to Wipro Limited is 
'privileged' and 'confidential' and intended for use only by the individual
 or entity to which it is addressed. You are notified that any use, copying 
or dissemination of the information contained in the E-MAIL in any manner 
whatsoever is strictly prohibited.

***************************************************************************

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org