Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - XML Schema never-never occurence of declared elements / attributes [Thread Next] Re: XML Schema never-never occurence of declared elements / attributesTo: NULL Date: 12/1/2005 1:28:00 PM Soren Kuula writes:
Given this (corrected) type definition
<complexType name="fattype">
<sequence>
<element name="bar" minOccurs="0" maxOccurs="342"/>
</sequence>
<attribute name="shanyang"/>
</complexType>
The non-misleading restriction you want is
<element name="thinfoo">
<complexType>
<complexContent>
<restriction base="fattype">
<attribute name="shanyang" use="prohibited"/>
</restriction>
</complexContent>
</complexType>
</element>
This is of course an element useful only as an illustration, as it
must always be empty, with no attributes.
ht
--
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@i...
URL: http://www.ltg.ed.ac.uk/~ht/
[mail really from me _always_ has this .sig -- mail without it is forged spam]
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
