Re: Partial type-assignment and ambiguous RELAX NG schema

On Tue, 21 Oct 2003 13:52:06 -0700
"Michael Rys" <mrys@microsoft.com> wrote:

> The data model should not allow xs:anyType as an instance type
> annotation since the instance should be a concrete type and not a
> general abstract type. However you can certainly use an (anonymous)
> union type...

You appear to disagree with Jonathan and Michael.  I thus think the data 
model spec needs some clarification about partial type-assignment.  Such 
clarification will also ensure that XQuery can be used for RELAX NG (and 
thus XHTML2 and RDF).

I plan to use non-deterministic path automata for partial type-assignment.  
My prototype can already generate a path automaton from the RNG schema shown 
in my previous mail.  This path automaton is non-deterministic: it cannot choose 
aWithOptB or aWithB.  Should I then use xs:anyType or the union of what?  (W3C XML 
Schema allows the union of simple types, but does it allow the union of complex types?)


<?xml version="1.0"?>
<pathAutomaton
	xmlns:rng="http://relaxng.org/ns/structure/1.0"
	start="#start"
	elementDeterministic="false"
	attributeDeterministic="true"
	simpleValueDeterministic="true">

<t s="#start" d="#anon0">
<rng:element>
  <rng:name ns="">root</rng:name>
</rng:element></t>
<t s="#anon0" d="#anon1">
<rng:element>
  <rng:name ns="">a</rng:name>
</rng:element></t>
<t s="#anon0" d="b">
<rng:element>
  <rng:name ns="">a</rng:name>
</rng:element></t>
<t s="#anon1" d="#anon2">
<rng:element>
  <rng:name ns="">b</rng:name>
</rng:element></t>
<t s="b" d="#anon2">
<rng:element>
  <rng:name ns="">b</rng:name>
</rng:element></t>
<t s="#anon2" d="#data">
<rng:data datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes" type="int"/></t>
</pathAutomaton>


Cheers,

-- 
MURATA Makoto (FAMILY Given) <EB2M-MRT@asahi-net.or.jp>

Received on Wednesday, 22 October 2003 11:01:42 UTC