summaryrefslogtreecommitdiff
path: root/test/schemas/dur_0.xsd
blob: 374c038a98d169666edec9962e0a699ac24259e4 (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
<?xml version="1.0"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:annotation>
    <xsd:documentation xml:lang="en">
      Testing duration data types
    </xsd:documentation>
  </xsd:annotation>
  <xsd:element name="duration">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:choice minOccurs="1" maxOccurs="unbounded">
          <xsd:element name="second1">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxExclusive value="PT1S"/>
                <xsd:minExclusive value="PT0.1S"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="second2">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxInclusive value="PT1S"/>
                <xsd:minInclusive value="PT0.1S"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="month1">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxExclusive value="P1M"/>
                <xsd:minExclusive value="P0M"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="month2">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxInclusive value="P1M"/>
                <xsd:minInclusive value="P0M"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="month3" type="MSD"/>
          <xsd:element name="year1">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxExclusive value="P2Y"/>
                <xsd:minExclusive value="P1Y"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="year2">
            <xsd:simpleType>
              <xsd:restriction base="xsd:duration">
                <xsd:maxInclusive value="P2Y"/>
                <xsd:minInclusive value="P1Y"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
        </xsd:choice>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
  <xsd:simpleType name="MSD">
    <xsd:restriction base="xsd:duration">
      <xsd:maxExclusive value="PT24H"/>
      <xsd:minExclusive value="-PT24H"/>
    </xsd:restriction>
  </xsd:simpleType>
</xsd:schema>