<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSPY v2004 rel. 4 U (http://www.xmlspy.com) by Yi Wang (London Borough of Camden) -->
<xsd:schema targetNamespace="http://www.homeconnections.gov.uk" elementFormDefault="qualified" attributeFormDefault="unqualified" version="0.1" id="PropertyAllocations" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.homeconnections.gov.uk">
	<!--XML Schema for Property Allocation (Sub Region Report)-->
	<xsd:annotation>
		<xsd:appinfo>
			<xsd:KeyWords>choice based letting, CBL, property, rent, points, address, registered individual				</xsd:KeyWords>
		</xsd:appinfo>
	</xsd:annotation>
	<!--
CBL - Choice Based Letting Pilot called 'Home Connections' : One of several DTLR funded pilots to provide user choice in the social housing arena.
XML Architecture Schema for Properties Allocation
Purpose: This schema is used to supply the CBL property allocation structures to architecture and message
schemas used throughout the sub-region schema structures.
Heritage: this and related schema are loosely based on the CECA XML Schema published on govtalk
Date: 25/02/2005
Version: 0.1
Editor: Yi Wang, Home Connections
-->
	<xsd:simpleType name="AddressPostCodeAreaType">
		<xsd:restriction base="xsd:string">
			<xsd:pattern value="[A-Z]{1,2}[0-9R][0-9A-Z]"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="AddressPostCodeStreetType">
		<xsd:restriction base="xsd:string">
			<xsd:pattern value="[0-9][A-Z]{2}"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="CBLAddressStreetNumberType">
		<xsd:restriction base="xsd:string">
			<xsd:maxLength value="10"/>
			<xsd:minLength value="1"/>
			<xsd:whiteSpace value="preserve"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="CBLAddressRoadType">
		<xsd:restriction base="xsd:string">
			<xsd:maxLength value="100"/>
			<xsd:minLength value="1"/>
			<xsd:whiteSpace value="preserve"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="CBLAddressNeighbourhoodType">
		<xsd:restriction base="xsd:string">
			<xsd:maxLength value="40"/>
			<xsd:minLength value="1"/>
			<xsd:whiteSpace value="preserve"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="CBLAddressTownType">
		<xsd:restriction base="xsd:string">
			<xsd:maxLength value="40"/>
			<xsd:minLength value="1"/>
			<xsd:whiteSpace value="preserve"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:simpleType name="CBLAddressCountyType">
		<xsd:restriction base="xsd:string">
			<xsd:maxLength value="30"/>
			<xsd:minLength value="1"/>
			<xsd:whiteSpace value="preserve"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:complexType name="CBLAddressStructure">
		<xsd:sequence>
			<xsd:element name="StreetNo" type="CBLAddressStreetNumberType" minOccurs="0"/>
			<xsd:element name="SubStreetNo" type="CBLAddressStreetNumberType" minOccurs="0"/>
			<xsd:element name="Road" type="CBLAddressRoadType" minOccurs="0"/>
			<xsd:element name="Neighbourhood" type="CBLAddressNeighbourhoodType" minOccurs="0"/>
			<xsd:element name="Town" type="CBLAddressTownType" minOccurs="0"/>
			<xsd:element name="County" type="CBLAddressCountyType" minOccurs="0"/>
			<xsd:element name="PostCodeArea" type="AddressPostCodeAreaType"/>
			<xsd:element name="PostCodeStreet" type="AddressPostCodeStreetType"/>
			<!--xsd:element name="UPRN" type="bs7666:UPRNtype" minOccurs="0"/-->
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="AddressStructure">
		<xsd:sequence>
			<xsd:choice>
				<xsd:element name="CBLAddress" type="CBLAddressStructure"/>
				<!--xsd:element name="BS7666Address" type="bs7666:BSaddressStructure"/-->
			</xsd:choice>
		</xsd:sequence>
	</xsd:complexType>
</xsd:schema>
