summaryrefslogtreecommitdiffstats
path: root/xml/alerts-3.5.rng
blob: 32e7b5d95d960be35c1f50ae839d928aef6cc4f9 (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
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0" 
         datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
  <start>
      <ref name="element-alerts"/>
  </start>

  <define name="element-alerts">
    <optional>
    <element name="alerts">
      <zeroOrMore>
        <element name="alert">
          <attribute name="id"><data type="ID"/></attribute>
          <optional>
            <attribute name="description"><text/></attribute>
          </optional>
          <!-- path to the script called for alert -->
          <attribute name="path"><text/></attribute>
          <interleave>
            <ref name="element-alert-extra"/>
            <optional>
              <element name="select">
                <interleave>
                  <optional>
                    <element name="select_attributes">
                      <zeroOrMore>
                        <element name="attribute">
                          <attribute name="id"><data type="ID"/></attribute>
                          <attribute name="name"><text/></attribute>
                        </element>
                      </zeroOrMore>
                    </element>
                  </optional>
                  <optional>
                    <element name="select_fencing">
                      <empty/>
                    </element>
                  </optional>
                  <optional>
                    <element name="select_nodes">
                      <empty/>
                    </element>
                  </optional>
                  <optional>
                    <element name="select_resources">
                      <empty/>
                    </element>
                  </optional>
                </interleave>
              </element>
            </optional>
            <zeroOrMore>
              <element name="recipient">
                <attribute name="id"><data type="ID"/></attribute>
                <optional>
                  <attribute name="description"><text/></attribute>
                </optional>
                <attribute name="value"><text/></attribute>
                <ref name="element-alert-extra"/>
              </element>
            </zeroOrMore>
          </interleave>
        </element>
      </zeroOrMore>
    </element>
    </optional>
  </define>

  <define name="element-alert-extra">
      <zeroOrMore>
        <choice>
          <element name="meta_attributes">
            <externalRef href="nvset-3.5.rng"/>
          </element>
          <element name="instance_attributes">
            <externalRef href="nvset-3.5.rng"/>
          </element>
        </choice>
      </zeroOrMore>
  </define>

</grammar>