<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">

	<xs:annotation>
    	<xs:documentation>
      		This schema describes a format for describing a tag-cloud in the openSUSE build
      		service.
    	</xs:documentation>
 	</xs:annotation>

	<xs:attribute default="6" name="steps" type="xs:nonNegativeInteger"/> 
	<xs:attribute name="size" type="xs:nonNegativeInteger"/>
	<xs:attribute name="count" type="xs:nonNegativeInteger"/> 
	<xs:attribute name="name" type="xs:string"/>
	<xs:attribute name="distribution_method" type="xs:string"/> 
	<xs:attribute name="user" type="xs:string"/> 
	
	
	<xs:element name="tag">
		<xs:complexType>
		<xs:attribute ref="name" use="required"/>
		<xs:attribute ref="count"/>
		<xs:attribute ref="size"/>
		</xs:complexType>
	</xs:element>
	
	
	<xs:element name="tagcloud">
		<xs:annotation>
      		<xs:documentation>
        		Top level element for tagcloud data.
      		</xs:documentation>
      	</xs:annotation>	
		<xs:complexType>	
			<xs:sequence>
				<xs:element maxOccurs="unbounded" minOccurs="0" ref="tag"/>
			</xs:sequence>	
			
			<xs:attribute ref="user" use="required"/>
			
			<xs:attribute ref="steps"/>

			<xs:attribute ref="distribution_method"/>	

		</xs:complexType>
	</xs:element>				


</xs:schema>
