W3C home > Mailing lists > Public > xmlschema-dev@w3.org > March 2005

Re: deriving mixed content types

From: Henry S. Thompson <ht@inf.ed.ac.uk>
Date: Wed, 16 Mar 2005 09:35:01 +0000
To: jbekaert@lanl.gov
Cc: xmlschema-dev@w3.org
Message-ID: <f5b1xagx7ay.fsf@erasmus.inf.ed.ac.uk>

"jeroen bekaert" <jbekaert@lanl.gov> writes:

> Derivation by extension can be used to append new content after the
> content of the base type; however - if not mistaken - the structure of the
> base type must be kept unchanged. As such, it is not possible to derive a
> mixed content model from an element-only content model (and vice versa).

Correct.

> The content type of the base type definition of SCHEMA 1 below is empty.
> Is it correct to derive (by extension) a content type 'mixed' of a base
> type definition with an empty content type?

Yes.

> Can someone point me to the clause of the W3C XML Schema spec
> confirming/forbidding the below extension constructs?

>From Schema Component Constraint: Derivation Valid (Extension) [1]

  1.4.3 All of the following must be true:
    1.4.3.1 The {content type} of the complex type definition itself
            must specify a particle.
    1.4.3.2 One of the following must be true:
      1.4.3.2.1 The {content type} of the {base type definition} must
                be _empty_.
      1.4.3.2.2 All of the following must be true:
        1.4.3.2.2.1 Both {content type}s must be _mixed_ or both must be
                    _element-only_.
        . . .

Hope this helps,

ht

[1] http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/structures.html#cos-ct-extends
-- 
 Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
                     Half-time member of W3C Team
    2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
            Fax: (44) 131 650-4587, e-mail: ht@inf.ed.ac.uk
                   URL: http://www.ltg.ed.ac.uk/~ht/
[mail really from me _always_ has this .sig -- mail without it is forged spam]
Received on Wednesday, 16 March 2005 09:35:06 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:49 GMT