Схема

XSD-схема находится по адресу http://kudago.com/static/import.xsd

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="unqualified" elementFormDefault="qualified"
           version="0.1.1">
    <xs:element name="xml" type="xmlType"/>
    <xs:element name="feed" type="xmlType"/>
    <xs:complexType name="dateType">
        <xs:simpleContent>
            <xs:extension base="xs:string">
                <xs:attribute type="xs:dateTime" name="start" use="optional"/>
                <xs:attribute type="xs:dateTime" name="end" use="optional"/>
                <xs:attribute type="xs:string" name="place" use="optional"/>
            </xs:extension>
        </xs:simpleContent>
    </xs:complexType>
    <xs:complexType name="scheduleType">
        <xs:sequence>
            <xs:element type="dateType" name="date" maxOccurs="unbounded" minOccurs="1"/>
        </xs:sequence>
    </xs:complexType>
    <xs:complexType name="imageType">
        <xs:simpleContent>
            <xs:extension base="xs:string">
                <xs:attribute type="URL" name="url" use="required"/>
                <xs:attribute type="xs:string" name="name"/>
                <xs:attribute type="xs:string" name="title"/>
            </xs:extension>
        </xs:simpleContent>
    </xs:complexType>
    <xs:complexType name="galleryType">
        <xs:sequence>
            <xs:element type="imageType" name="image" maxOccurs="unbounded" minOccurs="0"/>
        </xs:sequence>
    </xs:complexType>
    <xs:simpleType name="URL">
        <xs:restriction base="xs:anyURI">
            <xs:maxLength value="600"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="ageType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="0"/>
            <xs:enumeration value="6"/>
            <xs:enumeration value="12"/>
            <xs:enumeration value="16"/>
            <xs:enumeration value="18"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="cityType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="Москва"/>
            <xs:enumeration value="Санкт-Петербург"/>
            <xs:enumeration value="Казань"/>
            <xs:enumeration value="Новосибирск"/>
            <xs:enumeration value="Екатеринбург"/>
            <xs:enumeration value="Нижний Новгород"/>
            <xs:enumeration value="Уфа"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:complexType name="eventType">
        <xs:all>
            <xs:element type="xs:string" name="title"/>
            <xs:element type="cityType" name="city"/>
            <xs:element type="xs:string" name="description" minOccurs="0"/>
            <xs:element type="xs:string" name="full_description"/>
            <xs:element type="URL" name="url"/>
            <xs:element type="xs:string" name="price"/>
            <xs:element type="xs:boolean" name="free" minOccurs="0"/>
            <xs:element type="ageType" name="age_restriction"/>
            <xs:element type="xs:dateTime" name="last_updated" minOccurs="0"/>
            <xs:element type="scheduleType" name="schedule" minOccurs="1"/>
            <xs:element type="galleryType" name="gallery" minOccurs="0"/>
        </xs:all>
        <xs:attribute type="xs:string" name="id" use="required"/>
    </xs:complexType>
    <xs:complexType name="eventsType">
        <xs:sequence>
            <xs:element type="eventType" name="event" maxOccurs="5000" minOccurs="0"/>
        </xs:sequence>
    </xs:complexType>
    <xs:complexType name="addressType">
        <xs:simpleContent>
            <xs:extension base="xs:string">
                <xs:attribute type="xs:string" name="address"/>
                <xs:attribute type="xs:float" name="lat" use="optional"/>
                <xs:attribute type="xs:float" name="lon" use="optional"/>
                <xs:attribute type="xs:string" name="subway" use="optional"/>
            </xs:extension>
        </xs:simpleContent>
    </xs:complexType>
    <xs:complexType name="addressesType">
        <xs:sequence>
            <xs:element type="addressType" name="address"/>
        </xs:sequence>
    </xs:complexType>
    <xs:complexType name="placeType">
        <xs:all>
            <xs:element type="xs:string" name="title"/>
            <xs:element type="cityType" name="city"/>
            <xs:element type="xs:string" name="description" minOccurs="0"/>
            <xs:element type="xs:string" name="full_description"/>
            <xs:element type="URL" name="site_url" minOccurs="0"/>
            <xs:element type="xs:string" name="phone" minOccurs="0"/>
            <xs:element type="xs:anyURI" name="logo" minOccurs="0"/>
            <xs:element type="xs:dateTime" name="last_updated" minOccurs="0"/>
            <xs:element type="ageType" name="age_restriction" minOccurs="0"/>
            <xs:element type="addressesType" name="addresses" minOccurs="0"/>
            <xs:element type="galleryType" name="gallery" minOccurs="0"/>
        </xs:all>
        <xs:attribute type="xs:string" name="id" use="required"/>
    </xs:complexType>
    <xs:complexType name="placesType">
        <xs:sequence>
            <xs:element type="placeType" name="place" maxOccurs="5000" minOccurs="0"/>
        </xs:sequence>
    </xs:complexType>
    <xs:complexType name="xmlType">
        <xs:sequence>
            <xs:element type="eventsType" name="events"/>
            <xs:element type="placesType" name="places"/>
        </xs:sequence>
        <xs:attribute name="version" use="optional">
            <xs:simpleType>
                <xs:restriction base="xs:string">
                    <xs:pattern value="\d{1,2}.\d{1,2}.\d{1,2}"/>
                </xs:restriction>
            </xs:simpleType>
        </xs:attribute>
    </xs:complexType>
</xs:schema>