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

Re: True or False: Every element has a type, even if none is specified

From: Mukul Gandhi <gandhi.mukul@gmail.com>
Date: Sat, 23 Jan 2016 09:14:14 +0530
Message-ID: <CABuuzNMou-Wzi=JMhcWqpRu5BsFYieonv9D5NDau6euo4N7tbA@mail.gmail.com>
To: "Costello, Roger L." <costello@mitre.org>
Cc: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>
Hi Roger,

On 21 January 2016 at 18:21, Costello, Roger L. <costello@mitre.org> wrote:

>
> For example, no type is specified in this element declaration:
>
>         <element name="E" />
>
> So it has the default type:
>
>    <element name="E">
>       <complexType mixed="true">
>          <sequence>
>             <any maxOccurs="unbounded" minOccurs="0"/>
>          </sequence>
>          <anyAttribute/>
>       </complexType>
>    </element>
>

I believe you're correct in saying this (if I recall correctly, this is
also stated in the XSD spec in some way). This is also equivalent to the
XSD type xs:anyType I think.


>
> Likewise, no type is specified in this attribute declaration:
>
>         <attribute name="A" />
>
> So it has the default type:
>
>         <attribute name="A" type="anySimpleType" />
>

That's correct also I think.


>
> Do you agree with this statement:
>
>         Every element has a type, even if none is specified;
>         if none is specified, then the element has the default type.
>

Yes of course this statement is correct. This is formally illustrated in
the above points as well.



-- 
Regards,
Mukul Gandhi
Received on Saturday, 23 January 2016 03:45:02 UTC

This archive was generated by hypermail 2.3.1 : Saturday, 23 January 2016 03:45:02 UTC