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

 


Help: OASIS Mailing Lists Help | MarkMail Help

office-comment message

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


Subject: Re: [office-comment] Unacceptable presentation of content models(ODF 1.2CD01r5)


Michael Brauer - Sun Germany - ham02 - Hamburg wrote:
>  
> Again, this is to some degree a question of personal preferences. 
> People which are familiar with reading RNG in compact notation may 
> prefer this notation, others may prefer RNG in XML notation, and 
> others may prefer natural language even if it is not as exact as a 
> schema fragment.
>  
>
It also shows the unsatisfactory nature of having natural language and 
schemas disconnected, or even loosely connected.  It leads to the 
situation where people somehow consider natural language and schemas as 
in opposition to each, or as alternatives to each other.

ISO Schematron is a schema language that allows a tight coupling of 
natural language statements and declarative tests (e.g. using XPath.)  
So a Schematron schema can be pretty-printed so that each assertion is a 
bullet list (there are stylesheets to to convert Schematron schemas into 
ISO standard format, for example).

Plus, things like "upwards content models" (i.e. parents or ancestors) 
are easy to express.

For example, consider "A row element shall only be used immediately in a 
table element."  The Schematron schema for this is:

<sch:rule context="odf:row">
   <sch:assert test="parent::odf:table">
   A row element shall only be used immediately in a table element.
   </sch:assert>
</sch:rule>

It is almost impossible to always have natural language that is simple 
and yet unambiguous. Unfortunately it is equally often impossible to 
have schemas that complete capture a constraint at a perfect level of 
granularity. With Schematron, both can be captured, augmenting each 
other and providing discipline for the standards-maker, but with the 
text and the test coupled for maintainability and guaranteed coverage.

Cheers
Rick Jelliffe



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