SS is very good at checking that the aa stuff is well formed, but I have not found a way to persuade it to actually validate against the aa schema. I have tried declaring and importing the aa namespace, but still no joy.
Subject:Can SS validate tags used in appinfo element of XSD? Author:(Deleted User) Date:02 Jul 2007 09:09 AM
Hi Nick,
unfortunately the validating parser used by Stylus Studio (Xerces-C++) validates annotations only against the official XMLSchema specs, that allow any well formed element inside appinfo or documentation.
We'll investigate whether in a future version of Stylus this behavior can be modified to also validate against the generated schema, so that your custom schema can be used.
To make it visible in the Validation drop-down, I had to tick the "Supports validation of XML schema" box (which is not ticked on the example page).
I then tried to validate an XSD with my bespoke tags in the AppInfo section (and I have an Import of the schema that defines the bespoke tags). This is the result:
c:\msv>java -cp msv-driver.jar;msv.jar com.stylusstudio.msv.StylusDriver "c:/XXXXXXXXX/TypesXXXX-v1-00a.xsd"
Stylus Studio Driver for the Sun MSV Validator 20030225
--Starting validation of "c:/XXXXXXXXX/TypesXXXX-v1-00a.xsd"--
No identifiable DTD or XML Schema in c:/XXXXXXXXX/TypesXXXX-v1-00a.xsd
--Completed validation of "c:/XXXXXXXXX/TypesXXXX-v1-00a.xsd"--
No discernable difference whether my bespoke tags are correct or not. That said, I wonder whether the "No identifiable DTD or...." message is suggesting that I am doing something wrong.
Subject:Can SS validate tags used in appinfo element of XSD? Author:(Deleted User) Date:03 Jul 2007 06:08 AM
Hi Nick,
the 'Support validation of XML Schema' of the Sun Multi-Schema Validator is not checked because it doesn't support validating stand-alone schemas, but only XML documents referencing an XMLSchema.
You can however use the XSV validator (http://www.stylusstudio.com/xml_schema/xsv.html), or the IBM Schema Quality Checker (http://www.stylusstudio.com/sqc.html); but I fear neither will validate non-XMLSchema elements inside annotations.