<?xml version="1.0" encoding="UTF-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:base="urn:x-inspire:specification:gmlas:BaseTypes:3.2" xmlns:bu-base="http://inspire.ec.europa.eu/schemas/bu/3.0rc2" xmlns:bu-core2d="http://inspire.ec.europa.eu/schemas/bu-core2d/3.0rc2" xmlns:gml="http://www.opengis.net/gml/3.2" targetNamespace="http://inspire.ec.europa.eu/schemas/bu-core2d/3.0rc2" elementFormDefault="qualified" version="3.0rc2">
	<annotation>
		<documentation>-- Definition --
The core 2D application schema for INSPIRE theme building.</documentation>
	</annotation>
	<import namespace="http://inspire.ec.europa.eu/schemas/bu/3.0rc2" schemaLocation="http://inspire.ec.europa.eu/draft-schemas/bu-base/3.0rc2/BuildingsBase.xsd"/>
	<import namespace="http://www.opengis.net/gml/3.2" schemaLocation="http://schemas.opengis.net/gml/3.2.1/gml.xsd"/>
	<import namespace="urn:x-inspire:specification:gmlas:BaseTypes:3.2" schemaLocation="http://inspire.ec.europa.eu/schemas/base/3.2/BaseTypes.xsd"/>
	<!--XML Schema document created by ShapeChange-->
	<element name="Building" type="bu-core2d:BuildingType" substitutionGroup="bu-core2d:AbstractBuilding">
		<annotation>
			<documentation>-- Definition --
A Building is an enclosed &lt;b&gt;construction &lt;/b&gt;above and/or underground, used or intended for the shelter of humans, animals or things or for the production of economic goods. A building refers to any structure permanently constructed or erected on its site.</documentation>
		</annotation>
	</element>
	<complexType name="BuildingType">
		<complexContent>
			<extension base="bu-core2d:AbstractBuildingType">
				<sequence>
					<element name="parts" nillable="true" minOccurs="0" maxOccurs="unbounded">
						<annotation>
							<documentation>-- Definition --
The building parts composing the Building.
-- Description --
A building may be a simple building (with no BuildingPart) or a composed building (with several BuildingParts).</documentation>
						</annotation>
						<complexType>
							<complexContent>
								<extension base="gml:AbstractMemberType">
									<sequence minOccurs="0">
										<element ref="bu-core2d:BuildingPart"/>
									</sequence>
									<attributeGroup ref="gml:AssociationAttributeGroup"/>
								</extension>
							</complexContent>
						</complexType>
					</element>
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	<complexType name="BuildingPropertyType">
		<sequence minOccurs="0">
			<element ref="bu-core2d:Building"/>
		</sequence>
		<attributeGroup ref="gml:AssociationAttributeGroup"/>
		<attributeGroup ref="gml:OwnershipAttributeGroup"/>
	</complexType>
	<element name="BuildingPart" type="bu-core2d:BuildingPartType" substitutionGroup="bu-core2d:AbstractBuilding">
		<annotation>
			<documentation>-- Definition --
A BuildingPart is a sub-division of a Building that might be considered itself as a building.

-- Description --
NOTE 1: A BuildingPart is homogeneous related to its physical, functional or temporal aspects. 

NOTE 2: Building and BuildingPart share the same set of properties.
EXAMPLE: A Building may be composed of two BuildingParts having different heights above ground.</documentation>
		</annotation>
	</element>
	<complexType name="BuildingPartType">
		<complexContent>
			<extension base="bu-core2d:AbstractBuildingType">
				<sequence/>
			</extension>
		</complexContent>
	</complexType>
	<complexType name="BuildingPartPropertyType">
		<sequence minOccurs="0">
			<element ref="bu-core2d:BuildingPart"/>
		</sequence>
		<attributeGroup ref="gml:AssociationAttributeGroup"/>
		<attributeGroup ref="gml:OwnershipAttributeGroup"/>
	</complexType>
	<element name="AbstractBuilding" type="bu-core2d:AbstractBuildingType" abstract="true" substitutionGroup="bu-base:AbstractBuilding">
		<annotation>
			<documentation>-- Definition --
Abstract feature type grouping the common properties of instanciable feature types Building and BuildingPart.

-- Description --
In core 2D application schema, feature type AbstractBuilding includes both the common semantic properties of Building and BuildingPart (by inheritance from feature type AbstractBuilding of base application schema) and the common geometric properties of Building and BuildingPart.</documentation>
		</annotation>
	</element>
	<complexType name="AbstractBuildingType" abstract="true">
		<complexContent>
			<extension base="bu-base:AbstractBuildingType">
				<sequence>
					<element name="geometry2D" type="bu-base:BuildingGeometry2DPropertyType" maxOccurs="unbounded">
						<annotation>
							<documentation>-- Definition --
&lt;font color="#0f0f0f"&gt;Geometric representation of the building, as 2D or 2,5D data.&lt;/font&gt;
&lt;font color="#0f0f0f"&gt;-- Description --&lt;/font&gt;
&lt;font color="#0f0f0f"&gt;NOTE: Multiple representations of the geometry are possible (e.g. by surface and by point).&lt;/font&gt;</documentation>
						</annotation>
					</element>
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	<complexType name="AbstractBuildingPropertyType">
		<sequence minOccurs="0">
			<element ref="bu-core2d:AbstractBuilding"/>
		</sequence>
		<attributeGroup ref="gml:AssociationAttributeGroup"/>
		<attributeGroup ref="gml:OwnershipAttributeGroup"/>
	</complexType>
</schema>
