• 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

XML Verification using JARV

 
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a Java application that is supposed to validate an XML file using a schema. At this time I'm using JARV and running into a problem that isn't addressed in any of the Sun tutorials.
The lines for the validation are:
VerifierFactory factory = VerifierFactory.newInstance("http://www.w3.org/2001/XMLSchema");
Verifier verifier = factory.newVerifier("http://127.0.0.1:8070/soap/DataFolder/MySchema.xsd");
try {
if(verifier.verify(new File("EPSQ.xml")))
System.out.println("VALID XML");
.....
It all compiles, but when I run it I'm getting the following error on the second line ("Verifier verifier..."):
Exception in thread "main" org.iso_relax.verifier.VerifierConfigurationException
Anyone with experience and/or ideas about this? I have never done this before.
Thanks,
 
Angela Margot
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I figured this one out...I was using xerces.jar from apache, needed to use the xerces.jar from the Sun MRV (downloaded XML package from Sun).
Another stunning success :roll:
 
Angela Margot
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No...it's Sun's MSV - Multi-Schema Validator...
reply
    Bookmark Topic Watch Topic
  • New Topic