﻿<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
	targetNamespace="http://www.standard-sitemap.org/version1beta/"
	xmlns="http://www.standard-sitemap.org/version1beta/"
	elementFormDefault="qualified" attributeFormDefault="unqualified">

	<xs:import schemaLocation="xml.xsd" namespace="http://www.w3.org/XML/1998/namespace"/>
	<!-- all possible element declarations -->

	<xs:element name="sitemap" type="sitemapType">
		<xs:annotation>
			<xs:documentation>(Root element)</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="style" type="styleType">
		<xs:annotation>
			<xs:documentation>
				Stylesheet to be loaded when sidebar/toolbar is shown
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="group" type="groupType">
		<xs:annotation>
			<xs:documentation>
				Frame/separator around its embedded objects. If name is
				given, we show it as a heading.
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="item" type="itemType">
		<xs:annotation>
			<xs:documentation>
				Entry in the pages' list
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="variant" type="variantType">
		<xs:annotation>
			<xs:documentation>
				As its superordinate &lt;group&gt; or &lt;item&gt;
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="external" type="groupType">
		<xs:annotation>
			<xs:documentation>
				Includes another sitemap file. Namely on the very place
				in the hierarchy at which the &lt;external&gt; element
				lives.
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:element name="externalsitemap" type="externalsitemapType">
		<xs:annotation>
			<xs:documentation>
				(Root element of a sub-sitemap)
			</xs:documentation>
		</xs:annotation>
	</xs:element>
	<!-- end of all possible element declarations -->

	<!-- all complexType declarations -->
	<xs:complexType name="sitemapType">
		<xs:sequence>
			<xs:choice minOccurs="0" maxOccurs="unbounded">
				<xs:element ref="style" />
			</xs:choice>
			<xs:choice>
				<xs:element ref="group" />
				<xs:element ref="item" />
			</xs:choice>
			<xs:choice minOccurs="0" maxOccurs="unbounded">
				<xs:element ref="group" />
				<xs:element ref="item" />
				<xs:element ref="external" />
			</xs:choice>
		</xs:sequence>
		<xs:attribute ref="xml:base" use="required">
			<xs:annotation>
				<xs:documentation>
					This URL is prefixed to all "url" declarations in
					subordinate elements. In case a sub element is
					located on another domain, the complete URL must be
					given. (In other words: Only if any "url"
					declaration is no complete URL, the xml:base is
					prefixed to it.)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="lang" type="xs:language">
			<xs:annotation>
				<xs:documentation>
					Language of the referenced object. Declaration
					according to RFC 4646
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="type" type="mimeType">
			<xs:annotation>
				<xs:documentation>
					MIME type of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/media-types/
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="charset" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Character set of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/character-sets (The
					character set of the sitemap file itself is declared
					in the very first line as an attribute of the XML
					prologue: encoding=&quot;utf-8&quot;)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="target" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Declaration of the target frame (for web sites using
					frame sets) target=&quot;_blank&quot; is not allowed
					(after all, the sitemap contains only site-internal
					links) – the users can decide on their own if they
					want a new window/tab :-)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>

	<xs:complexType name="styleType">
		<xs:complexContent>
			<xs:extension base="xs:anyType">
				<xs:attribute name="url" type="xs:anyURI"
					use="required">
					<xs:annotation>
						<xs:documentation>
							If this is no complete URL (e.g. "files/logo.gif"), 
							the xml:base will be prefixed. Anchors are allowed as URL’s.
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="type" type="mimeType"
					use="required">
					<xs:annotation>
						<xs:documentation>
							MIME type of the referenced object.
							Declaration according to
							http://www.iana.org/assignments/media-types/
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
			</xs:extension>
		</xs:complexContent>
	</xs:complexType>

	<xs:complexType name="groupType">
		<xs:choice maxOccurs="unbounded">
			<xs:element ref="group" />
			<xs:element ref="item" />
			<xs:element ref="variant" />
			<xs:element ref="external" />
		</xs:choice>
		<xs:attribute name="name" type="xs:string">
			<xs:annotation>
				<xs:documentation>
					Name which appears in the sidebar/toolbar
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="relation" type="relationType"
			default="none">
			<xs:annotation>
				<xs:documentation>
					This is used to declare a linear sequence of several
					pages (e.g. Bugzilla Guide). Allowed values are:

					* none (=default) * sequence. In this case, the
					previous/next arrows in the Firefox Extension
					(function bar) are shown.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="description" type="xs:string">
			<xs:annotation>
				<xs:documentation>
					Longer description which appears in the tooltip when
					user MouseOvers the object
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="priority" type="priorityType"
			default="0.5">
			<xs:annotation>
				<xs:documentation>
					Denotes the importance of an object, relative to the
					rest. Allowed values: number from 0.0 to 1.0,
					default is 0.5.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="target" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Declaration of the target frame (for web sites using
					frame sets) target=&quot;_blank&quot; is not allowed
					(after all, the sitemap contains only site-internal
					links) – the users can decide on their own if they
					want a new window/tab :-)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="lang" type="xs:language">
			<xs:annotation>
				<xs:documentation>
					Language of the referenced object. Declaration
					according to RFC 4646
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="type" type="mimeType">
			<xs:annotation>
				<xs:documentation>
					MIME type of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/media-types/
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute ref="xml:base">
			<xs:annotation>
				<xs:documentation>
					This URL is prefixed to all "url" declarations in
					subordinate elements. In case a sub element is
					located on another domain, the complete URL must be
					given. (In other words: Only if any "url"
					declaration is no complete URL, the xml:base is
					prefixed to it.)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="charset" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Character set of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/character-sets (The
					character set of the sitemap file itself is declared
					in the very first line as an attribute of the XML
					prologue: encoding=&quot;utf-8&quot;)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>

	<xs:complexType name="itemType">
		<xs:sequence minOccurs="0">
			<xs:sequence minOccurs="0">
				<xs:element ref="variant" minOccurs="2"
					maxOccurs="unbounded" />
			</xs:sequence>
			<xs:choice minOccurs="0" maxOccurs="unbounded">
				<xs:element ref="group" />
				<xs:element ref="item" />
				<xs:element ref="external" />
			</xs:choice>
		</xs:sequence>
		<xs:attribute name="url" type="xs:anyURI">
			<xs:annotation>
				<xs:documentation>
					If this is no complete URL (e.g. "files/logo.gif"), 
					the xml:base will be prefixed. Anchors are allowed as URL’s.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="name" type="xs:string">
			<xs:annotation>
				<xs:documentation>
					Name which appears in the sidebar/toolbar
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="description" type="xs:string">
			<xs:annotation>
				<xs:documentation>
					Longer description which appears in the tooltip when
					user MouseOvers the object
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="role" type="roleType">
			<xs:annotation>
				<xs:documentation>
					Causes the object to be displayed in the function
					bar, not in the normal hierarchy.

					If several function's are located on the same page,
					they have to be declared as anchors and entered
					separately into the sitemap. Allowed values:

					* contact

					* contentinfo: Central repository for all
					&quot;background&quot; information about the site,
					especially legal information like imprint, terms and
					conditions, privacy policy, etc.)

					* search: Use the website's own search script
					(instead of Google).

					Each of these role's may appear several times in the
					sitemap (e.g. if the site has multiple contact
					pages). In this case a sub-menu pops up (containing
					the name-attributes of the &lt;item&gt;'s) when the
					user clicks. We indicate this by showing the usual
					triangle symbol to the right of the icon
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="priority" type="priorityType"
			default="0.5">
			<xs:annotation>
				<xs:documentation>
					Denotes the importance of an object, relative to the
					rest. Allowed values: number from 0.0 to 1.0,
					default is 0.5.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="target" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Declaration of the target frame (for web sites using
					frame sets) target=&quot;_blank&quot; is not allowed
					(after all, the sitemap contains only site-internal
					links) – the users can decide on their own if they
					want a new window/tab :-)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="lang" type="xs:language">
			<xs:annotation>
				<xs:documentation>
					Language of the referenced object. Declaration
					according to RFC 4646
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="type" type="mimeType">
			<xs:annotation>
				<xs:documentation>
					MIME type of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/media-types/
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute ref="xml:base">
			<xs:annotation>
				<xs:documentation>
					This URL is prefixed to all "url" declarations in
					subordinate elements. In case a sub element is
					located on another domain, the complete URL must be
					given. (In other words: Only if any "url"
					declaration is no complete URL, the xml:base is
					prefixed to it.)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="charset" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Character set of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/character-sets (The
					character set of the sitemap file itself is declared
					in the very first line as an attribute of the XML
					prologue: encoding=&quot;utf-8&quot;)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="method" type="methodType" default="get">
			<xs:annotation>
				<xs:documentation>
					Only allowed if role="search". Method to be used to
					send the user's search request to the server.
					Allowed values: get (=default) post
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="data" type="xs:string">
			<xs:annotation>
				<xs:documentation>
					Only allowed if role="search". Data to be sent to
					the server when the user submits a search request
					using the searchbox in our sidebar. Use %s as a
					placeholder for the user's search term.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>

	<xs:complexType name="variantType">
		<xs:complexContent>
			<xs:extension base="xs:anyType">
				<xs:attribute name="url" type="xs:anyURI">
					<xs:annotation>
						<xs:documentation>
							If this is no complete URL (e.g. "files/logo.gif"), 
							the xml:base will be prefixed. Anchors are allowed as URL’s.
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="name" type="xs:string">
					<xs:annotation>
						<xs:documentation>
							Name which appears in the sidebar/toolbar
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="description" type="xs:string">
					<xs:annotation>
						<xs:documentation>
							Longer description which appears in the
							tooltip when user MouseOvers the object
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="lang" type="xs:language">
					<xs:annotation>
						<xs:documentation>
							Language of the referenced object.
							Declaration according to RFC 4646
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="type" type="mimeType">
					<xs:annotation>
						<xs:documentation>
							MIME type of the referenced object.
							Declaration according to
							http://www.iana.org/assignments/media-types/
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="charset" type="xs:token">
					<xs:annotation>
						<xs:documentation>
							Character set of the referenced object.
							Declaration according to
							http://www.iana.org/assignments/character-sets
							(The character set of the sitemap file
							itself is declared in the very first line as
							an attribute of the XML prologue:
							encoding=&quot;utf-8&quot;)
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="data" type="xs:string">
					<xs:annotation>
						<xs:documentation>
							Only allowed if role="search". Data to be
							sent to the server when the user submits a
							search request using the searchbox in our
							sidebar. Use %s as a placeholder for the
							user's search term.
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<!-- <xs:attributeGroup ref="dimension" /> -->
			</xs:extension>
		</xs:complexContent>
	</xs:complexType>

	<xs:complexType name="externalType">
		<xs:complexContent>
			<xs:extension base="xs:anyType">
				<xs:attribute name="url" type="xs:anyURI"
					use="required">
					<xs:annotation>
						<xs:documentation>
							If this is no complete URL (e.g. "files/logo.gif"), 
							the xml:base will be prefixed. Anchors are allowed as URL’s.
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute ref="xml:base">
			<xs:annotation>
				<xs:documentation>
					This URL is prefixed to all "url" declarations in
					subordinate elements. In case a sub element is
					located on another domain, the complete URL must be
					given. (In other words: Only if any "url"
					declaration is no complete URL, the xml:base is
					prefixed to it.)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
				<xs:attribute name="lang" type="xs:language">
					<xs:annotation>
						<xs:documentation>
							Language of the referenced object.
							Declaration according to RFC 4646
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="type" type="mimeType">
					<xs:annotation>
						<xs:documentation>
							MIME type of the referenced object.
							Declaration according to
							http://www.iana.org/assignments/media-types/
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="charset" type="xs:token">
					<xs:annotation>
						<xs:documentation>
							Character set of the referenced object.
							Declaration according to
							http://www.iana.org/assignments/character-sets
							(The character set of the sitemap file
							itself is declared in the very first line as
							an attribute of the XML prologue:
							encoding=&quot;utf-8&quot;)
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="priority" type="priorityType"
					default="0.5">
					<xs:annotation>
						<xs:documentation>
							Denotes the importance of an object,
							relative to the rest. Allowed values: number
							from 0.0 to 1.0, default is 0.5.
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
				<xs:attribute name="target" type="xs:token">
					<xs:annotation>
						<xs:documentation>
							Declaration of the target frame (for web
							sites using frame sets)
							target=&quot;_blank&quot; is not allowed
							(after all, the sitemap contains only
							site-internal links) – the users can decide
							on their own if they want a new window/tab
							:-)
						</xs:documentation>
					</xs:annotation>
				</xs:attribute>
			</xs:extension>
		</xs:complexContent>
	</xs:complexType>

	<xs:complexType name="externalsitemapType">
		<xs:choice maxOccurs="unbounded">
			<xs:element ref="group"></xs:element>
			<xs:element ref="item"></xs:element>
			<xs:element ref="variant"></xs:element>
			<xs:element ref="external"></xs:element>
		</xs:choice>
		<xs:attribute ref="xml:base">
			<xs:annotation>
				<xs:documentation>
					This URL is prefixed to all "url" declarations in
					subordinate elements. In case a sub element is
					located on another domain, the complete URL must be
					given. (In other words: Only if any "url"
					declaration is no complete URL, the xml:base is
					prefixed to it.)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="lang" type="xs:language">
			<xs:annotation>
				<xs:documentation>
					Language of the referenced object. Declaration
					according to RFC 4646
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="type" type="mimeType">
			<xs:annotation>
				<xs:documentation>
					MIME type of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/media-types/
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="charset" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Character set of the referenced object. Declaration
					according to
					http://www.iana.org/assignments/character-sets (The
					character set of the sitemap file itself is declared
					in the very first line as an attribute of the XML
					prologue: encoding=&quot;utf-8&quot;)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="target" type="xs:token">
			<xs:annotation>
				<xs:documentation>
					Declaration of the target frame (for web sites using
					frame sets) target=&quot;_blank&quot; is not allowed
					(after all, the sitemap contains only site-internal
					links) – the users can decide on their own if they
					want a new window/tab :-)
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>
	<!-- end of all complexType declarations -->

	<!-- all named simple Type declarations -->
	<xs:simpleType name="mimeType">
		<xs:restriction base="xs:string">
			<xs:pattern
				value="(application|audio|example|image|message|model|multipart|text|video)/[a-zA-Z0-9._+-]+" />
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="relationType">
		<xs:restriction base="xs:token">
			<xs:enumeration value="none" />
			<xs:enumeration value="sequence" />
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="priorityType">
		<xs:restriction base="xs:decimal">
			<xs:minInclusive value="0" />
			<xs:maxInclusive value="1" />
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="roleType">
		<xs:restriction base="xs:token">
			<xs:enumeration value="contact" />
			<xs:enumeration value="contentinfo" />
			<xs:enumeration value="search" />
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="methodType">
		<xs:restriction base="xs:token">
			<xs:enumeration value="get" />
			<xs:enumeration value="post" />
		</xs:restriction>
	</xs:simpleType>
	<!-- end of all named simple Type declarations -->

</xs:schema>
