]> gitweb @ CieloNegro.org - Rakka.git/blob - schemas/rakka-page-1.0.rng
started implementing trackback receiver
[Rakka.git] / schemas / rakka-page-1.0.rng
1 <?xml version="1.0" encoding="utf-8"?>
2 <grammar ns="http://cielonegro.org/schema/Rakka/Page/1.0"
3          datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
4          xmlns="http://relaxng.org/ns/structure/1.0">
5
6   <start>
7     <element name="page">
8       <optional>
9         <element name="updateInfo">
10           <!-- 旧リビジョン -->
11           <attribute name="oldRevision">
12             <!-- HXT が對應してゐない。
13                  <data type="nonNegativeInteger" />
14             -->
15             <text />
16           </attribute>
17
18           <!-- ページ移動 -->
19           <optional>
20             <element name="move">
21               <attribute name="from">
22                 <text />
23               </attribute>
24             </element>
25           </optional>
26         </element>
27
28         <!-- 猶、更新時に type 屬性を空欄にすると自動判別される。但し
29              binaryData の場合のみ許される。 -->
30       </optional>
31
32       <optional>
33         <!-- ログインしてゐないユーザーの編集を禁止するフラグ -->
34         <attribute name="isLocked">
35           <choice>
36             <value>yes</value>
37             <value>no</value>
38           </choice>
39         </attribute>
40       </optional>
41
42       <choice>
43         <!-- リダイレクトの場合 -->
44         <ref name="redirection" />
45     
46         <!-- リダイレクトでない場合 -->
47         <ref name="entity" />
48       </choice>
49     </element>
50   </start>
51
52   <define name="redirection">
53     <attribute name="redirect">
54       <!-- ページ名 -->
55       <data type="anyURI" />
56     </attribute>
57   </define>
58
59   <define name="entity">
60     <group>
61       <attribute name="type">
62         <!-- MIME Type -->
63         <text />
64       </attribute>
65
66       <optional>
67         <attribute name="lang">
68           <text />
69         </attribute>
70       </optional>
71
72       <optional>
73         <!-- text/css でなければ無視される -->
74         <attribute name="isTheme">
75           <choice>
76             <value>yes</value>
77             <value>no</value>
78           </choice>
79         </attribute>
80       </optional>
81
82       <optional>
83         <!-- text/x-rakka でなければ無視される -->
84         <attribute name="isFeed">
85           <choice>
86             <value>yes</value>
87             <value>no</value>
88           </choice>
89         </attribute>
90       </optional>
91
92       <interleave>
93         <optional>
94           <element name="summary">
95             <text />
96           </element>
97         </optional>
98
99         <optional>
100           <element name="otherLang">
101             <zeroOrMore>
102               <element name="link">
103                 <attribute name="lang">
104                   <!-- RFC 4646 言語コード -->
105                   <text />
106                 </attribute>
107                 <attribute name="page">
108                   <!-- ページ名 -->
109                   <data type="anyURI" />
110                 </attribute>
111               </element>
112             </zeroOrMore>
113           </element>
114         </optional>
115       </interleave>
116
117       <choice>
118         <element name="textData">
119           <text />
120         </element>
121
122         <element name="binaryData">
123           <!-- これは HXT が對應してゐない。
124                <data type="base64Binary" />
125           -->
126           <text />
127         </element>
128       </choice>
129     </group>
130   </define>
131 </grammar>