W3C home > Mailing lists > Public > xmlschema-dev@w3.org > June 2006

Extension of xs:anyType

From: Pete Cordell <petexmldev@tech-know-ware.com>
Date: Thu, 1 Jun 2006 10:43:16 +0100
Message-ID: <001201c6855f$efcf10b0$0600a8c0@RW>
To: <xmlschema-dev@w3.org>

I've been looking at the HL7 schema and I see that a type is defined to be 
an extension of an xs:anyType, as shown below...

 <xsd:complexType name="varies">
  <xsd:complexContent>
   <xsd:extension base="xsd:anyType"/>
  </xsd:complexContent>
 </xsd:complexType>

This type is then used in the following situation...

  <xsd:complexType name="MFA.5.CONTENT">
    <xsd:complexContent>
      <xsd:extension base="varies">
        <xsd:attributeGroup ref="MFA.5.ATTRIBUTES"/>
      </xsd:extension>
    </xsd:complexContent>
  </xsd:complexType>

What sorts of XML instances does this map to?  Also, what would you expect 
(in an ideal world!) a data binding tool to do in this context?

I notice that the uses only add attributes.  Could the construct also have 
elements added to it?

Is there a section of the spec I should look at to describe this?

Thanks for any explanations.  (Apologies if this is an FAQ!)

Pete.
--
=============================================
Pete Cordell
Tech-Know-Ware Ltd
                         for XML to C++ data binding visit
                         http://www.tech-know-ware.com/lmx
                         (or http://www.xml2cpp.com)
=============================================
Received on Thursday, 1 June 2006 09:44:25 GMT

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