File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / libxml2 / test / schemas / src-element2-2_0.xsd
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Tue Feb 21 23:37:59 2012 UTC (12 years, 5 months ago) by misho
Branches: libxml2, MAIN
CVS tags: v2_9_1p0, v2_9_1, v2_8_0p0, v2_8_0, v2_7_8, HEAD
libxml2

<?xml version="1.0" encoding="ISO-8859-1" ?>
<!-- 3.2.3 : 2.2 
    If ref is present, then all of <complexType>, <simpleType>, <key>, <keyref>, <unique>, 
    nillable, default, fixed, form, block and type must be absent, i.e. only minOccurs, maxOccurs, 
    id are allowed in addition to ref, along with <annotation>.

-->
<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://foo" xmlns:foo="http://foo">
	
  <element name="bar" type="string"/>	
	
  <element name="foo">
  	  <complexType>
  	  	<choice>
  	  	
  	  		<!-- The good ones. -->
  	  		<element ref="foo:bar" minOccurs="0"/>
  	  		<element ref="foo:bar" maxOccurs="0"/>
  	  		<element ref="foo:bar" id="myomy"/>
  	  		
  	  		<!-- The bad ones. -->
  	  		<element ref="foo:bar">
  	  			<complexType>
  	  				<attribute name="bar" type="string"/>
  	  			</complexType>
  	  		</element>
  	  		
  	  		<element ref="foo:bar">
  	  			<simpleType>
  	  				<restriction base="string">
  	  					<maxLength value="20"/>
  	  				</restriction>
  	  			</simpleType>
  	  		</element>  
  	  		
  	  		<element ref="foo:bar" type="string"/>
  	  		<element ref="foo:bar" nillable="true"/>
  	  		<element ref="foo:bar" default="Joni"/>
  	  		<element ref="foo:bar" fixed="Mitchel"/>
  	  		<element ref="foo:bar" form="unqualified"/>
  	  		<element ref="foo:bar" block="restriction"/>  	  		
  	  		
  	  	</choice>
  	  </complexType>    
  </element>  
  

</schema>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>