OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] Schematron and RNG, RNC

<?xml version="1.0" encoding="UTF-8"?>
<grammar ns="http://docbook.org/ns/docbook" xmlns:db="http://docbook.org/ns/docbook" xmlns:s="http://www.ascc.net/xml/schematron" xmlns:svg="http://www.w3.org/2000/svg" xmlns:dk="http://docbook.org/ns/docbook" xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://relaxng.org/ns/structure/1.0">

  <s:pattern id="condition.checks">

Not sure if I explained that well but here is what i've done and no syntax error given..

I was following the advice from http://www.xml.com/pub/a/2004/02/11/relaxtron.html?page=2

" it is recommended that you embed the Schematron rules in one of two places:
  1. Insert all the embedded Schematron rules at the beginning of the RELAX NG schema as a child of the top-level element. Then you always know that if you have embedded rules, they will be specified together and in the same place.

  2. Specify each Schematron rule on the element pattern that specifies the context of the embedded rule. In the previous example this means that one of the Schematron rules would be embedded on the element pattern for the item element and the other on the element pattern for the amount element in the payment section."

I've been writing and testing the schematron rules in a separate files. Ideally I suppose I would just import that file.

On Fri, Feb 3, 2012 at 7:01 PM, John Cowan <cowan@mercury.ccil.org> wrote:
> Well the other thing I'm not clear on is that for the RNG the schematron
> logic can be placed after the top level grammar element,, for the RNC I'm
> getting syntax error

I don't understand that.  An element placed after the document (top-level)
element would not be well-formed XML.

Alex Muir
Program Organizer - University Technology Student Work Experience Building
University of the Gambia


Come visit Gambia enjoy the sun and culture and help out! Software Engineering Lecturers needed!
Join UTSWEB do local contract work or give a student a contract remotely for slow, cheap and good work http://sites.utg.edu.gm/utsweb/

Some fantastic African/Canadian Fusion  http://bafila.bandcamp.com/

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

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS