Re: combine

From
James Clark <>
Date
2001-05-22T03:39:20+00:00
ID
051501c0e270$73ed25f0$
Thread
Re: combine
> >In other words, deriving from Address changes what is allowed by a
reference
> >to Address.
>
> This is true, but can be easily mimicked as below.  Basically, we only
have
> to introduce another named pattern.

That's a nice trick.  This does require the author of the invoice schema to
have the foresight to introduce the double indirection
Address/AddressForReference.  On the other hand, even combine="group"
requires the author to have the foresight to introduce the Address
definition.

> >allow a postCode. Derivation by extension in XML Schema supports this.
In
> >RELAX NG, combine="group" provides similar functionality.
>
> You have overshadowed the original definition of "Address"; in other
words,  postCode
> has become mandatory in your example.  I think that this is very different
from
> what people would expect.

I don't think anybody would be surprised that:

  <define name="Address" combine="group">
   ...
  </define>

overshadows the original definition of Address.

James