summaryrefslogtreecommitdiff
path: root/schemas/incidence.xsd
blob: 988b7bb35d22c507a9d65616ab127c2dfc09ba2a (plain)
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
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    targetNamespace="http://kolab.org"
    xmlns="http://kolab.org"
    elementFormDefault="qualified">

    <xs:include schemaLocation="base.xsd" />

    <xs:complexType name="Incidence">
        <xs:complexContent>
            <xs:extension base="XMLBase">
                <xs:sequence>
                    <xs:element name="summary" type="xs:string" />
                    <xs:element name="location" type="xs:string" />
                    <xs:element name="creator" type="SMTPContact" />
                    <xs:element name="organizer" type="SMTPContact" />
                    <xs:element name="alarm" type="xs:string" />
                    <xs:element name="recurrence" type="Recurrence" minOccurs="0" maxOccurs="1"/>
                    <xs:element name="attendee" type="Attendee" />
                </xs:sequence>
            </xs:extension>
        </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="Attendee">
        <xs:complexContent>
            <xs:extension base="SMTPContact">
                <xs:sequence>
                    <xs:element name="status" type="Status" />
                    <xs:element name="request-response" type="xs:string" />
                    <xs:element name="role" type="Role" />
                </xs:sequence>
            </xs:extension>
        </xs:complexContent>
    </xs:complexType>

    <xs:simpleType name="Status">
        <xs:restriction base="xs:string">
            <xs:enumeration value="none" />
            <xs:enumeration value="tentative" />
            <xs:enumeration value="accepted" />
            <xs:enumeration value="declined" />
        </xs:restriction>
    </xs:simpleType>

    <xs:simpleType name="Role">
        <xs:restriction base="xs:string">
            <xs:enumeration value="required" />
            <xs:enumeration value="optional" />
            <xs:enumeration value="resource" />
        </xs:restriction>
    </xs:simpleType>


    <xs:complexType name="Recurrence">
        <xs:sequence>
            <xs:element name="rule" type="Rule" maxOccurs="unbounded" minOccurs="0" />
            <xs:element name="date" type="xs:dateTime" maxOccurs="unbounded" minOccurs="0" />
            <xs:element name="exception" type="Exception" maxOccurs="unbounded" minOccurs="0" />
        </xs:sequence>
    </xs:complexType>
    
    <xs:complexType name="Interval">
        <xs:choice>
            <xs:element name="interval" type="xs:int"/>
            <xs:element name="list" type="xs:int" maxOccurs="unbounded" minOccurs="1" />
        </xs:choice>
    </xs:complexType>

    <xs:complexType name="Exception">
        <xs:sequence>
            <xs:element name="rule" type="Rule" />
            <xs:element name="date" type="xs:dateTime" />
            <xs:element name="subevent" type="xs:string" />
        </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Rule">
        <xs:sequence>
            <xs:element name="yearly" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="monthly" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="weekly" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="daily" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="hourly" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="minutely" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="secondly" type="Interval" maxOccurs="1" minOccurs="0" />
            <xs:element name="occurence" type="xs:int" maxOccurs="unbounded" minOccurs="0" />
            <xs:element name="weekstart" type="xs:int" />
            <xs:choice>
                <xs:element name="count" type="xs:int" />
                <xs:element name="enddate" type="xs:dateTime" />
            </xs:choice>
        </xs:sequence>
    </xs:complexType>
</xs:schema>