<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.wipo.int/classifications/ipc/masterfiles" xmlns:xhtml="http://www.w3.org/1999/xhtml" targetNamespace="http://www.wipo.int/classifications/ipc/masterfiles" elementFormDefault="qualified">
	<xs:include schemaLocation="inc-types_3-1.xsd"/>
	<xs:import namespace="http://www.w3.org/1999/xhtml" schemaLocation="xhtml_strict_1-0.xsd"/>
	<xs:annotation>
		<xs:appinfo>ipc_definitions_3-1.xsd</xs:appinfo>
	</xs:annotation>
	<xs:annotation>
		<xs:documentation>
			<h1>IPC Definitions Master File</h1>
		</xs:documentation>
	</xs:annotation>
	<xs:element name="IPCDefinitions" type="IPCDefinitions"/>
	<xs:complexType name="IPCDefinitions">
		<xs:annotation>
			<xs:documentation>
				<div>definitions in one language, for a certain version and language</div>
			</xs:documentation>
		</xs:annotation>
		<xs:choice minOccurs="0" maxOccurs="unbounded">
			<xs:element name="IPCDefinitionsSection" type="IPCDefinitionsSection" maxOccurs="unbounded"/>
			<xs:element name="IPC-DEFINITION" type="IPC-DEFINITION"/>
		</xs:choice>
		<xs:attribute name="edition" type="edition" use="required">
			<xs:annotation>
				<xs:documentation>
					<div>edition of IPC to which these definitions belong</div>
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="lang" type="lang" use="required">
			<xs:annotation>
				<xs:documentation>
					<div>Language of the definitions</div>
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>
	<xs:complexType name="IPCDefinitionsSection">
		<xs:annotation>
			<xs:documentation>
				<div>hierarchical element for storing definitions related to a section</div>
				<div>Sections do not have definitions</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="IPCDefinitionsClass" type="IPCDefinitionsClass" maxOccurs="unbounded"/>
		</xs:sequence>
		<xs:attribute name="symbol" type="section" use="required"/>
	</xs:complexType>
	<xs:complexType name="IPCDefinitionsClass">
		<xs:annotation>
			<xs:documentation>
				<div>hierarchical element for storing definitions related to a class</div>
				<div>Classses may have definitions.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="IPC-DEFINITION" type="IPC-DEFINITION" minOccurs="0"/>
			<xs:element name="IPCDefinitionsSubclass" type="IPCDefinitionsSubclass" minOccurs="0" maxOccurs="unbounded"/>
		</xs:sequence>
		<xs:attribute name="symbol" type="class" use="required"/>
	</xs:complexType>
	<xs:complexType name="IPCDefinitionsSubclass">
		<xs:annotation>
			<xs:documentation>
				<div>hierarchical element for storing definitions related to a subclass.</div>
				<div>A IPCDefinitionsSubclass usually has definitions, and can contain definitions for (some of) its maingroups, stored under the IPCDefinitionsMaingroup elements.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="IPC-DEFINITION" type="IPC-DEFINITION" minOccurs="0"/>
			<xs:element name="IPCDefinitionsMaingroup" type="IPCDefinitionsMaingroup" minOccurs="0" maxOccurs="unbounded"/>
		</xs:sequence>
		<xs:attribute name="symbol" type="subclass" use="required"/>
	</xs:complexType>
	<xs:complexType name="IPCDefinitionsMaingroup">
		<xs:annotation>
			<xs:documentation>
				<div>hierarchical element for storing definitions related to a maingroup.</div>
				<div>While it is not mandatory to have definition for the main group, embedded subgroups may have their own definition.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="IPC-DEFINITION" type="IPC-DEFINITION" minOccurs="0"/>
			<xs:element name="IPCDefinitionsGroup" type="IPCDefinitionsGroup" minOccurs="0" maxOccurs="unbounded">
				<xs:annotation>
					<xs:documentation>flat list of subgroups</xs:documentation>
				</xs:annotation>
			</xs:element>
		</xs:sequence>
		<xs:attribute name="symbol" type="symbol" use="required"/>
	</xs:complexType>
	<xs:complexType name="IPCDefinitionsGroup">
		<xs:annotation>
			<xs:documentation>
				<div>wrapper of the definition of the group</div>
				<div>A subgroup must have exactly one definition.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="IPC-DEFINITION" type="IPC-DEFINITION" minOccurs="1" maxOccurs="1"/>
		</xs:sequence>
		<xs:attribute name="symbol" type="symbol" use="required"/>
	</xs:complexType>
	<xs:complexType name="IPC-DEFINITION">
		<xs:annotation>
			<xs:documentation>
				<div>an independent IPC definition</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="DEFINITION-STATEMENT" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="LARGESUBJECTS" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="REFERENCES" type="referenceTables" minOccurs="0"/>
			<xs:element name="SPECIALRULES" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="GLOSSARYOFTERMS" type="xhtmlDL" minOccurs="0"/>
			<xs:element name="SYNONYMSANDKEYWORDS" type="SYNONYMSANDKEYWORDS" minOccurs="0"/>
		</xs:sequence>
		<xs:attribute name="IPC" type="symbol" use="optional">
			<xs:annotation>
				<xs:documentation>non-specified symbol denotes IPC-wide, global definitions (terms)</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:complexType>
	<xs:complexType name="referenceTables">
		<xs:annotation>
			<xs:documentation>
				<div>one or more reference tables</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="LIMITINGREFERENCES" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="APPLICATIONORIENTEDREFERENCES" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="REFERENCESOUTOFARESIDUALPLACE" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="INFORMATIVEREFERENCES" type="xhtmlBlock" minOccurs="0"/>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="SYNONYMSANDKEYWORDS">
		<xs:annotation>
			<xs:documentation>
				<div>synonyms and keywords often used in patent documents</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="ABBREVIATIONS" type="xhtmlDL" minOccurs="0"/>
			<xs:element name="SYNONYMS" type="xhtmlBlock" minOccurs="0"/>
			<xs:element name="INSTEADOFWORDS" type="xhtmlDL" minOccurs="0"/>
			<xs:element name="SPECIALMEANINGS" type="xhtmlDL" minOccurs="0"/>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="xhtmlBlock">
		<xs:annotation>
			<xs:documentation>
				<div>Standard XHTML block type of content</div>
			</xs:documentation>
		</xs:annotation>
		<xs:group ref="xhtml:block"/>
	</xs:complexType>
	<xs:complexType name="xhtmlTable">
		<xs:annotation>
			<xs:documentation>
				<div>Standard XHTML table</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element ref="xhtml:table"/>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="xhtmlUL">
		<xs:annotation>
			<xs:documentation>
				<div>Standard XHTML unordered list</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element ref="xhtml:ul"/>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="xhtmlDL">
		<xs:annotation>
			<xs:documentation>
				<div>Standard XHTML definition list</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element ref="xhtml:dl"/>
		</xs:sequence>
	</xs:complexType>
</xs:schema>
