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

Re: validation against xml schema (xsd)

  • From: George Cristian Bina <george@o...>
  • To: "Johnson, Matthew C. (LNG-HBE)" <Matthew.C.Johnson@l...>
  • Date: Fri, 06 Mar 2009 15:29:43 +0200

Re:  validation against xml schema (xsd)
Hi Matt,

Philippe is right, NVDL should work, I also should have suggested it.
You can find the available NVDL implementations linked from here


In addition to those listed there you can also use Jing from
because the oNVDL implementation was merged back into Jing. Note however 
that you need to check out Jing [1] and just run its build script to get 
the jars with NVDL support, for details see [2].

Basically you need to create a script that in the initial mode matches 
on each namespace you are interested in and validates with the schema 
for each namespace using a mode that attaches all the descendant 
sections to the initial one, something like below:

<?xml version="1.0" encoding="UTF-8"?>
<rules xmlns="http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0" 
     <mode name="match">
         <namespace ns="http://www.example.com/namespaceA">
             <validate schema="a.xsd" useMode="attach"/>
         <namespace ns="http://www.example.com/namespaceB">
             <validate schema="b.xsd" useMode="attach"/>
     <mode name="attach">

Note also that using NVDL allows you to use not only XML Schema but also 
Schematron and Relax NG and also you can validate a document against 
multiple schemas:

Relax NG:
         <namespace ns="http://www.example.com/namespaceC">
             <validate schema="c.rng" useMode="attach"/>
Multiple validations, against XSD and Schematron:
         <namespace ns="http://www.example.com/namespaceD">
             <validate schema="d.xsd" useMode="attach"/>
             <validate schema="d.sch" useMode="attach"/>

[1] http://code.google.com/p/jing-trang/source/checkout
[2] http://code.google.com/p/jing-trang/wiki/HowToBuildFromSource

Best Regards,
George Cristian Bina
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger

Johnson, Matthew C. (LNG-HBE) wrote:
> Thank you Philippe.  I had been considering NVDL (I recall a thread
> involving Roger Costello on NVDL) but have not had time to investigate
> further.  Perhaps, this will give me the proper motivation!
> Matt
>> -----Original Message-----
>> From: Philippe Poulard [mailto:philippe.poulard@s...]
>> Sent: Friday, March 06, 2009 4:28 AM
>> To: Johnson, Matthew C. (LNG-HBE)
>> Cc: xml-dev@l...
>> Subject: Re:  validation against xml schema (xsd)
>> Hi,
>> I think NVDL can do this for you:
>> http://nvdl.org/
>> --
>> Cordialement,
>>                ///
>>               (. .)
>>   --------ooO--(_)--Ooo--------
>> |      Philippe Poulard       |
>>   -----------------------------
>>   http://reflex.gforge.inria.fr/
>>         Have the RefleX !
> _______________________________________________________________________
> XML-DEV is a publicly archived, unmoderated list hosted by OASIS
> to support XML implementation and development. To minimize
> spam in the archives, you must subscribe before posting.
> [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
> Or unsubscribe: xml-dev-unsubscribe@l...
> subscribe: xml-dev-subscribe@l...
> List archive: http://lists.xml.org/archives/xml-dev/
> List Guidelines: http://www.oasis-open.org/maillists/guidelines.php

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


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.
First Name
Last Name
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.