XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
extend two elements?

Hi,

I have an element called "grad_student" which extends "student". Now I want to extend "grad_address" element too since "grad_student" element needs address related info. Unfortunately I cannot merge address info from "grad_address" element into "grad_student" element. I am wondering how I can
extend another element when this element already extends a base element?

regards,

    <xsd:complexType name="grad_student">
<xsd:complexContent>
<xsd:extension base="student">
<xsd:attribute name="name" type="xsd:string" use="required"/>
<xsd:attribute name="grade" type="xsd:string" use="required"/>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:element name="grad_student" type="xyz:grad_student"/>

<xsd:complexType name="grad_address">
<xsd:complexContent>
<xsd:extension base="address">
<xsd:attribute name="state" type="xsd:string" use="required"/>
<xsd:attribute name="zip_code" type="xsd:string" use="required"/>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:element name="grad_address" type="xyz:grad_address"/>


Low, Low, Low Rates! Check out Yahoo! Messenger's cheap PC-to-Phone call rates.

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS