<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning" vc:minVersion="1.1" elementFormDefault="qualified" targetNamespace="https://schema.ccmm.cz/research-data/1.1" xmlns:ccmm="https://schema.ccmm.cz/research-data/1.1" xmlns:sawsdl="http://www.w3.org/ns/sawsdl" xmlns:xml="http://www.w3.org/XML/1998/namespace">
  <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
  <xs:complexType name="address" sawsdl:modelReference="http://www.w3.org/ns/locn#Address">
    <xs:annotation>
      <xs:documentation xml:lang="en">
        Address - A spatial object that in a human-readable way identifies a fixed location. 
        Address shall refer to the IRI identifier of an address from existing Address registry (e.g. RÚIAN for Czechia). In cases, where address identifier does not exist or cannot be used, fill address details using class attributes.
      </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element minOccurs="0" name="iri" type="xs:anyURI"/>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="label" sawsdl:modelReference="http://www.w3.org/2000/01/rdf-schema#label">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            label - Address label
          </xs:documentation>
        </xs:annotation>
        <xs:complexType>
          <xs:simpleContent>
            <xs:extension base="xs:string">
              <xs:attribute ref="xml:lang" use="required"/>
            </xs:extension>
          </xs:simpleContent>
        </xs:complexType>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="full_address" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#fullAddress">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            full address - The complete address written as a string.
            Use of this property is recommended as it will not suffer any misunderstandings that might arise through the breaking up of an address into its component parts. This property is analogous to vCard's label property but with two important differences: (1) formatting is not assumed so that, unlike vCard label, it may not be suitable to print this on an address label, (2) vCard's label property has a domain of vCard Address; the fullAddress property has no such restriction. An example of a full address is &#34;Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France&#34;. 
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="po_box" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#poBox">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            post office box - A location designator for a postal delivery point at a post office, usually a number.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="thoroughfare" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#thoroughfare">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            thoroughfare - The name of a passage or way through from one location to another.
            A thoroughfare is usually a street, but it might be a waterway or some other feature. For example, &#34;Avenue des Champs-Élysées&#34;.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="locator_designator" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#locatorDesignator">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            locator designator - A number or sequence of characters that uniquely identifies the locator within the relevant scope.
            In simpler terms, this is the building number, apartment number, etc. For an address such as &#34;Flat 3, 17 Bridge Street&#34;, the locator is &#34;flat 3, 17&#34;. 
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="locator_name" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#locatorName">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            locator name - Proper noun(s) applied to the real world entity identified by the locator. The locator name could be the name of the property or complex, of the building or part of the building, or it could be the name of a room inside a building.
            The locator name could be the name of the property or complex, of the building or part of the building, or it could be the name of a room inside a building.

            The key difference between a locator designator and a locator name is that the latter is a proper name and is unlikely to include digits. For example, &#34;Shumann, Berlaymont&#34; is a meeting room within the European Commission headquarters for which locator name is more appropriate than locator. 
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="address_area" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#addressArea">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            address area - The name of a geographic area that groups Addresses.
             This would typically be part of a city, a neighbourhood or village, e.g. Montmartre. Address area is not an administrative unit. 
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="post_name" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#postName">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            post name - A name created and maintained for postal purposes to identify a subdivision of addresses and postal delivery points. 
            Usually a city, for example &#34;Paris&#34;. Eventually name of the post itself.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="administrative_unit_level_1" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#adminUnitL1">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            administrative unit level 1 - The name of the uppermost level of the address, almost always a country.
            Best practice is to use the ISO 3166-1 code but if this is inappropriate for the context, country names should be provided in a consistent manner to reduce ambiguity. For example, either write 'France' or 'FRA' consistently throughout the dataset and avoid mixing the two. The Country controlled vocabulary from the Publications Office can be reused for this.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="administrative_unit_level_2" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#adminUnitL2">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            administrative unit level 2 - The name of a secondary level/region of the address, usually a county, state or other such area that typically encompasses several localities.
            Values could be a region or province, more granular than level 1.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="post_code" type="xs:string" sawsdl:modelReference="http://www.w3.org/ns/locn#postCode">
        <xs:annotation>
          <xs:documentation xml:lang="en">
            post code - The code created and maintained for postal purposes to identify a subdivision of addresses and postal delivery points.
            Post codes are common elements in many countries' postal address systems. One of the many post codes of Paris is for example &#34;75000&#34;.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax" namespace="##other"/>
    </xs:sequence>
  </xs:complexType>
  <xs:element name="address" type="ccmm:address"/>
</xs:schema>
