XML Schema Quality Checker

IBM's alphaWorks group released a tool called the XML Schema Quality Checker, which checks both the letter of the law and also its spirit, when validating the quality of an XML schema document. For example, it will check all of the enumerated values of an element or type, and make sure they all fit within a given length facet.

This article tells you how you can integrate the SQC into Stylus Studio as one of the Custom Validation Engines

Where Can I Get the Schema Quality Checker?

Click here to get to the main page, and go to "Downloads and demos".

The software comes as a .zip file (at the time of this writing, it's SQC2.2.1.zip at about 3 megabytes). An archived copy of the SQC2.2.1.zip file is also available from our website.

Installing the Schema Quality Checker

  1. Unpack the .zip file. For our testing purposes, we'll assume you unpack it into C:\SQC
  2. In Stylus Studio, go to Tools|Options|General|Custom Validation Engines
  3. Click on the Add New Validator icon to add a new custom validator
  4. Fill in the entries like this:
    Custom Validation Engines showing SQC settings

Using the Schema Quality Checker

Open any XML Schema file, and click on the Validate XSD Document (Validate Document) icon to drop down the list, and then select the Schema Quality Checker entry.

XSD Validation Dropdown showing SQC

You will see the Output window appear, and show something like this:

Running custom validation engine Schema Quality Checker...

Initializing Schema Quality Checker. Please wait ...
SchemaQualityChecker has been initialized
PROCESSING c:\u\cd-UBL-1.0\xsd\codelist\UBL-CodeList-ChipCode-1.0.xsd time : 2005-09-07T00:43:46 ...
c:\u\cd-UBL-1.0\xsd\codelist\UBL-CodeList-ChipCode-1.0.xsd (file 1 of 1) now being read ...
NO ERROR
end time = 2005-09-07T00:43:49

Variations on a Theme: WSDL, XForms, and More

The SQC supports several options which modify its behavior. It might be useful to add more than one SQC validation entry, each with different parameters for different situations. For example, the following could be used in the Arguments: field instead of just plain ${FilePath}:

  • -emb ${FilePath} to tell SQC to also validate embedded schemas
  • -wsdl ${FilePath} to tell SQC to validate embedded schemas in WSDL documents
  • -xform ${FilePath} to tell SQC to validate embedded schemas in XForms

The full list of available options can be seen by just typing SQC at the command line.

Congratulations! You've just added a powerful new tool to your Stylus Studio toolbox.

PURCHASE STYLUS STUDIO ONLINE TODAY!!

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

Buy Stylus Studio Now

Try STYLUS

Download a free trial of Stylus Studio's cross-platform development and validation tools Today!.

Get More Tips on Extending Stylus Studio Delivered to Your Inbox

Subscribe to the Stylus Scoop newsletter and get next month's tricks of the trade delivered to your inbox for free!.

What's New for Stylus Studio® X16?

New XQuery & Web Services Tools, Support for MySQL, PostgreSQL, HL7 EDI, Microsoft .NET Code Generation and much more!

Why Pay More for XML Tools?

With Stylus Studio® X16 XML Enterprise Suite, you get the most comprehensive XML tool suite at one incredibly low price. Value: it's just one of many reasons why smart XML developers are choosing Stylus Studio!

 
Free Stylus Studio XML Training:
W3C Member