Next in thread → Next in month →

Re: [relax-ng] attribute constraint

From
James Clark <>
Date
2001-11-15T12:31:11+00:00
ID
533190106.1005813635@localhost
Thread
Re: [relax-ng] attribute constraint
Murata-san and myself recently had a meeting with Hosoya-san, where he gave 
a crisp rationale for this restriction: without the restriction RELAX NG 
would not be closed under negation.  Consider the pattern

<attribute>
  <anyName/>
</attribute>

The negation of this would be

<optional>
  <group>
    <attribute>
      <anyName/>
    </attribute>
    <attribute>
      <anyName/>
    </attribute>
  </group>
</optional>

But this is not legal because it violates the restriction on duplicate 
attributes.

--On 16 October 2001 08:33 +0900 Murata Makoto <> 
wrote:

>
>>
>> There's a related possible restriction, which is what I thought
>> Murata-san  was proposing: if an <attribute> occurs in a <oneOrMore>,
>> then its first  child must be <nsName> or <anyName>.  That would have
>> the disadvantage of  disallowing the
>
> Actually, in Hosoya-san's normalization, <attribute> is always normalized
> to <attribute>  within <oneOrMore>.  For example,
>
> <element name="foo">
>   <attribute name="bar"><text/></attribute>
> </element>
>
> is normalized into
>
> <element name="foo">
>   <oneOrMore>
>     <attribute name="bar"><text/></attribute>
>   </oneOrMore>
> </element>
>
> It is this normalization that makes subsumption checking possible.
>
> Cheers,
>
> Makoto
>
> ----------------------------------------------------------------
> To subscribe or unsubscribe from this elist use the subscription
> manager: <http://lists.oasis-open.org/ob/adm.pl>
>
>
>
Next in thread → Next in month →