<?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:include schemaLocation="inc-scheme_3-1.xsd"/>
	<xs:import namespace="http://www.w3.org/1999/xhtml" schemaLocation="xhtml_strict_1-0.xsd"/>
	<xs:annotation>
		<xs:appinfo>ipc_compilation_3-1.xsd</xs:appinfo>
	</xs:annotation>
	<xs:annotation>
		<xs:documentation>
			<h1>IPC Compilation File</h1>
		</xs:documentation>
	</xs:annotation>
	<xs:element name="IPCCompilation" type="IPCCompilation"/>
	<xs:complexType name="IPCCompilation">
		<xs:annotation>
			<xs:documentation>
				<div>a flat list of new, modified or deleted ipcEntry-s</div>
				<div>ipcEntry elements are not embedded, i.e. section/class/subclass/maingroup/dot 1 etc. hierarchy is not reflected by the inclusion of ipcEntry elements</div>
			</xs:documentation>
		</xs:annotation>
		<xs:sequence>
			<xs:element name="ipcEntryChange" type="compilationIpcEntry" minOccurs="1" maxOccurs="unbounded">
				<xs:annotation>
					<xs:documentation>
						<div>modified, new or deleted IPC entries</div>
					</xs:documentation>
				</xs:annotation>
			</xs:element>
		</xs:sequence>
		<xs:attribute name="edition" type="edition" use="required"/>
		<xs:attribute name="lang" type="lang" use="required"/>
	</xs:complexType>
	<xs:complexType name="compilationIpcEntry">
		<xs:annotation>
			<xs:documentation>
				<div>representation of the modified, new or deleted IPC entry, either structured and non-structured entry</div>
				<div>For the purpose of comparison, the <u>text</u> of IPC entries is 'flattened'.</div>
				<div>IPC entries in compilation files are not embedded into their hierarchy as reflected in the scheme.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:choice minOccurs="0">
			<xs:element name="textBodyChange" type="xhtmlBlock"/>
			<xs:element name="transferredTo" type="transferredTo"/>
		</xs:choice>
		<xs:attributeGroup ref="compilationEntryAttributes"/>
	</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="transferredTo">
		<xs:annotation>
			<xs:documentation>
				<div>the subject matter of the symbol to be deleted is transferred to a new symbol, i.e. references should point to new symbols</div>
			</xs:documentation>
		</xs:annotation>
		<xs:choice maxOccurs="unbounded">
			<xs:element name="sref" type="sref">
				<xs:annotation>
					<xs:documentation>
						<div>the referred reference should be a new symbol</div>
					</xs:documentation>
				</xs:annotation>
			</xs:element>
			<xs:element name="mref" type="mref">
				<xs:annotation>
					<xs:documentation>
						<div>all the references within the interval should be new symbols</div>
					</xs:documentation>
				</xs:annotation>
			</xs:element>
		</xs:choice>
	</xs:complexType>
	<xs:attributeGroup name="compilationEntryAttributes">
		<xs:attributeGroup ref="ipcEntryAttributes"/>
		<xs:attribute name="amendmentType" type="amendmentType" use="required">
			<xs:annotation>
				<xs:documentation>
					<div>type of amendment</div>
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="isDead" type="yesno" default="N">
			<xs:annotation>
				<xs:documentation>
					<div>text-less entry for history</div>
					<div>Used for the purpose of marking deleted notes and guidance headings, as used in compilation files and prereform versions.</div>
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="structChangeFrom" type="ipcEntryKind">
			<xs:annotation>
				<xs:documentation>
					<div>former type of IPC entry, e.g. 'm' for maingroup</div>
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
	</xs:attributeGroup>
	<xs:simpleType name="amendmentType">
		<xs:annotation>
			<xs:documentation>
				<div>Type of the amendment.</div>
			</xs:documentation>
		</xs:annotation>
		<xs:restriction base="xs:NMTOKEN">
			<xs:enumeration value="N">
				<xs:annotation>
					<xs:documentation>for new entries</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="D">
				<xs:annotation>
					<xs:documentation>for deleted entries</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="U">
				<xs:annotation>
					<xs:documentation>or entries that remain unchanged, but are displayed to improve the readability of the proposal</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="M">
				<xs:annotation>
					<xs:documentation>for entries where changes do not impact the file scope, and do not require reclassification</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="C">
				<xs:annotation>
					<xs:documentation>for entries with modified file scope and serving as source entries for reclassification</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="T">
				<xs:annotation>
					<xs:documentation>For entries with modified file scope, but not serving as source entries for reclassification, i.e. target entries</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
			<xs:enumeration value="L">
				<xs:annotation>
					<xs:documentation>for entries which remain unchanged only in one of the two authentic languages of the IPC while the other authentic language is modified and marked as “M”</xs:documentation>
				</xs:annotation>
			</xs:enumeration>
		</xs:restriction>
	</xs:simpleType>
</xs:schema>
