Change the protocol definition of X-Resource to use ATOMs.
[free-sw/xcb/proto] / src / sync.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!--
3 Copyright (C) 2004 Mikko Torni and Josh Triplett.
4 All Rights Reserved.  See the file COPYING in this directory
5 for licensing information.
6 -->
7 <xcb header="sync" extension-xname="SYNC" extension-name="Sync"
8     major-version="3" minor-version="0">
9   <import>xproto</import>
10
11   <xidtype name="ALARM" />
12
13   <enum name="ALARMSTATE">
14     <item name="Active" />
15     <item name="Inactive" />
16     <item name="Destroyed" />
17   </enum>
18
19   <xidtype name="COUNTER" />
20
21   <enum name="TESTTYPE">
22     <item name="PositiveTransition" />
23     <item name="NegativeTransition" />
24     <item name="PositiveComparison" />
25     <item name="NegativeComparison" />
26   </enum>
27
28   <enum name="VALUETYPE">
29     <item name="Absolute" />
30     <item name="Relative" />
31   </enum>
32
33   <enum name="CA">
34     <item name="Counter">  <bit>0</bit></item>
35     <item name="ValueType"><bit>1</bit></item>
36     <item name="Value">    <bit>2</bit></item>
37     <item name="TestType"> <bit>3</bit></item>
38     <item name="Delta">    <bit>4</bit></item>
39     <item name="Events">   <bit>5</bit></item>
40   </enum>
41
42   <struct name="INT64">
43     <field type="INT32" name="hi" />
44     <field type="CARD32" name="lo" />
45   </struct>
46
47   <struct name="SYSTEMCOUNTER">
48     <field type="COUNTER" name="counter" />
49     <field type="INT64" name="resolution" />
50     <field type="CARD16" name="name_len" />
51     <list type="CARD8" name="name">
52       <fieldref>name_len</fieldref>
53     </list>
54   </struct>
55
56   <struct name="TRIGGER">
57     <field type="COUNTER" name="counter" />
58     <field type="VALUETYPE" name="wait_type" />
59     <field type="INT64" name="wait_value" />
60     <field type="TESTTYPE" name="test_type" />
61   </struct>
62
63   <struct name="WAITCONDITION">
64     <field type="TRIGGER" name="trigger" />
65     <field type="INT64" name="event_threshold" />
66   </struct>
67
68   <error name="Counter" number="0">
69     <field type="CARD32" name="bad_counter" />
70     <field type="CARD16" name="minor_opcode" />
71     <field type="CARD8" name="major_opcode" />
72   </error>
73
74   <error name="Alarm" number="1">
75     <field type="CARD32" name="bad_alarm" />
76     <field type="CARD16" name="minor_opcode" />
77     <field type="CARD8" name="major_opcode" />
78   </error>
79     
80   <request name="Initialize" opcode="0">
81     <field type="CARD8" name="desired_major_version" />
82     <field type="CARD8" name="desired_minor_version" />
83     <reply>
84       <pad bytes="1" />
85       <field type="CARD8" name="major_version" />
86       <field type="CARD8" name="minor_version" />
87     </reply>
88   </request>
89
90   <request name="ListSystemCounters" opcode="1">
91     <reply>
92       <pad bytes="1" />
93       <field type="CARD32" name="counters_len" />
94       <pad bytes="20" />
95       <list type="SYSTEMCOUNTER" name="counters">
96         <fieldref>counters_len</fieldref>
97       </list>
98     </reply>
99   </request>
100
101   <request name="CreateCounter" opcode="2">
102     <field type="COUNTER" name="id" />
103     <field type="INT64" name="initial_value" />
104   </request>
105
106   <request name="DestroyCounter" opcode="6">
107     <field type="COUNTER" name="counter" />
108   </request>
109
110   <request name="QueryCounter" opcode="5">
111     <field type="COUNTER" name="counter" />
112     <reply>
113       <pad bytes="1" />
114       <field type="INT64" name="counter_value" />
115     </reply>
116   </request>
117
118   <request name="Await" opcode="7">
119     <list type="WAITCONDITION" name="wait_list" />
120   </request>
121
122   <request name="ChangeCounter" opcode="4">
123     <field type="COUNTER" name="counter" />
124     <field type="INT64" name="amount" />
125   </request>
126
127   <request name="SetCounter" opcode="3">
128     <field type="COUNTER" name="counter" />
129     <field type="INT64" name="value" />
130   </request>
131
132   <request name="CreateAlarm" opcode="8">
133     <field type="ALARM" name="id" />
134     <valueparam value-mask-type="CARD32"
135                 value-mask-name="value_mask"
136                 value-list-name="value_list" />
137   </request>
138
139   <request name="ChangeAlarm" opcode="9">
140     <field type="ALARM" name="id" />
141     <valueparam value-mask-type="CARD32"
142                 value-mask-name="value_mask"
143                 value-list-name="value_list" />
144   </request>
145
146   <request name="DestroyAlarm" opcode="11">
147     <field type="ALARM" name="alarm" />
148   </request>
149
150   <request name="QueryAlarm" opcode="10">
151     <field type="ALARM" name="alarm" />
152     <reply>
153       <pad bytes="1" />
154       <field type="TRIGGER" name="trigger" />
155       <field type="INT64" name="delta" />
156       <field type="BOOL" name="events" />
157       <field type="ALARMSTATE" name="state" />
158     </reply>
159   </request>
160
161   <request name="SetPriority" opcode="12">
162     <field type="CARD32" name="id" />
163     <field type="INT32" name="priority" />
164   </request>
165     
166   <request name="GetPriority" opcode="13">
167     <field type="CARD32" name="id" />
168     <reply>
169       <pad bytes="1" />
170       <field type="INT32" name="priority" />
171     </reply>
172   </request>
173
174   <event name="CounterNotify" number="0">
175     <field type="CARD8" name="kind" />
176     <field type="COUNTER" name="counter" />
177     <field type="INT64" name="wait_value" />
178     <field type="INT64" name="counter_value" />
179     <field type="TIMESTAMP" name="timestamp" />
180     <field type="CARD16" name="count" />
181     <field type="BOOL" name="destroyed" />
182   </event>
183
184   <event name="AlarmNotify" number="1">
185     <field type="CARD8" name="kind" />
186     <field type="ALARM" name="alarm" />
187     <field type="INT64" name="counter_value" />
188     <field type="INT64" name="alarm_value" />
189     <field type="TIMESTAMP" name="timestamp" />
190   </event>
191 </xcb>