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

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   RE: [xml-dev] Two Questions - on XML Schema

[ Lists Home | Date Index | Thread Index ]

The reference is W3C-member restricted.

It might be that we've reached the stage where we can't afford to do things
properly so we have to do them cheaply. If that's the case, then this is
probably the right way forward. However, one needs to be aware of its
limitations. For example, if there are two possible content models for an
element and you want to control which one to use based on an attribute, then
you have to define the union of the two content models and design XPath
expressions that implement two permitted subsets. That seems pretty unusable
to me.

To my mind, grammar-based constraints and value-based constraints should be
much more closely integrated than this. And I don't think it's impossible.
One way of doing co-occurrence constraints is to think in terms of a
"computed xsi:type" where the effective value of xsi:type on an element is
computed as the result of an XPath expression in the schema, applied to the
element instance as context node. This expression can default to
"@xsi:type", so the current xsi:type facility becomes just a special case.

That doesn't preclude the needs for generalized XPath-based constraints in
the schema, of course.

Michael Kay
http://www.saxonica.com/

> -----Original Message-----
> From: xmlschema-dev-request@w3.org 
> [mailto:xmlschema-dev-request@w3.org] On Behalf Of Paul.V.Biron@kp.org
> Sent: 09 March 2006 16:37
> To: rjelliffe@allette.com.au
> Cc: ElektonikaMail@frink.w3.org; xml-dev@lists.xml.org; 
> xmlschema-dev@w3.org; xmlschema-dev-request@w3.org
> Subject: Re: [xml-dev] Two Questions - on XML Schema
> 
> 
> > Well, can I recommend just officialy recommending the  
> simple Schematron 
> 
> > assert statements as the easiest way forward for everyone, 
> using the 
> > schematron namespace, and inside <appinfo>
> 
> Rick, that is exactly what I have proposed, see [1], and one of the 
> options the WG is seriously considering.  I'm really 
> interested in your 
> reactions to my proposal.
> 
> pvb
> 
> [1] 
> http://lists.w3.org/Archives/Member/w3c-xml-schema-ig/2006Jan/
> 0137.html
> 
> 
> 






 

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

Copyright 2001 XML.org. This site is hosted by OASIS