W3C home > Mailing lists > Public > xmlschema-dev@w3.org > January 2001

RE: redefinition errors

From: <MarkH@i2.co.uk>
Date: Wed, 10 Jan 2001 12:15:44 -0000
Message-ID: <1E73B637CFC3D411A12F00B0D0795DDD091497@uknts40exh01.i2.co.uk>
To: ht@cogsci.ed.ac.uk
Cc: xmlschema-dev@w3.org

> -----Original Message-----
> From: ht@cogsci.ed.ac.uk [mailto:ht@cogsci.ed.ac.uk]
> Forget that, then.  In the XML Schema context, here's the relevant
> text [1]:
>   "If the {particles} [of a model group] contains, either directly,
>   indirectly (that is, within the {particles} of a contained model
>   group, recursively) or implicitly two or more element declaration
>   particles with the same {name} and {target namespace}, all their
>   {type definition}s must be the same."
> A model group is (the schema component corresponding to) a <choice>,
> <all> or <sequence>.
> Hope this helps
Yes, thanks. And that appears to rule it out throughout a document since all
elements in a document will always share a common model group at the top of
the hierarchy?

On my travels I read the bit about the scope under "definition of an
element" [2] - which indeed says that the scope is indeed a content model.
If you then look up content model you find that

   A particle can be used in a complex type definition to constrain the 
   validation of the [children] of an element information item; such a 
   particle is called a content model. [3] 

And you'll be under the impression that the scope can be restricted to allow
multiple elements with same name, different type, so long as the scope is
restricted to a "particle" (such as <sequence>).

And then (with Henry's help) you find the restriction which precludes this

Life is full of disappointments that make it interesting!! :-)

Mark Hughes
  Agile HTML Editor

PS ht - intelligence not insulted - in tact and whirring away along with
good humour. have a brill day!

[1] http://www.w3.org/TR/xmlschema-1/#cos-element-consistent
[2] http://www.w3.org/TR/xmlschema-1/#Element_Declaration_details
[3] http://www.w3.org/TR/xmlschema-1/#key-contentModel)
Received on Wednesday, 10 January 2001 07:22:51 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:14:49 UTC