[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: validating against the standard W3C


w3c verifier
can i use xmlspy with a java api ...
i want to call a validation on the file before uploading to a database
this validation has to be done in a java context (java api)
 
mvg, bart
 -----Original Message-----
From: AndrewWatt2000@a... [mailto:AndrewWatt2000@a...]
Sent: Tuesday, December 11, 2001 1:37 PM
To: xml-dev@l...
Subject: Re: validating against the standard W3C

In a message dated 11/12/01 11:32:13 GMT Standard Time, Bart.Boogaerts@A... writes:


at this moment, we are using MSV from Sun to validate our schema's and it works well, good and quick...
while working with our own schema's.
we want to validate our schema's against the standard W3C schema but by implementing this, we get errors...
Has anyone an idea of how we should use this standard, should we download the files and then use them (if so where can we find them -> the correct ones)
when pointing directly to the url, it can't validate www.w3.org...
when downloading  the file, it can't find the anySimpleType...
Source Code
VerifierFactory factory = new com.sun.msv.verifier.jarv.TheFactoryImpl();
and:
Schema schema = factory.compileSchema("http://www.w3.org/2001/XMLSchema.xsd");
Verifier verifier = schema.newVerifier();
or:
Verifier verifier = factory.newVerifier("d:/schema/XMLSchema.xsd");
Has anyone an idea about how we should validate our xml files against this standard??
thanks for helping, bart


Bart,

The basic problem at this point in time is being totally sure of what the gold standard is. The W3C XML Schema Rec, particularly Part 1, seems almost designed to be impenetrable. [I have had my knuckles rapped before for saying that, but I still believe it to be true.]

Inevitably implementors have to interpret the impenetrable and implementors differ in how they do interpret it. I would suggest that at this point in the development of XSD Schema (W3C XML Schema) tools that there is some sort of safety in numbers.

Take a look at the schema validation facilities in XML Spy and in Turbo XML from Extensibility. Both are fairly good validators and have free evaluation downloads available. I spent several weeks working with both downloads on a range of (relatively brief) schemas. Occasionally Turbo XML (2.2.1 I think) would miss errors and slightly more often XML Spy (4.01 I think) would declare spurious errors.

So if you put those validators and their error messages together with the results from the tool you are already using then you will begin to (hopefully) creep closer to the truth.

Others may disagree but for a little time yet I don't think one can safely assume that the absence of an error message from a W3C XML Schema validation tool accurately predicts the absence of errors nor does an error message necessarily accurately predict the presence of errors.

Some patience is called for - both in working through the current situation and also in waiting for the next iteration of (constantly improving) tools.

Andrew Watt

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.