• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

XSD validation

 
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to do on the fly validation of an XML document that I am constructing.

I perform xsd validation of a Document object using an xsd file and javax.xml.validation.Validator. If the xsd validation fails, i get a SAXException. I need to identify programmatically which xml tag failed the validation. How can I do that?
If I perform the validation on an xml file, I get the line number of the error, but not for a Document object.
Is there an alternate solution to my problem?
Thanks!!
 
reply
    Bookmark Topic Watch Topic
  • New Topic