OLD | NEW |
---|---|
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // This header is meant to be included in multiple passes, hence no traditional | 5 // This header is meant to be included in multiple passes, hence no traditional |
6 // header guard. | 6 // header guard. |
7 // | 7 // |
8 // In the first pass, IPC_MESSAGE_MACROS_ENUMS should be defined, which will | 8 // In your XXX_messages_internal.h file, before defining any messages do: |
9 // create enums for each of the messages defined with the IPC_MESSAGE_* macros. | 9 // #define IPC_MESSAGE_START XMsgStart |
10 // | 10 // XMstStart value is from the IPCMessageStart enum in ipc_message_utils.h |
11 // In the second pass, either IPC_MESSAGE_MACROS_DEBUGSTRINGS or | 11 // In your XXX_messages.cc file, after all the includes for param types: |
12 // IPC_MESSAGE_MACROS_CLASSES should be defined (if both, DEBUGSTRINGS takes | 12 // #define IPC_MESSAGE_IMPL |
13 // precedence). Only one .cc file should have DEBUGSTRINGS defined, as this | 13 // #include "X_messages.h" |
14 // will create helper functions mapping message types to strings. Having | |
15 // CLASSES defined will create classes for each of the messages defined with | |
16 // the IPC_MESSAGE_* macros. | |
17 // | 14 // |
18 // "Sync" messages are just synchronous calls, the Send() call doesn't return | 15 // "Sync" messages are just synchronous calls, the Send() call doesn't return |
19 // until a reply comes back. Input parameters are first (const TYPE&), and | 16 // until a reply comes back. Input parameters are first (const TYPE&), and |
20 // To declare a sync message, use the IPC_SYNC_ macros. The numbers at the | 17 // To declare a sync message, use the IPC_SYNC_ macros. The numbers at the |
21 // end show how many input/output parameters there are (i.e. 1_2 is 1 in, 2 | 18 // end show how many input/output parameters there are (i.e. 1_2 is 1 in, 2 |
22 // out). The caller does a Send([route id, ], in1, &out1, &out2). | 19 // out). The caller does a Send([route id, ], in1, &out1, &out2). |
23 // The receiver's handler function will be | 20 // The receiver's handler function will be |
24 // void OnSyncMessageName(const type1& in1, type2* out1, type3* out2) | 21 // void OnSyncMessageName(const type1& in1, type2* out1, type3* out2) |
25 // | 22 // |
26 // | 23 // |
27 // A caller can also send a synchronous message, while the receiver can respond | 24 // A caller can also send a synchronous message, while the receiver can respond |
28 // at a later time. This is transparent from the sender's side. The receiver | 25 // at a later time. This is transparent from the sender's side. The receiver |
29 // needs to use a different handler that takes in a IPC::Message* as the output | 26 // needs to use a different handler that takes in a IPC::Message* as the output |
30 // type, stash the message, and when it has the data it can Send the message. | 27 // type, stash the message, and when it has the data it can Send the message. |
31 // | 28 // |
32 // Use the IPC_MESSAGE_HANDLER_DELAY_REPLY macro instead of IPC_MESSAGE_HANDLER | 29 // Use the IPC_MESSAGE_HANDLER_DELAY_REPLY macro instead of IPC_MESSAGE_HANDLER |
33 // IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_SyncMessageName, | 30 // IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_SyncMessageName, |
34 // OnSyncMessageName) | 31 // OnSyncMessageName) |
35 // | 32 // |
36 // The handler function will look like: | 33 // The handler function will look like: |
37 // void OnSyncMessageName(const type1& in1, IPC::Message* reply_msg); | 34 // void OnSyncMessageName(const type1& in1, IPC::Message* reply_msg); |
38 // | 35 // |
39 // Receiver stashes the IPC::Message* pointer, and when it's ready, it does: | 36 // Receiver stashes the IPC::Message* pointer, and when it's ready, it does: |
40 // ViewHostMsg_SyncMessageName::WriteReplyParams(reply_msg, out1, out2); | 37 // ViewHostMsg_SyncMessageName::WriteReplyParams(reply_msg, out1, out2); |
41 // Send(reply_msg); | 38 // Send(reply_msg); |
42 | 39 |
43 #include "ipc/ipc_message_utils.h" | 40 #include "ipc/ipc_message_utils.h" |
44 | 41 |
45 | 42 // In case a file includes several X_messages.h files, we don't want to get |
46 #ifndef MESSAGES_INTERNAL_FILE | 43 // errors because each X_messages_internal.h file will define this. |
47 #error This file should only be included by X_messages.h, which needs to define\ | 44 #undef IPC_MESSAGE_START |
48 MESSAGES_INTERNAL_FILE first. | 45 |
46 #if defined(IPC_MESSAGE_IMPL) | |
47 #include "ipc/ipc_message_impl_macros.h" | |
48 #elif defined(IPC_MESSAGE_MACROS_LOG_ENABLED) | |
49 | |
50 #ifndef IPC_LOG_TABLE_CREATED | |
51 #define IPC_LOG_TABLE_CREATED | |
52 | |
53 #include "base/hash_tables.h" | |
54 | |
55 typedef void (*LogFunction)(std::string* name, | |
56 const IPC::Message* msg, | |
57 std::string* params); | |
58 | |
59 typedef base::hash_map<uint32, LogFunction > LogFunctionMap; | |
60 LogFunctionMap g_log_function_mapping; | |
61 | |
49 #endif | 62 #endif |
50 | 63 |
51 // Trick xcode into seeing the possible real dependencies since they | 64 |
52 // don't understand #include MESSAGES_INTERNAL_FILE. See http://crbug.com/7828 | 65 #define IPC_MESSAGE_LOG(msg_class) \ |
53 #if 0 | 66 class LoggerRegisterHelper##msg_class { \ |
54 #include "ipc/ipc_sync_message_unittest.h" | 67 public: \ |
55 #include "chrome/common/automation_messages_internal.h" | 68 LoggerRegisterHelper##msg_class() { \ |
56 #include "chrome/common/devtools_messages_internal.h" | 69 g_log_function_mapping[msg_class::ID] = msg_class::Log; \ |
57 #include "chrome/common/plugin_messages_internal.h" | 70 } \ |
58 #include "chrome/common/render_messages_internal.h" | 71 }; \ |
59 #include "chrome/common/worker_messages_internal.h" | 72 LoggerRegisterHelper##msg_class g_LoggerRegisterHelper##msg_class; |
60 #include "ppapi/proxy/ppapi_messages_internal.h" | 73 |
74 #define IPC_MESSAGE_CONTROL0_EXTRA(msg_class) \ | |
75 IPC_MESSAGE_LOG(msg_class) | |
76 | |
77 #define IPC_MESSAGE_CONTROL1_EXTRA(msg_class, type1) \ | |
78 IPC_MESSAGE_LOG(msg_class) | |
79 | |
80 #define IPC_MESSAGE_CONTROL2_EXTRA(msg_class, type1, type2) \ | |
81 IPC_MESSAGE_LOG(msg_class) | |
82 | |
83 #define IPC_MESSAGE_CONTROL3_EXTRA(msg_class, type1, type2, type3) \ | |
84 IPC_MESSAGE_LOG(msg_class) | |
85 | |
86 #define IPC_MESSAGE_CONTROL4_EXTRA(msg_class, type1, type2, type3, type4) \ | |
87 IPC_MESSAGE_LOG(msg_class) | |
88 | |
89 #define IPC_MESSAGE_CONTROL5_EXTRA(msg_class, type1, type2, type3, type4, type5) \ | |
90 IPC_MESSAGE_LOG(msg_class) | |
91 | |
92 #define IPC_MESSAGE_ROUTED0_EXTRA(msg_class) \ | |
93 IPC_MESSAGE_LOG(msg_class) | |
94 | |
95 #define IPC_MESSAGE_ROUTED1_EXTRA(msg_class, type1) \ | |
96 IPC_MESSAGE_LOG(msg_class) | |
97 | |
98 #define IPC_MESSAGE_ROUTED2_EXTRA(msg_class, type1, type2) \ | |
99 IPC_MESSAGE_LOG(msg_class) | |
100 | |
101 #define IPC_MESSAGE_ROUTED3_EXTRA(msg_class, type1, type2, type3) \ | |
102 IPC_MESSAGE_LOG(msg_class) | |
103 | |
104 #define IPC_MESSAGE_ROUTED4_EXTRA(msg_class, type1, type2, type3, type4) \ | |
105 IPC_MESSAGE_LOG(msg_class) | |
106 | |
107 #define IPC_MESSAGE_ROUTED5_EXTRA(msg_class, type1, type2, type3, type4, type5) \ | |
108 IPC_MESSAGE_LOG(msg_class) | |
109 | |
110 #define IPC_SYNC_MESSAGE_CONTROL0_0_EXTRA(msg_class) \ | |
111 IPC_MESSAGE_LOG(msg_class) | |
112 | |
113 #define IPC_SYNC_MESSAGE_CONTROL0_1_EXTRA(msg_class, type1_out) \ | |
114 IPC_MESSAGE_LOG(msg_class) | |
115 | |
116 #define IPC_SYNC_MESSAGE_CONTROL0_2_EXTRA(msg_class, type1_out, type2_out) \ | |
117 IPC_MESSAGE_LOG(msg_class) | |
118 | |
119 #define IPC_SYNC_MESSAGE_CONTROL0_3_EXTRA(msg_class, type1_out, type2_out, type3 _out) \ | |
120 IPC_MESSAGE_LOG(msg_class) | |
121 | |
122 #define IPC_SYNC_MESSAGE_CONTROL1_0_EXTRA(msg_class, type1_in) \ | |
123 IPC_MESSAGE_LOG(msg_class) | |
124 | |
125 #define IPC_SYNC_MESSAGE_CONTROL1_1_EXTRA(msg_class, type1_in, type1_out) \ | |
126 IPC_MESSAGE_LOG(msg_class) | |
127 | |
128 #define IPC_SYNC_MESSAGE_CONTROL1_2_EXTRA(msg_class, type1_in, type1_out, type2_ out) \ | |
129 IPC_MESSAGE_LOG(msg_class) | |
130 | |
131 #define IPC_SYNC_MESSAGE_CONTROL1_3_EXTRA(msg_class, type1_in, type1_out, type2_ out, type3_out) \ | |
132 IPC_MESSAGE_LOG(msg_class) | |
133 | |
134 #define IPC_SYNC_MESSAGE_CONTROL2_0_EXTRA(msg_class, type1_in, type2_in) \ | |
135 IPC_MESSAGE_LOG(msg_class) | |
136 | |
137 #define IPC_SYNC_MESSAGE_CONTROL2_1_EXTRA(msg_class, type1_in, type2_in, type1_o ut) \ | |
138 IPC_MESSAGE_LOG(msg_class) | |
139 | |
140 #define IPC_SYNC_MESSAGE_CONTROL2_2_EXTRA(msg_class, type1_in, type2_in, type1_o ut, type2_out) \ | |
141 IPC_MESSAGE_LOG(msg_class) | |
142 | |
143 #define IPC_SYNC_MESSAGE_CONTROL2_3_EXTRA(msg_class, type1_in, type2_in, type1_o ut, type2_out, type3_out) \ | |
144 IPC_MESSAGE_LOG(msg_class) | |
145 | |
146 #define IPC_SYNC_MESSAGE_CONTROL3_1_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out) \ | |
147 IPC_MESSAGE_LOG(msg_class) | |
148 | |
149 #define IPC_SYNC_MESSAGE_CONTROL3_2_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out) \ | |
150 IPC_MESSAGE_LOG(msg_class) | |
151 | |
152 #define IPC_SYNC_MESSAGE_CONTROL3_3_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out, type3_out) \ | |
153 IPC_MESSAGE_LOG(msg_class) | |
154 | |
155 #define IPC_SYNC_MESSAGE_CONTROL3_4_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out, type3_out, type4_out) \ | |
156 IPC_MESSAGE_LOG(msg_class) | |
157 | |
158 #define IPC_SYNC_MESSAGE_CONTROL4_1_EXTRA(msg_class, type1_in, type2_in, type3_i n, type4_in, type1_out) \ | |
159 IPC_MESSAGE_LOG(msg_class) | |
160 | |
161 #define IPC_SYNC_MESSAGE_CONTROL4_2_EXTRA(msg_class, type1_in, type2_in, type3_i n, type4_in, type1_out, type2_out) \ | |
162 IPC_MESSAGE_LOG(msg_class) | |
163 | |
164 #define IPC_SYNC_MESSAGE_ROUTED0_0_EXTRA(msg_class) \ | |
165 IPC_MESSAGE_LOG(msg_class) | |
166 | |
167 #define IPC_SYNC_MESSAGE_ROUTED0_1_EXTRA(msg_class, type1_out) \ | |
168 IPC_MESSAGE_LOG(msg_class) | |
169 | |
170 #define IPC_SYNC_MESSAGE_ROUTED0_2_EXTRA(msg_class, type1_out, type2_out) \ | |
171 IPC_MESSAGE_LOG(msg_class) | |
172 | |
173 #define IPC_SYNC_MESSAGE_ROUTED0_3_EXTRA(msg_class, type1_out, type2_out, type3_ out) \ | |
174 IPC_MESSAGE_LOG(msg_class) | |
175 | |
176 #define IPC_SYNC_MESSAGE_ROUTED1_0_EXTRA(msg_class, type1_in) \ | |
177 IPC_MESSAGE_LOG(msg_class) | |
178 | |
179 #define IPC_SYNC_MESSAGE_ROUTED1_1_EXTRA(msg_class, type1_in, type1_out) \ | |
180 IPC_MESSAGE_LOG(msg_class) | |
181 | |
182 #define IPC_SYNC_MESSAGE_ROUTED1_2_EXTRA(msg_class, type1_in, type1_out, type2_o ut) \ | |
183 IPC_MESSAGE_LOG(msg_class) | |
184 | |
185 #define IPC_SYNC_MESSAGE_ROUTED1_3_EXTRA(msg_class, type1_in, type1_out, type2_o ut, type3_out) \ | |
186 IPC_MESSAGE_LOG(msg_class) | |
187 | |
188 #define IPC_SYNC_MESSAGE_ROUTED1_4_EXTRA(msg_class, type1_in, type1_out, type2_o ut, type3_out, type4_out) \ | |
189 IPC_MESSAGE_LOG(msg_class) | |
190 | |
191 #define IPC_SYNC_MESSAGE_ROUTED2_0_EXTRA(msg_class, type1_in, type2_in) \ | |
192 IPC_MESSAGE_LOG(msg_class) | |
193 | |
194 #define IPC_SYNC_MESSAGE_ROUTED2_1_EXTRA(msg_class, type1_in, type2_in, type1_ou t) \ | |
195 IPC_MESSAGE_LOG(msg_class) | |
196 | |
197 #define IPC_SYNC_MESSAGE_ROUTED2_2_EXTRA(msg_class, type1_in, type2_in, type1_ou t, type2_out) \ | |
198 IPC_MESSAGE_LOG(msg_class) | |
199 | |
200 #define IPC_SYNC_MESSAGE_ROUTED2_3_EXTRA(msg_class, type1_in, type2_in, type1_ou t, type2_out, type3_out) \ | |
201 IPC_MESSAGE_LOG(msg_class) | |
202 | |
203 #define IPC_SYNC_MESSAGE_ROUTED3_0_EXTRA(msg_class, type1_in, type2_in, type3_in ) \ | |
204 IPC_MESSAGE_LOG(msg_class) | |
205 | |
206 #define IPC_SYNC_MESSAGE_ROUTED3_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out) \ | |
207 IPC_MESSAGE_LOG(msg_class) | |
208 | |
209 #define IPC_SYNC_MESSAGE_ROUTED3_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out) \ | |
210 IPC_MESSAGE_LOG(msg_class) | |
211 | |
212 #define IPC_SYNC_MESSAGE_ROUTED3_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out, type3_out) \ | |
213 IPC_MESSAGE_LOG(msg_class) | |
214 | |
215 #define IPC_SYNC_MESSAGE_ROUTED3_4_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out, type3_out, type4_out) \ | |
216 IPC_MESSAGE_LOG(msg_class) | |
217 | |
218 #define IPC_SYNC_MESSAGE_ROUTED4_0_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in) \ | |
219 IPC_MESSAGE_LOG(msg_class) | |
220 | |
221 #define IPC_SYNC_MESSAGE_ROUTED4_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out) \ | |
222 IPC_MESSAGE_LOG(msg_class) | |
223 | |
224 #define IPC_SYNC_MESSAGE_ROUTED4_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out, type2_out) \ | |
225 IPC_MESSAGE_LOG(msg_class) | |
226 | |
227 #define IPC_SYNC_MESSAGE_ROUTED4_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out, type2_out, type3_out) \ | |
228 IPC_MESSAGE_LOG(msg_class) | |
229 | |
230 #define IPC_SYNC_MESSAGE_ROUTED5_0_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in) \ | |
231 IPC_MESSAGE_LOG(msg_class) | |
232 | |
233 #define IPC_SYNC_MESSAGE_ROUTED5_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out) \ | |
234 IPC_MESSAGE_LOG(msg_class) | |
235 | |
236 #define IPC_SYNC_MESSAGE_ROUTED5_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out, type2_out) \ | |
237 IPC_MESSAGE_LOG(msg_class) | |
238 | |
239 #define IPC_SYNC_MESSAGE_ROUTED5_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out, type2_out, type3_out) \ | |
240 IPC_MESSAGE_LOG(msg_class) | |
241 | |
242 #else | |
243 | |
244 #define IPC_MESSAGE_CONTROL0_EXTRA(msg_class) | |
245 #define IPC_MESSAGE_CONTROL1_EXTRA(msg_class, type1) | |
246 #define IPC_MESSAGE_CONTROL2_EXTRA(msg_class, type1, type2) | |
247 #define IPC_MESSAGE_CONTROL3_EXTRA(msg_class, type1, type2, type3) | |
248 #define IPC_MESSAGE_CONTROL4_EXTRA(msg_class, type1, type2, type3, type4) | |
249 #define IPC_MESSAGE_CONTROL5_EXTRA(msg_class, type1, type2, type3, type4, type5) | |
250 #define IPC_MESSAGE_ROUTED0_EXTRA(msg_class) | |
251 #define IPC_MESSAGE_ROUTED1_EXTRA(msg_class, type1) | |
252 #define IPC_MESSAGE_ROUTED2_EXTRA(msg_class, type1, type2) | |
253 #define IPC_MESSAGE_ROUTED3_EXTRA(msg_class, type1, type2, type3) | |
254 #define IPC_MESSAGE_ROUTED4_EXTRA(msg_class, type1, type2, type3, type4) | |
255 #define IPC_MESSAGE_ROUTED5_EXTRA(msg_class, type1, type2, type3, type4, type5) | |
256 #define IPC_SYNC_MESSAGE_CONTROL0_0_EXTRA(msg_class) | |
257 #define IPC_SYNC_MESSAGE_CONTROL0_1_EXTRA(msg_class, type1_out) | |
258 #define IPC_SYNC_MESSAGE_CONTROL0_2_EXTRA(msg_class, type1_out, type2_out) | |
259 #define IPC_SYNC_MESSAGE_CONTROL0_3_EXTRA(msg_class, type1_out, type2_out, type3 _out) | |
260 #define IPC_SYNC_MESSAGE_CONTROL1_0_EXTRA(msg_class, type1_in) | |
261 #define IPC_SYNC_MESSAGE_CONTROL1_1_EXTRA(msg_class, type1_in, type1_out) | |
262 #define IPC_SYNC_MESSAGE_CONTROL1_2_EXTRA(msg_class, type1_in, type1_out, type2_ out) | |
263 #define IPC_SYNC_MESSAGE_CONTROL1_3_EXTRA(msg_class, type1_in, type1_out, type2_ out, type3_out) | |
264 #define IPC_SYNC_MESSAGE_CONTROL2_0_EXTRA(msg_class, type1_in, type2_in) | |
265 #define IPC_SYNC_MESSAGE_CONTROL2_1_EXTRA(msg_class, type1_in, type2_in, type1_o ut) | |
266 #define IPC_SYNC_MESSAGE_CONTROL2_2_EXTRA(msg_class, type1_in, type2_in, type1_o ut, type2_out) | |
267 #define IPC_SYNC_MESSAGE_CONTROL2_3_EXTRA(msg_class, type1_in, type2_in, type1_o ut, type2_out, type3_out) | |
268 #define IPC_SYNC_MESSAGE_CONTROL3_1_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out) | |
269 #define IPC_SYNC_MESSAGE_CONTROL3_2_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out) | |
270 #define IPC_SYNC_MESSAGE_CONTROL3_3_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out, type3_out) | |
271 #define IPC_SYNC_MESSAGE_CONTROL3_4_EXTRA(msg_class, type1_in, type2_in, type3_i n, type1_out, type2_out, type3_out, type4_out) | |
272 #define IPC_SYNC_MESSAGE_CONTROL4_1_EXTRA(msg_class, type1_in, type2_in, type3_i n, type4_in, type1_out) | |
273 #define IPC_SYNC_MESSAGE_CONTROL4_2_EXTRA(msg_class, type1_in, type2_in, type3_i n, type4_in, type1_out, type2_out) | |
274 #define IPC_SYNC_MESSAGE_ROUTED0_0_EXTRA(msg_class) | |
275 #define IPC_SYNC_MESSAGE_ROUTED0_1_EXTRA(msg_class, type1_out) | |
276 #define IPC_SYNC_MESSAGE_ROUTED0_2_EXTRA(msg_class, type1_out, type2_out) | |
277 #define IPC_SYNC_MESSAGE_ROUTED0_3_EXTRA(msg_class, type1_out, type2_out, type3_ out) | |
278 #define IPC_SYNC_MESSAGE_ROUTED1_0_EXTRA(msg_class, type1_in) | |
279 #define IPC_SYNC_MESSAGE_ROUTED1_1_EXTRA(msg_class, type1_in, type1_out) | |
280 #define IPC_SYNC_MESSAGE_ROUTED1_2_EXTRA(msg_class, type1_in, type1_out, type2_o ut) | |
281 #define IPC_SYNC_MESSAGE_ROUTED1_3_EXTRA(msg_class, type1_in, type1_out, type2_o ut, type3_out) | |
282 #define IPC_SYNC_MESSAGE_ROUTED1_4_EXTRA(msg_class, type1_in, type1_out, type2_o ut, type3_out, type4_out) | |
283 #define IPC_SYNC_MESSAGE_ROUTED2_0_EXTRA(msg_class, type1_in, type2_in) | |
284 #define IPC_SYNC_MESSAGE_ROUTED2_1_EXTRA(msg_class, type1_in, type2_in, type1_ou t) | |
285 #define IPC_SYNC_MESSAGE_ROUTED2_2_EXTRA(msg_class, type1_in, type2_in, type1_ou t, type2_out) | |
286 #define IPC_SYNC_MESSAGE_ROUTED2_3_EXTRA(msg_class, type1_in, type2_in, type1_ou t, type2_out, type3_out) | |
287 #define IPC_SYNC_MESSAGE_ROUTED3_0_EXTRA(msg_class, type1_in, type2_in, type3_in ) | |
288 #define IPC_SYNC_MESSAGE_ROUTED3_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out) | |
289 #define IPC_SYNC_MESSAGE_ROUTED3_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out) | |
290 #define IPC_SYNC_MESSAGE_ROUTED3_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out, type3_out) | |
291 #define IPC_SYNC_MESSAGE_ROUTED3_4_EXTRA(msg_class, type1_in, type2_in, type3_in , type1_out, type2_out, type3_out, type4_out) | |
292 #define IPC_SYNC_MESSAGE_ROUTED4_0_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in) | |
293 #define IPC_SYNC_MESSAGE_ROUTED4_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out) | |
294 #define IPC_SYNC_MESSAGE_ROUTED4_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out, type2_out) | |
295 #define IPC_SYNC_MESSAGE_ROUTED4_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type1_out, type2_out, type3_out) | |
296 #define IPC_SYNC_MESSAGE_ROUTED5_0_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in) | |
297 #define IPC_SYNC_MESSAGE_ROUTED5_1_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out) | |
298 #define IPC_SYNC_MESSAGE_ROUTED5_2_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out, type2_out) | |
299 #define IPC_SYNC_MESSAGE_ROUTED5_3_EXTRA(msg_class, type1_in, type2_in, type3_in , type4_in, type5_in, type1_out, type2_out, type3_out) | |
300 | |
61 #endif | 301 #endif |
62 | 302 |
63 #ifndef IPC_MESSAGE_MACROS_INCLUDE_BLOCK | |
64 #define IPC_MESSAGE_MACROS_INCLUDE_BLOCK | |
65 | |
66 // Multi-pass include of X_messages_internal.h. Preprocessor magic allows | |
67 // us to use 1 header to define the enums and classes for our render messages. | |
68 #define IPC_MESSAGE_MACROS_ENUMS | |
69 #include MESSAGES_INTERNAL_FILE | |
70 | |
71 #define IPC_MESSAGE_MACROS_CLASSES | |
72 #include MESSAGES_INTERNAL_FILE | |
73 | |
74 #ifdef IPC_MESSAGE_MACROS_LOG_ENABLED | |
75 #define IPC_MESSAGE_MACROS_LOG | |
76 #include MESSAGES_INTERNAL_FILE | |
77 #endif | |
78 | |
79 #undef MESSAGES_INTERNAL_FILE | |
80 #undef IPC_MESSAGE_MACROS_INCLUDE_BLOCK | |
81 | |
82 #endif | |
83 | |
84 #if defined(IPC_MESSAGE_MACROS_ENUMS) | |
85 #undef IPC_MESSAGE_MACROS_ENUMS | |
86 | |
87 | |
88 // Undefine the macros from the previous pass (if any). | |
89 #undef IPC_BEGIN_MESSAGES | |
90 #undef IPC_END_MESSAGES | |
91 #undef IPC_MESSAGE_CONTROL0 | |
92 #undef IPC_MESSAGE_CONTROL1 | |
93 #undef IPC_MESSAGE_CONTROL2 | |
94 #undef IPC_MESSAGE_CONTROL3 | |
95 #undef IPC_MESSAGE_CONTROL4 | |
96 #undef IPC_MESSAGE_CONTROL5 | |
97 #undef IPC_MESSAGE_ROUTED0 | |
98 #undef IPC_MESSAGE_ROUTED1 | |
99 #undef IPC_MESSAGE_ROUTED2 | |
100 #undef IPC_MESSAGE_ROUTED3 | |
101 #undef IPC_MESSAGE_ROUTED4 | |
102 #undef IPC_MESSAGE_ROUTED5 | |
103 #undef IPC_SYNC_MESSAGE_CONTROL0_0 | |
104 #undef IPC_SYNC_MESSAGE_CONTROL0_1 | |
105 #undef IPC_SYNC_MESSAGE_CONTROL0_2 | |
106 #undef IPC_SYNC_MESSAGE_CONTROL0_3 | |
107 #undef IPC_SYNC_MESSAGE_CONTROL1_0 | |
108 #undef IPC_SYNC_MESSAGE_CONTROL1_1 | |
109 #undef IPC_SYNC_MESSAGE_CONTROL1_2 | |
110 #undef IPC_SYNC_MESSAGE_CONTROL1_3 | |
111 #undef IPC_SYNC_MESSAGE_CONTROL2_0 | |
112 #undef IPC_SYNC_MESSAGE_CONTROL2_1 | |
113 #undef IPC_SYNC_MESSAGE_CONTROL2_2 | |
114 #undef IPC_SYNC_MESSAGE_CONTROL2_3 | |
115 #undef IPC_SYNC_MESSAGE_CONTROL3_1 | |
116 #undef IPC_SYNC_MESSAGE_CONTROL3_2 | |
117 #undef IPC_SYNC_MESSAGE_CONTROL3_3 | |
118 #undef IPC_SYNC_MESSAGE_CONTROL3_4 | |
119 #undef IPC_SYNC_MESSAGE_CONTROL4_1 | |
120 #undef IPC_SYNC_MESSAGE_CONTROL4_2 | |
121 #undef IPC_SYNC_MESSAGE_ROUTED0_0 | |
122 #undef IPC_SYNC_MESSAGE_ROUTED0_1 | |
123 #undef IPC_SYNC_MESSAGE_ROUTED0_2 | |
124 #undef IPC_SYNC_MESSAGE_ROUTED0_3 | |
125 #undef IPC_SYNC_MESSAGE_ROUTED1_0 | |
126 #undef IPC_SYNC_MESSAGE_ROUTED1_1 | |
127 #undef IPC_SYNC_MESSAGE_ROUTED1_2 | |
128 #undef IPC_SYNC_MESSAGE_ROUTED1_3 | |
129 #undef IPC_SYNC_MESSAGE_ROUTED1_4 | |
130 #undef IPC_SYNC_MESSAGE_ROUTED2_0 | |
131 #undef IPC_SYNC_MESSAGE_ROUTED2_1 | |
132 #undef IPC_SYNC_MESSAGE_ROUTED2_2 | |
133 #undef IPC_SYNC_MESSAGE_ROUTED2_3 | |
134 #undef IPC_SYNC_MESSAGE_ROUTED3_0 | |
135 #undef IPC_SYNC_MESSAGE_ROUTED3_1 | |
136 #undef IPC_SYNC_MESSAGE_ROUTED3_2 | |
137 #undef IPC_SYNC_MESSAGE_ROUTED3_3 | |
138 #undef IPC_SYNC_MESSAGE_ROUTED3_4 | |
139 #undef IPC_SYNC_MESSAGE_ROUTED4_0 | |
140 #undef IPC_SYNC_MESSAGE_ROUTED4_1 | |
141 #undef IPC_SYNC_MESSAGE_ROUTED4_2 | |
142 #undef IPC_SYNC_MESSAGE_ROUTED4_3 | |
143 #undef IPC_SYNC_MESSAGE_ROUTED5_0 | |
144 #undef IPC_SYNC_MESSAGE_ROUTED5_1 | |
145 #undef IPC_SYNC_MESSAGE_ROUTED5_2 | |
146 #undef IPC_SYNC_MESSAGE_ROUTED5_3 | |
147 | |
148 // We're using the lowest 16 bits of type for the message id, and the highest | |
149 // 16 bits for the channel type. | |
150 // | |
151 // Do label##PreStart so that automation messages keep the same id as before. | |
152 #define IPC_BEGIN_MESSAGES(label) \ | |
153 enum label##MsgType { \ | |
154 label##Start = label##MsgStart << 16, \ | |
155 label##PreStart = (label##MsgStart << 16) - 1, | |
156 | |
157 #define IPC_END_MESSAGES(label) \ | |
158 label##End \ | |
159 }; | |
160 | |
161 #define IPC_MESSAGE_CONTROL0(msg_class) \ | 303 #define IPC_MESSAGE_CONTROL0(msg_class) \ |
162 msg_class##__ID, | 304 class msg_class : public IPC::Message { \ |
305 public: \ | |
306 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
jam
2010/12/08 01:44:10
note: the only changes I made here are fixing spac
| |
307 msg_class() \ | |
308 : IPC::Message(MSG_ROUTING_CONTROL, \ | |
309 ID, \ | |
310 PRIORITY_NORMAL) {} \ | |
311 }; \ | |
312 IPC_MESSAGE_CONTROL0_EXTRA(msg_class) | |
163 | 313 |
164 #define IPC_MESSAGE_CONTROL1(msg_class, type1) \ | 314 #define IPC_MESSAGE_CONTROL1(msg_class, type1) \ |
165 msg_class##__ID, | 315 class msg_class : public IPC::MessageWithTuple< Tuple1<type1> > { \ |
166 | 316 public: \ |
167 #define IPC_MESSAGE_CONTROL2(msg_class, type1, type2) \ | 317 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ |
168 msg_class##__ID, | 318 msg_class(const type1& arg1); \ |
169 | 319 ~msg_class(); \ |
170 #define IPC_MESSAGE_CONTROL3(msg_class, type1, type2, type3) \ | 320 static void Log(std::string* name, const Message* msg, std::string* l); \ |
171 msg_class##__ID, | 321 }; \ |
172 | 322 IPC_MESSAGE_CONTROL1_EXTRA(msg_class, type1) |
173 #define IPC_MESSAGE_CONTROL4(msg_class, type1, type2, type3, type4) \ | 323 |
174 msg_class##__ID, | 324 #define IPC_MESSAGE_CONTROL2(msg_class, type1, type2) \ |
325 class msg_class : public IPC::MessageWithTuple< Tuple2<type1, type2> > { \ | |
326 public: \ | |
327 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
328 msg_class(const type1& arg1, const type2& arg2); \ | |
329 ~msg_class(); \ | |
330 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
331 }; \ | |
332 IPC_MESSAGE_CONTROL2_EXTRA(msg_class, type1, type2) | |
333 | |
334 #define IPC_MESSAGE_CONTROL3(msg_class, type1, type2, type3) \ | |
335 class msg_class : \ | |
336 public IPC::MessageWithTuple< Tuple3<type1, type2, type3> > { \ | |
337 public: \ | |
338 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
339 msg_class(const type1& arg1, const type2& arg2, const type3& arg3); \ | |
340 ~msg_class(); \ | |
341 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
342 }; \ | |
343 IPC_MESSAGE_CONTROL3_EXTRA(msg_class, type1, type2, type3) | |
344 | |
345 #define IPC_MESSAGE_CONTROL4(msg_class, type1, type2, type3, type4) \ | |
346 class msg_class : \ | |
347 public IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> > { \ | |
348 public: \ | |
349 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
350 msg_class(const type1& arg1, const type2& arg2, const type3& arg3, \ | |
351 const type4& arg4); \ | |
352 ~msg_class(); \ | |
353 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
354 }; \ | |
355 IPC_MESSAGE_CONTROL4_EXTRA(msg_class, type1, type2, type3, type4) | |
175 | 356 |
176 #define IPC_MESSAGE_CONTROL5(msg_class, type1, type2, type3, type4, type5) \ | 357 #define IPC_MESSAGE_CONTROL5(msg_class, type1, type2, type3, type4, type5) \ |
177 msg_class##__ID, | 358 class msg_class : \ |
359 public IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, \ | |
360 type5> > { \ | |
361 public: \ | |
362 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
363 msg_class(const type1& arg1, const type2& arg2, \ | |
364 const type3& arg3, const type4& arg4, const type5& arg5); \ | |
365 ~msg_class(); \ | |
366 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
367 }; \ | |
368 IPC_MESSAGE_CONTROL5_EXTRA(msg_class, type1, type2, type3, type4, type5) | |
178 | 369 |
179 #define IPC_MESSAGE_ROUTED0(msg_class) \ | 370 #define IPC_MESSAGE_ROUTED0(msg_class) \ |
180 msg_class##__ID, | 371 class msg_class : public IPC::Message { \ |
372 public: \ | |
373 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
374 msg_class(int32 routing_id) \ | |
375 : IPC::Message(routing_id, ID, PRIORITY_NORMAL) {} \ | |
376 }; \ | |
377 IPC_MESSAGE_ROUTED0_EXTRA(msg_class) | |
181 | 378 |
182 #define IPC_MESSAGE_ROUTED1(msg_class, type1) \ | 379 #define IPC_MESSAGE_ROUTED1(msg_class, type1) \ |
183 msg_class##__ID, | 380 class msg_class : public IPC::MessageWithTuple< Tuple1<type1> > { \ |
184 | 381 public: \ |
185 #define IPC_MESSAGE_ROUTED2(msg_class, type1, type2) \ | 382 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ |
186 msg_class##__ID, | 383 msg_class(int32 routing_id, const type1& arg1); \ |
187 | 384 ~msg_class(); \ |
188 #define IPC_MESSAGE_ROUTED3(msg_class, type1, type2, type3) \ | 385 static void Log(std::string* name, const Message* msg, std::string* l); \ |
189 msg_class##__ID, | 386 }; \ |
190 | 387 IPC_MESSAGE_ROUTED1_EXTRA(msg_class, type1) |
191 #define IPC_MESSAGE_ROUTED4(msg_class, type1, type2, type3, type4) \ | 388 |
192 msg_class##__ID, | 389 #define IPC_MESSAGE_ROUTED2(msg_class, type1, type2) \ |
390 class msg_class \ | |
391 : public IPC::MessageWithTuple< Tuple2<type1, type2> > { \ | |
392 public: \ | |
393 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
394 msg_class(int32 routing_id, const type1& arg1, const type2& arg2); \ | |
395 ~msg_class(); \ | |
396 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
397 }; \ | |
398 IPC_MESSAGE_ROUTED2_EXTRA(msg_class, type1, type2) | |
399 | |
400 #define IPC_MESSAGE_ROUTED3(msg_class, type1, type2, type3) \ | |
401 class msg_class \ | |
402 : public IPC::MessageWithTuple< Tuple3<type1, type2, type3> > { \ | |
403 public: \ | |
404 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
405 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
406 const type3& arg3); \ | |
407 ~msg_class(); \ | |
408 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
409 }; \ | |
410 IPC_MESSAGE_ROUTED3_EXTRA(msg_class, type1, type2, type3) | |
411 | |
412 #define IPC_MESSAGE_ROUTED4(msg_class, type1, type2, type3, type4) \ | |
413 class msg_class \ | |
414 : public IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> > { \ | |
415 public: \ | |
416 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
417 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
418 const type3& arg3, const type4& arg4); \ | |
419 ~msg_class(); \ | |
420 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
421 }; \ | |
422 IPC_MESSAGE_ROUTED4_EXTRA(msg_class, type1, type2, type3, type4) | |
193 | 423 |
194 #define IPC_MESSAGE_ROUTED5(msg_class, type1, type2, type3, type4, type5) \ | 424 #define IPC_MESSAGE_ROUTED5(msg_class, type1, type2, type3, type4, type5) \ |
195 msg_class##__ID, | 425 class msg_class \ |
426 : public IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, \ | |
427 type5> > { \ | |
428 public: \ | |
429 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
430 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
431 const type3& arg3, const type4& arg4, const type5& arg5); \ | |
432 ~msg_class(); \ | |
433 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
434 }; \ | |
435 IPC_MESSAGE_ROUTED5_EXTRA(msg_class, type1, type2, type3, type4, type5) | |
196 | 436 |
197 #define IPC_SYNC_MESSAGE_CONTROL0_0(msg_class) \ | 437 #define IPC_SYNC_MESSAGE_CONTROL0_0(msg_class) \ |
198 msg_class##__ID, | 438 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple0 > { \ |
199 | 439 public: \ |
200 #define IPC_SYNC_MESSAGE_CONTROL0_1(msg_class, type1_out) \ | 440 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ |
201 msg_class##__ID, | 441 msg_class(); \ |
442 ~msg_class(); \ | |
443 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
444 }; \ | |
445 IPC_SYNC_MESSAGE_CONTROL0_0_EXTRA(msg_class) | |
446 | |
447 #define IPC_SYNC_MESSAGE_CONTROL0_1(msg_class, type1_out) \ | |
448 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple1<type1_out&> > {\ | |
449 public: \ | |
450 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
451 msg_class(type1_out* arg1); \ | |
452 ~msg_class(); \ | |
453 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
454 }; \ | |
455 IPC_SYNC_MESSAGE_CONTROL0_1_EXTRA(msg_class, type1_out) | |
202 | 456 |
203 #define IPC_SYNC_MESSAGE_CONTROL0_2(msg_class, type1_out, type2_out) \ | 457 #define IPC_SYNC_MESSAGE_CONTROL0_2(msg_class, type1_out, type2_out) \ |
204 msg_class##__ID, | 458 class msg_class : \ |
459 public IPC::MessageWithReply<Tuple0, Tuple2<type1_out&, type2_out&> > { \ | |
460 public: \ | |
461 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
462 msg_class(type1_out* arg1, type2_out* arg2); \ | |
463 ~msg_class(); \ | |
464 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
465 }; \ | |
466 IPC_SYNC_MESSAGE_CONTROL0_2_EXTRA(msg_class, type1_out, type2_out) | |
205 | 467 |
206 #define IPC_SYNC_MESSAGE_CONTROL0_3(msg_class, type1_out, type2_out, type3_out) \ | 468 #define IPC_SYNC_MESSAGE_CONTROL0_3(msg_class, type1_out, type2_out, type3_out) \ |
207 msg_class##__ID, | 469 class msg_class : \ |
208 | 470 public IPC::MessageWithReply<Tuple0, \ |
209 #define IPC_SYNC_MESSAGE_CONTROL1_0(msg_class, type1_in) \ | 471 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ |
210 msg_class##__ID, | 472 public: \ |
211 | 473 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ |
212 #define IPC_SYNC_MESSAGE_CONTROL1_1(msg_class, type1_in, type1_out) \ | 474 msg_class(type1_out* arg1, type2_out* arg2, type3_out* arg3); \ |
213 msg_class##__ID, | 475 ~msg_class(); \ |
476 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
477 }; \ | |
478 IPC_SYNC_MESSAGE_CONTROL0_3_EXTRA(msg_class, type1_out, type2_out, type3_out) | |
479 | |
480 #define IPC_SYNC_MESSAGE_CONTROL1_0(msg_class, type1_in) \ | |
481 class msg_class : \ | |
482 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple0 > { \ | |
483 public: \ | |
484 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
485 msg_class(const type1_in& arg1); \ | |
486 ~msg_class(); \ | |
487 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
488 }; \ | |
489 IPC_SYNC_MESSAGE_CONTROL1_0_EXTRA(msg_class, type1_in) | |
490 | |
491 #define IPC_SYNC_MESSAGE_CONTROL1_1(msg_class, type1_in, type1_out) \ | |
492 class msg_class : \ | |
493 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple1<type1_out&> > { \ | |
494 public: \ | |
495 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
496 msg_class(const type1_in& arg1, type1_out* arg2); \ | |
497 ~msg_class(); \ | |
498 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
499 }; \ | |
500 IPC_SYNC_MESSAGE_CONTROL1_1_EXTRA(msg_class, type1_in, type1_out) | |
214 | 501 |
215 #define IPC_SYNC_MESSAGE_CONTROL1_2(msg_class, type1_in, type1_out, type2_out) \ | 502 #define IPC_SYNC_MESSAGE_CONTROL1_2(msg_class, type1_in, type1_out, type2_out) \ |
216 msg_class##__ID, | 503 class msg_class : \ |
504 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple2<type1_out&, type2_ou t&> > { \ | |
505 public: \ | |
506 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
507 msg_class(const type1_in& arg1, type1_out* arg2, type2_out* arg3); \ | |
508 ~msg_class(); \ | |
509 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
510 }; \ | |
511 IPC_SYNC_MESSAGE_CONTROL1_2_EXTRA(msg_class, type1_in, type1_out, type2_out) | |
217 | 512 |
218 #define IPC_SYNC_MESSAGE_CONTROL1_3(msg_class, type1_in, type1_out, type2_out, t ype3_out) \ | 513 #define IPC_SYNC_MESSAGE_CONTROL1_3(msg_class, type1_in, type1_out, type2_out, t ype3_out) \ |
219 msg_class##__ID, | 514 class msg_class : \ |
220 | 515 public IPC::MessageWithReply<Tuple1<type1_in>, \ |
221 #define IPC_SYNC_MESSAGE_CONTROL2_0(msg_class, type1_in, type2_in) \ | 516 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ |
222 msg_class##__ID, | 517 public: \ |
518 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
519 msg_class(const type1_in& arg1, type1_out* arg2, type2_out* arg3, type3_out* arg4); \ | |
520 ~msg_class(); \ | |
521 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
522 }; \ | |
523 IPC_SYNC_MESSAGE_CONTROL1_3_EXTRA(msg_class, type1_in, type1_out, type2_out, t ype3_out) | |
524 | |
525 #define IPC_SYNC_MESSAGE_CONTROL2_0(msg_class, type1_in, type2_in) \ | |
526 class msg_class : \ | |
527 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple0 > { \ | |
528 public: \ | |
529 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
530 msg_class(const type1_in& arg1, const type2_in& arg2); \ | |
531 ~msg_class(); \ | |
532 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
533 }; \ | |
534 IPC_SYNC_MESSAGE_CONTROL2_0_EXTRA(msg_class, type1_in, type2_in) | |
223 | 535 |
224 #define IPC_SYNC_MESSAGE_CONTROL2_1(msg_class, type1_in, type2_in, type1_out) \ | 536 #define IPC_SYNC_MESSAGE_CONTROL2_1(msg_class, type1_in, type2_in, type1_out) \ |
225 msg_class##__ID, | 537 class msg_class : \ |
538 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple1<type1_out& > > { \ | |
539 public: \ | |
540 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
541 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3); \ | |
542 ~msg_class(); \ | |
543 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
544 }; \ | |
545 IPC_SYNC_MESSAGE_CONTROL2_1_EXTRA(msg_class, type1_in, type2_in, type1_out) | |
226 | 546 |
227 #define IPC_SYNC_MESSAGE_CONTROL2_2(msg_class, type1_in, type2_in, type1_out, ty pe2_out) \ | 547 #define IPC_SYNC_MESSAGE_CONTROL2_2(msg_class, type1_in, type2_in, type1_out, ty pe2_out) \ |
228 msg_class##__ID, | 548 class msg_class : \ |
549 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
550 Tuple2<type1_out&, type2_out&> > { \ | |
551 public: \ | |
552 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
553 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3, type2 _out* arg4); \ | |
554 ~msg_class(); \ | |
555 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
556 }; \ | |
557 IPC_SYNC_MESSAGE_CONTROL2_2_EXTRA(msg_class, type1_in, type2_in, type1_out, ty pe2_out) | |
229 | 558 |
230 #define IPC_SYNC_MESSAGE_CONTROL2_3(msg_class, type1_in, type2_in, type1_out, ty pe2_out, type3_out) \ | 559 #define IPC_SYNC_MESSAGE_CONTROL2_3(msg_class, type1_in, type2_in, type1_out, ty pe2_out, type3_out) \ |
231 msg_class##__ID, | 560 class msg_class : \ |
561 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
562 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
563 public: \ | |
564 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
565 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3, type2 _out* arg4, type3_out* arg5); \ | |
566 ~msg_class(); \ | |
567 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
568 }; \ | |
569 IPC_SYNC_MESSAGE_CONTROL2_3_EXTRA(msg_class, type1_in, type2_in, type1_out, ty pe2_out, type3_out) | |
232 | 570 |
233 #define IPC_SYNC_MESSAGE_CONTROL3_1(msg_class, type1_in, type2_in, type3_in, typ e1_out) \ | 571 #define IPC_SYNC_MESSAGE_CONTROL3_1(msg_class, type1_in, type2_in, type3_in, typ e1_out) \ |
234 msg_class##__ID, | 572 class msg_class : \ |
573 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
574 Tuple1<type1_out&> > { \ | |
575 public: \ | |
576 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
577 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4); \ | |
578 ~msg_class(); \ | |
579 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
580 }; \ | |
581 IPC_SYNC_MESSAGE_CONTROL3_1_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e1_out) | |
235 | 582 |
236 #define IPC_SYNC_MESSAGE_CONTROL3_2(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out) \ | 583 #define IPC_SYNC_MESSAGE_CONTROL3_2(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out) \ |
237 msg_class##__ID, | 584 class msg_class : \ |
585 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
586 Tuple2<type1_out&, type2_out&> > { \ | |
587 public: \ | |
588 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
589 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5); \ | |
590 ~msg_class(); \ | |
591 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
592 }; \ | |
593 IPC_SYNC_MESSAGE_CONTROL3_2_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out) | |
238 | 594 |
239 #define IPC_SYNC_MESSAGE_CONTROL3_3(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out) \ | 595 #define IPC_SYNC_MESSAGE_CONTROL3_3(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out) \ |
240 msg_class##__ID, | 596 class msg_class : \ |
597 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
598 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
599 public: \ | |
600 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
601 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6); \ | |
602 ~msg_class(); \ | |
603 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
604 }; \ | |
605 IPC_SYNC_MESSAGE_CONTROL3_3_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out) | |
241 | 606 |
242 #define IPC_SYNC_MESSAGE_CONTROL3_4(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out, type4_out) \ | 607 #define IPC_SYNC_MESSAGE_CONTROL3_4(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out, type4_out) \ |
243 msg_class##__ID, | 608 class msg_class : \ |
609 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
610 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> > { \ | |
611 public: \ | |
612 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
613 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6, type4_out* arg7); \ | |
614 ~msg_class(); \ | |
615 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
616 }; \ | |
617 IPC_SYNC_MESSAGE_CONTROL3_4_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out, type4_out) | |
244 | 618 |
245 #define IPC_SYNC_MESSAGE_CONTROL4_1(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out) \ | 619 #define IPC_SYNC_MESSAGE_CONTROL4_1(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out) \ |
246 msg_class##__ID, | 620 class msg_class : \ |
621 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
622 Tuple1<type1_out&> > { \ | |
623 public: \ | |
624 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
625 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, type1_out* arg6); \ | |
626 ~msg_class(); \ | |
627 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
628 }; \ | |
629 IPC_SYNC_MESSAGE_CONTROL4_1_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out) | |
247 | 630 |
248 #define IPC_SYNC_MESSAGE_CONTROL4_2(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out, type2_out) \ | 631 #define IPC_SYNC_MESSAGE_CONTROL4_2(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out, type2_out) \ |
249 msg_class##__ID, | 632 class msg_class : \ |
633 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
634 Tuple2<type1_out&, type2_out&> > { \ | |
635 public: \ | |
636 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
637 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, type1_out* arg5, type2_out* arg6); \ | |
638 ~msg_class(); \ | |
639 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
640 }; \ | |
641 IPC_SYNC_MESSAGE_CONTROL4_2_EXTRA(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out, type2_out) | |
250 | 642 |
251 #define IPC_SYNC_MESSAGE_ROUTED0_0(msg_class) \ | 643 #define IPC_SYNC_MESSAGE_ROUTED0_0(msg_class) \ |
252 msg_class##__ID, | 644 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple0 > { \ |
645 public: \ | |
646 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
647 msg_class(int routing_id); \ | |
648 ~msg_class(); \ | |
649 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
650 }; \ | |
651 IPC_SYNC_MESSAGE_ROUTED0_0_EXTRA(msg_class) | |
253 | 652 |
254 #define IPC_SYNC_MESSAGE_ROUTED0_1(msg_class, type1_out) \ | 653 #define IPC_SYNC_MESSAGE_ROUTED0_1(msg_class, type1_out) \ |
255 msg_class##__ID, | 654 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple1<type1_out&> > { \ |
655 public: \ | |
656 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
657 msg_class(int routing_id, type1_out* arg1); \ | |
658 ~msg_class(); \ | |
659 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
660 }; \ | |
661 IPC_SYNC_MESSAGE_ROUTED0_1_EXTRA(msg_class, type1_out) | |
256 | 662 |
257 #define IPC_SYNC_MESSAGE_ROUTED0_2(msg_class, type1_out, type2_out) \ | 663 #define IPC_SYNC_MESSAGE_ROUTED0_2(msg_class, type1_out, type2_out) \ |
258 msg_class##__ID, | 664 class msg_class : \ |
665 public IPC::MessageWithReply<Tuple0, Tuple2<type1_out&, type2_out&> > { \ | |
666 public: \ | |
667 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
668 msg_class(int routing_id, type1_out* arg1, type2_out* arg2); \ | |
669 ~msg_class(); \ | |
670 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
671 }; \ | |
672 IPC_SYNC_MESSAGE_ROUTED0_2_EXTRA(msg_class, type1_out, type2_out) | |
259 | 673 |
260 #define IPC_SYNC_MESSAGE_ROUTED0_3(msg_class, type1_out, type2_out, type3_out) \ | 674 #define IPC_SYNC_MESSAGE_ROUTED0_3(msg_class, type1_out, type2_out, type3_out) \ |
261 msg_class##__ID, | 675 class msg_class : \ |
676 public IPC::MessageWithReply<Tuple0, \ | |
677 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
678 public: \ | |
679 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
680 msg_class(int routing_id, type1_out* arg1, type2_out* arg2, type3_out* arg3) ; \ | |
681 ~msg_class(); \ | |
682 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
683 }; \ | |
684 IPC_SYNC_MESSAGE_ROUTED0_3_EXTRA(msg_class, type1_out, type2_out, type3_out) | |
262 | 685 |
263 #define IPC_SYNC_MESSAGE_ROUTED1_0(msg_class, type1_in) \ | 686 #define IPC_SYNC_MESSAGE_ROUTED1_0(msg_class, type1_in) \ |
264 msg_class##__ID, | 687 class msg_class : \ |
688 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple0 > { \ | |
689 public: \ | |
690 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
691 msg_class(int routing_id, const type1_in& arg1); \ | |
692 ~msg_class(); \ | |
693 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
694 }; \ | |
695 IPC_SYNC_MESSAGE_ROUTED1_0_EXTRA(msg_class, type1_in) | |
265 | 696 |
266 #define IPC_SYNC_MESSAGE_ROUTED1_1(msg_class, type1_in, type1_out) \ | 697 #define IPC_SYNC_MESSAGE_ROUTED1_1(msg_class, type1_in, type1_out) \ |
267 msg_class##__ID, | 698 class msg_class : \ |
699 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple1<type1_out&> > { \ | |
700 public: \ | |
701 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
702 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2); \ | |
703 ~msg_class(); \ | |
704 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
705 }; \ | |
706 IPC_SYNC_MESSAGE_ROUTED1_1_EXTRA(msg_class, type1_in, type1_out) | |
268 | 707 |
269 #define IPC_SYNC_MESSAGE_ROUTED1_2(msg_class, type1_in, type1_out, type2_out) \ | 708 #define IPC_SYNC_MESSAGE_ROUTED1_2(msg_class, type1_in, type1_out, type2_out) \ |
270 msg_class##__ID, | 709 class msg_class : \ |
710 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple2<type1_out&, type2_ou t&> > { \ | |
711 public: \ | |
712 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
713 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* arg3); \ | |
714 ~msg_class(); \ | |
715 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
716 }; \ | |
717 IPC_SYNC_MESSAGE_ROUTED1_2_EXTRA(msg_class, type1_in, type1_out, type2_out) | |
271 | 718 |
272 #define IPC_SYNC_MESSAGE_ROUTED1_3(msg_class, type1_in, type1_out, type2_out, ty pe3_out) \ | 719 #define IPC_SYNC_MESSAGE_ROUTED1_3(msg_class, type1_in, type1_out, type2_out, ty pe3_out) \ |
273 msg_class##__ID, | 720 class msg_class : \ |
721 public IPC::MessageWithReply<Tuple1<type1_in>, \ | |
722 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
723 public: \ | |
724 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
725 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* arg3, type3_out* arg4); \ | |
726 ~msg_class(); \ | |
727 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
728 }; \ | |
729 IPC_SYNC_MESSAGE_ROUTED1_3_EXTRA(msg_class, type1_in, type1_out, type2_out, ty pe3_out) | |
274 | 730 |
275 #define IPC_SYNC_MESSAGE_ROUTED1_4(msg_class, type1_in, type1_out, type2_out, ty pe3_out, type4_out) \ | 731 #define IPC_SYNC_MESSAGE_ROUTED1_4(msg_class, type1_in, type1_out, type2_out, ty pe3_out, type4_out) \ |
276 msg_class##__ID, | 732 class msg_class : \ |
733 public IPC::MessageWithReply<Tuple1<type1_in>, \ | |
734 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> >{ \ | |
735 public: \ | |
736 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
737 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* arg3, type3_out* arg4, type4_out* arg5); \ | |
738 ~msg_class(); \ | |
739 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
740 }; \ | |
741 IPC_SYNC_MESSAGE_ROUTED1_4_EXTRA(msg_class, type1_in, type1_out, type2_out, ty pe3_out, type4_out) | |
277 | 742 |
278 #define IPC_SYNC_MESSAGE_ROUTED2_0(msg_class, type1_in, type2_in) \ | 743 #define IPC_SYNC_MESSAGE_ROUTED2_0(msg_class, type1_in, type2_in) \ |
279 msg_class##__ID, | 744 class msg_class : \ |
745 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple0 > { \ | |
746 public: \ | |
747 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
748 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2); \ | |
749 ~msg_class(); \ | |
750 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
751 }; \ | |
752 IPC_SYNC_MESSAGE_ROUTED2_0_EXTRA(msg_class, type1_in, type2_in) | |
280 | 753 |
281 #define IPC_SYNC_MESSAGE_ROUTED2_1(msg_class, type1_in, type2_in, type1_out) \ | 754 #define IPC_SYNC_MESSAGE_ROUTED2_1(msg_class, type1_in, type2_in, type1_out) \ |
282 msg_class##__ID, | 755 class msg_class : \ |
756 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple1<type1_out& > > { \ | |
757 public: \ | |
758 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
759 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_ out* arg3); \ | |
760 ~msg_class(); \ | |
761 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
762 }; \ | |
763 IPC_SYNC_MESSAGE_ROUTED2_1_EXTRA(msg_class, type1_in, type2_in, type1_out) | |
283 | 764 |
284 #define IPC_SYNC_MESSAGE_ROUTED2_2(msg_class, type1_in, type2_in, type1_out, typ e2_out) \ | 765 #define IPC_SYNC_MESSAGE_ROUTED2_2(msg_class, type1_in, type2_in, type1_out, typ e2_out) \ |
285 msg_class##__ID, | 766 class msg_class : \ |
767 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
768 Tuple2<type1_out&, type2_out&> > { \ | |
769 public: \ | |
770 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
771 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_ out* arg3, type2_out* arg4); \ | |
772 ~msg_class(); \ | |
773 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
774 }; \ | |
775 IPC_SYNC_MESSAGE_ROUTED2_2_EXTRA(msg_class, type1_in, type2_in, type1_out, typ e2_out) | |
286 | 776 |
287 #define IPC_SYNC_MESSAGE_ROUTED2_3(msg_class, type1_in, type2_in, type1_out, typ e2_out, type3_out) \ | 777 #define IPC_SYNC_MESSAGE_ROUTED2_3(msg_class, type1_in, type2_in, type1_out, typ e2_out, type3_out) \ |
288 msg_class##__ID, | 778 class msg_class : \ |
779 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
780 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
781 public: \ | |
782 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
783 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_ out* arg3, type2_out* arg4, type3_out* arg5); \ | |
784 ~msg_class(); \ | |
785 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
786 }; \ | |
787 IPC_SYNC_MESSAGE_ROUTED2_3_EXTRA(msg_class, type1_in, type2_in, type1_out, typ e2_out, type3_out) | |
289 | 788 |
290 #define IPC_SYNC_MESSAGE_ROUTED3_0(msg_class, type1_in, type2_in, type3_in) \ | 789 #define IPC_SYNC_MESSAGE_ROUTED3_0(msg_class, type1_in, type2_in, type3_in) \ |
291 msg_class##__ID, | 790 class msg_class : \ |
791 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, Tuple0 > { \ | |
792 public: \ | |
793 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
794 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3); \ | |
795 ~msg_class(); \ | |
796 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
797 }; \ | |
798 IPC_SYNC_MESSAGE_ROUTED3_0_EXTRA(msg_class, type1_in, type2_in, type3_in) | |
292 | 799 |
293 #define IPC_SYNC_MESSAGE_ROUTED3_1(msg_class, type1_in, type2_in, type3_in, type 1_out) \ | 800 #define IPC_SYNC_MESSAGE_ROUTED3_1(msg_class, type1_in, type2_in, type3_in, type 1_out) \ |
294 msg_class##__ID, | 801 class msg_class : \ |
802 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
803 Tuple1<type1_out&> > { \ | |
804 public: \ | |
805 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
806 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4); \ | |
807 ~msg_class(); \ | |
808 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
809 }; \ | |
810 IPC_SYNC_MESSAGE_ROUTED3_1_EXTRA(msg_class, type1_in, type2_in, type3_in, type 1_out) | |
295 | 811 |
296 #define IPC_SYNC_MESSAGE_ROUTED3_2(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out) \ | 812 #define IPC_SYNC_MESSAGE_ROUTED3_2(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out) \ |
297 msg_class##__ID, | 813 class msg_class : \ |
814 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
815 Tuple2<type1_out&, type2_out&> > { \ | |
816 public: \ | |
817 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
818 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5); \ | |
819 ~msg_class(); \ | |
820 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
821 }; \ | |
822 IPC_SYNC_MESSAGE_ROUTED3_2_EXTRA(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out) | |
298 | 823 |
299 #define IPC_SYNC_MESSAGE_ROUTED3_3(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out) \ | 824 #define IPC_SYNC_MESSAGE_ROUTED3_3(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out) \ |
300 msg_class##__ID, | 825 class msg_class : \ |
826 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
827 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
828 public: \ | |
829 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
830 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6); \ | |
831 ~msg_class(); \ | |
832 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
833 }; \ | |
834 IPC_SYNC_MESSAGE_ROUTED3_3_EXTRA(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out) | |
301 | 835 |
302 #define IPC_SYNC_MESSAGE_ROUTED3_4(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out, type4_out) \ | 836 #define IPC_SYNC_MESSAGE_ROUTED3_4(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out, type4_out) \ |
303 msg_class##__ID, | 837 class msg_class : \ |
838 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
839 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> > { \ | |
840 public: \ | |
841 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
842 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6, type4_out* ar g7); \ | |
843 ~msg_class(); \ | |
844 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
845 }; \ | |
846 IPC_SYNC_MESSAGE_ROUTED3_4_EXTRA(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out, type4_out) | |
304 | 847 |
305 #define IPC_SYNC_MESSAGE_ROUTED4_0(msg_class, type1_in, type2_in, type3_in, type 4_in) \ | 848 #define IPC_SYNC_MESSAGE_ROUTED4_0(msg_class, type1_in, type2_in, type3_in, type 4_in) \ |
306 msg_class##__ID, | 849 class msg_class : \ |
850 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
851 Tuple0 > { \ | |
852 public: \ | |
853 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
854 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4); \ | |
855 ~msg_class(); \ | |
856 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
857 }; \ | |
858 IPC_SYNC_MESSAGE_ROUTED4_0_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in) | |
307 | 859 |
308 #define IPC_SYNC_MESSAGE_ROUTED4_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out) \ | 860 #define IPC_SYNC_MESSAGE_ROUTED4_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out) \ |
309 msg_class##__ID, | 861 class msg_class : \ |
862 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
863 Tuple1<type1_out&> > { \ | |
864 public: \ | |
865 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
866 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, type1_out* arg6); \ | |
867 ~msg_class(); \ | |
868 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
869 }; \ | |
870 IPC_SYNC_MESSAGE_ROUTED4_1_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out) | |
310 | 871 |
311 #define IPC_SYNC_MESSAGE_ROUTED4_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out) \ | 872 #define IPC_SYNC_MESSAGE_ROUTED4_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out) \ |
312 msg_class##__ID, | 873 class msg_class : \ |
874 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
875 Tuple2<type1_out&, type2_out&> > { \ | |
876 public: \ | |
877 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
878 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, type1_out* arg5, type2_out* arg6); \ | |
879 ~msg_class(); \ | |
880 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
881 }; \ | |
882 IPC_SYNC_MESSAGE_ROUTED4_2_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out) | |
313 | 883 |
314 #define IPC_SYNC_MESSAGE_ROUTED4_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out, type3_out) \ | 884 #define IPC_SYNC_MESSAGE_ROUTED4_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out, type3_out) \ |
315 msg_class##__ID, | 885 class msg_class : \ |
886 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
887 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
888 public: \ | |
889 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
890 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, type1_out* arg5, type2_out* arg6, type3_ou t* arg7); \ | |
891 ~msg_class(); \ | |
892 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
893 }; \ | |
894 IPC_SYNC_MESSAGE_ROUTED4_3_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out, type3_out) | |
316 | 895 |
317 #define IPC_SYNC_MESSAGE_ROUTED5_0(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in) \ | 896 #define IPC_SYNC_MESSAGE_ROUTED5_0(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in) \ |
318 msg_class##__ID, | 897 class msg_class : \ |
898 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
899 Tuple0 > { \ | |
900 public: \ | |
901 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
902 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, const type5_in& arg5); \ | |
903 ~msg_class(); \ | |
904 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
905 }; \ | |
906 IPC_SYNC_MESSAGE_ROUTED5_0_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in) | |
319 | 907 |
320 #define IPC_SYNC_MESSAGE_ROUTED5_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out) \ | 908 #define IPC_SYNC_MESSAGE_ROUTED5_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out) \ |
321 msg_class##__ID, | 909 class msg_class : \ |
910 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
911 Tuple1<type1_out&> > { \ | |
912 public: \ | |
913 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
914 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, const type5_in& arg5, type1_out* arg6); \ | |
915 ~msg_class(); \ | |
916 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
917 }; \ | |
918 IPC_SYNC_MESSAGE_ROUTED5_1_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out) | |
322 | 919 |
323 #define IPC_SYNC_MESSAGE_ROUTED5_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out) \ | 920 #define IPC_SYNC_MESSAGE_ROUTED5_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out) \ |
324 msg_class##__ID, | 921 class msg_class : \ |
922 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
923 Tuple2<type1_out&, type2_out&> > { \ | |
924 public: \ | |
925 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
926 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, const type4_in& arg5, type1_out* arg6, typ e2_out* arg7); \ | |
927 ~msg_class(); \ | |
928 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
929 }; \ | |
930 IPC_SYNC_MESSAGE_ROUTED5_2_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out) | |
325 | 931 |
326 #define IPC_SYNC_MESSAGE_ROUTED5_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out, type3_out) \ | 932 #define IPC_SYNC_MESSAGE_ROUTED5_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out, type3_out) \ |
327 msg_class##__ID, | 933 class msg_class : \ |
934 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
935 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
936 public: \ | |
937 enum { ID = (IPC_MESSAGE_START << 16) + __LINE__ }; \ | |
938 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, const type4_in& arg4, const type4_in& arg5, type1_out* arg6, typ e2_out* arg7, type3_out* arg8); \ | |
939 ~msg_class(); \ | |
940 static void Log(std::string* name, const Message* msg, std::string* l); \ | |
941 }; \ | |
942 IPC_SYNC_MESSAGE_ROUTED5_3_EXTRA(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out, type3_out) | |
943 | |
944 | |
328 | 945 |
329 // Message crackers and handlers. | 946 // Message crackers and handlers. |
330 // Prefer to use the IPC_BEGIN_MESSAGE_MAP_EX to the older macros since they | 947 // Prefer to use the IPC_BEGIN_MESSAGE_MAP_EX to the older macros since they |
331 // allow you to detect when a message could not be de-serialized. Usage: | 948 // allow you to detect when a message could not be de-serialized. Usage: |
332 // | 949 // |
333 // void MyClass::OnMessageReceived(const IPC::Message& msg) { | 950 // void MyClass::OnMessageReceived(const IPC::Message& msg) { |
334 // bool msg_is_good = false; | 951 // bool msg_is_good = false; |
335 // IPC_BEGIN_MESSAGE_MAP_EX(MyClass, msg, msg_is_good) | 952 // IPC_BEGIN_MESSAGE_MAP_EX(MyClass, msg, msg_is_good) |
336 // IPC_MESSAGE_HANDLER(MsgClassOne, OnMsgClassOne) | 953 // IPC_MESSAGE_HANDLER(MsgClassOne, OnMsgClassOne) |
337 // ...more handlers here ... | 954 // ...more handlers here ... |
338 // IPC_MESSAGE_HANDLER(MsgClassTen, OnMsgClassTen) | 955 // IPC_MESSAGE_HANDLER(MsgClassTen, OnMsgClassTen) |
339 // IPC_END_MESSAGE_MAP_EX() | 956 // IPC_END_MESSAGE_MAP_EX() |
340 // if (!msg_is_good) { | 957 // if (!msg_is_good) { |
341 // // Signal error here or terminate offending process. | 958 // // Signal error here or terminate offending process. |
342 // } | 959 // } |
343 // } | 960 // } |
344 | 961 |
962 | |
345 #define IPC_DEFINE_MESSAGE_MAP(class_name) \ | 963 #define IPC_DEFINE_MESSAGE_MAP(class_name) \ |
346 void class_name::OnMessageReceived(const IPC::Message& msg) \ | 964 void class_name::OnMessageReceived(const IPC::Message& msg) \ |
347 IPC_BEGIN_MESSAGE_MAP(class_name, msg) | 965 IPC_BEGIN_MESSAGE_MAP(class_name, msg) |
348 | 966 |
349 #define IPC_BEGIN_MESSAGE_MAP_EX(class_name, msg, msg_is_ok) \ | 967 #define IPC_BEGIN_MESSAGE_MAP_EX(class_name, msg, msg_is_ok) \ |
350 { \ | 968 { \ |
351 typedef class_name _IpcMessageHandlerClass; \ | 969 typedef class_name _IpcMessageHandlerClass; \ |
352 const IPC::Message& ipc_message__ = msg; \ | 970 const IPC::Message& ipc_message__ = msg; \ |
353 bool& msg_is_ok__ = msg_is_ok; \ | 971 bool& msg_is_ok__ = msg_is_ok; \ |
354 switch (ipc_message__.type()) { \ | 972 switch (ipc_message__.type()) { \ |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
398 "Invalid message with type = " << \ | 1016 "Invalid message with type = " << \ |
399 ipc_message__.type()) | 1017 ipc_message__.type()) |
400 | 1018 |
401 #define IPC_END_MESSAGE_MAP() \ | 1019 #define IPC_END_MESSAGE_MAP() \ |
402 DCHECK(msg_is_ok__); \ | 1020 DCHECK(msg_is_ok__); \ |
403 } \ | 1021 } \ |
404 } | 1022 } |
405 | 1023 |
406 #define IPC_END_MESSAGE_MAP_EX() \ | 1024 #define IPC_END_MESSAGE_MAP_EX() \ |
407 } \ | 1025 } \ |
408 } | 1026 } |
409 | |
410 #elif defined(IPC_MESSAGE_MACROS_LOG) | |
411 #undef IPC_MESSAGE_MACROS_LOG | |
412 | |
413 | |
414 // Undefine the macros from the previous pass (if any). | |
415 #undef IPC_BEGIN_MESSAGES | |
416 #undef IPC_END_MESSAGES | |
417 #undef IPC_MESSAGE_CONTROL0 | |
418 #undef IPC_MESSAGE_CONTROL1 | |
419 #undef IPC_MESSAGE_CONTROL2 | |
420 #undef IPC_MESSAGE_CONTROL3 | |
421 #undef IPC_MESSAGE_CONTROL4 | |
422 #undef IPC_MESSAGE_CONTROL5 | |
423 #undef IPC_MESSAGE_ROUTED0 | |
424 #undef IPC_MESSAGE_ROUTED1 | |
425 #undef IPC_MESSAGE_ROUTED2 | |
426 #undef IPC_MESSAGE_ROUTED3 | |
427 #undef IPC_MESSAGE_ROUTED4 | |
428 #undef IPC_MESSAGE_ROUTED5 | |
429 #undef IPC_SYNC_MESSAGE_CONTROL0_0 | |
430 #undef IPC_SYNC_MESSAGE_CONTROL0_1 | |
431 #undef IPC_SYNC_MESSAGE_CONTROL0_2 | |
432 #undef IPC_SYNC_MESSAGE_CONTROL0_3 | |
433 #undef IPC_SYNC_MESSAGE_CONTROL1_0 | |
434 #undef IPC_SYNC_MESSAGE_CONTROL1_1 | |
435 #undef IPC_SYNC_MESSAGE_CONTROL1_2 | |
436 #undef IPC_SYNC_MESSAGE_CONTROL1_3 | |
437 #undef IPC_SYNC_MESSAGE_CONTROL2_0 | |
438 #undef IPC_SYNC_MESSAGE_CONTROL2_1 | |
439 #undef IPC_SYNC_MESSAGE_CONTROL2_2 | |
440 #undef IPC_SYNC_MESSAGE_CONTROL2_3 | |
441 #undef IPC_SYNC_MESSAGE_CONTROL3_1 | |
442 #undef IPC_SYNC_MESSAGE_CONTROL3_2 | |
443 #undef IPC_SYNC_MESSAGE_CONTROL3_3 | |
444 #undef IPC_SYNC_MESSAGE_CONTROL3_4 | |
445 #undef IPC_SYNC_MESSAGE_CONTROL4_1 | |
446 #undef IPC_SYNC_MESSAGE_CONTROL4_2 | |
447 #undef IPC_SYNC_MESSAGE_ROUTED0_0 | |
448 #undef IPC_SYNC_MESSAGE_ROUTED0_1 | |
449 #undef IPC_SYNC_MESSAGE_ROUTED0_2 | |
450 #undef IPC_SYNC_MESSAGE_ROUTED0_3 | |
451 #undef IPC_SYNC_MESSAGE_ROUTED1_0 | |
452 #undef IPC_SYNC_MESSAGE_ROUTED1_1 | |
453 #undef IPC_SYNC_MESSAGE_ROUTED1_2 | |
454 #undef IPC_SYNC_MESSAGE_ROUTED1_3 | |
455 #undef IPC_SYNC_MESSAGE_ROUTED1_4 | |
456 #undef IPC_SYNC_MESSAGE_ROUTED2_0 | |
457 #undef IPC_SYNC_MESSAGE_ROUTED2_1 | |
458 #undef IPC_SYNC_MESSAGE_ROUTED2_2 | |
459 #undef IPC_SYNC_MESSAGE_ROUTED2_3 | |
460 #undef IPC_SYNC_MESSAGE_ROUTED3_0 | |
461 #undef IPC_SYNC_MESSAGE_ROUTED3_1 | |
462 #undef IPC_SYNC_MESSAGE_ROUTED3_2 | |
463 #undef IPC_SYNC_MESSAGE_ROUTED3_3 | |
464 #undef IPC_SYNC_MESSAGE_ROUTED3_4 | |
465 #undef IPC_SYNC_MESSAGE_ROUTED4_0 | |
466 #undef IPC_SYNC_MESSAGE_ROUTED4_1 | |
467 #undef IPC_SYNC_MESSAGE_ROUTED4_2 | |
468 #undef IPC_SYNC_MESSAGE_ROUTED4_3 | |
469 #undef IPC_SYNC_MESSAGE_ROUTED5_0 | |
470 #undef IPC_SYNC_MESSAGE_ROUTED5_1 | |
471 #undef IPC_SYNC_MESSAGE_ROUTED5_2 | |
472 #undef IPC_SYNC_MESSAGE_ROUTED5_3 | |
473 | |
474 #ifndef IPC_LOG_TABLE_CREATED | |
475 #define IPC_LOG_TABLE_CREATED | |
476 typedef void (*LogFunction)(uint32 type, | |
477 std::string* name, | |
478 const IPC::Message* msg, | |
479 std::string* params); | |
480 | |
481 LogFunction g_log_function_mapping[LastMsgIndex]; | |
482 #endif | |
483 | |
484 | |
485 #define IPC_BEGIN_MESSAGES(label) \ | |
486 void label##MsgLog(uint32 type, std::string* name, const IPC::Message* msg, \ | |
487 std::string* params) { \ | |
488 switch (type) { | |
489 | |
490 #define IPC_END_MESSAGES(label) \ | |
491 default: \ | |
492 if (name) \ | |
493 *name = "[UNKNOWN " #label " MSG]"; \ | |
494 } \ | |
495 } \ | |
496 class LoggerRegisterHelper##label { \ | |
497 public: \ | |
498 LoggerRegisterHelper##label() { \ | |
499 g_log_function_mapping[label##MsgStart] = label##MsgLog; \ | |
500 } \ | |
501 }; \ | |
502 LoggerRegisterHelper##label g_LoggerRegisterHelper##label; | |
503 | |
504 #define IPC_MESSAGE_LOG(msg_class) \ | |
505 case msg_class##__ID: \ | |
506 if (name) \ | |
507 *name = #msg_class; \ | |
508 if (msg && params) \ | |
509 msg_class::Log(msg, params); \ | |
510 break; | |
511 | |
512 #define IPC_MESSAGE_CONTROL0(msg_class) \ | |
513 IPC_MESSAGE_LOG(msg_class) | |
514 | |
515 #define IPC_MESSAGE_CONTROL1(msg_class, type1) \ | |
516 IPC_MESSAGE_LOG(msg_class) | |
517 | |
518 #define IPC_MESSAGE_CONTROL2(msg_class, type1, type2) \ | |
519 IPC_MESSAGE_LOG(msg_class) | |
520 | |
521 #define IPC_MESSAGE_CONTROL3(msg_class, type1, type2, type3) \ | |
522 IPC_MESSAGE_LOG(msg_class) | |
523 | |
524 #define IPC_MESSAGE_CONTROL4(msg_class, type1, type2, type3, type4) \ | |
525 IPC_MESSAGE_LOG(msg_class) | |
526 | |
527 #define IPC_MESSAGE_CONTROL5(msg_class, type1, type2, type3, type4, type5) \ | |
528 IPC_MESSAGE_LOG(msg_class) | |
529 | |
530 #define IPC_MESSAGE_ROUTED0(msg_class) \ | |
531 IPC_MESSAGE_LOG(msg_class) | |
532 | |
533 #define IPC_MESSAGE_ROUTED1(msg_class, type1) \ | |
534 IPC_MESSAGE_LOG(msg_class) | |
535 | |
536 #define IPC_MESSAGE_ROUTED2(msg_class, type1, type2) \ | |
537 IPC_MESSAGE_LOG(msg_class) | |
538 | |
539 #define IPC_MESSAGE_ROUTED3(msg_class, type1, type2, type3) \ | |
540 IPC_MESSAGE_LOG(msg_class) | |
541 | |
542 #define IPC_MESSAGE_ROUTED4(msg_class, type1, type2, type3, type4) \ | |
543 IPC_MESSAGE_LOG(msg_class) | |
544 | |
545 #define IPC_MESSAGE_ROUTED5(msg_class, type1, type2, type3, type4, type5) \ | |
546 IPC_MESSAGE_LOG(msg_class) | |
547 | |
548 #define IPC_SYNC_MESSAGE_CONTROL0_0(msg_class) \ | |
549 IPC_MESSAGE_LOG(msg_class) | |
550 | |
551 #define IPC_SYNC_MESSAGE_CONTROL0_1(msg_class, type1_out) \ | |
552 IPC_MESSAGE_LOG(msg_class) | |
553 | |
554 #define IPC_SYNC_MESSAGE_CONTROL0_2(msg_class, type1_out, type2_out) \ | |
555 IPC_MESSAGE_LOG(msg_class) | |
556 | |
557 #define IPC_SYNC_MESSAGE_CONTROL0_3(msg_class, type1_out, type2_out, type3_out) \ | |
558 IPC_MESSAGE_LOG(msg_class) | |
559 | |
560 #define IPC_SYNC_MESSAGE_CONTROL1_0(msg_class, type1_in) \ | |
561 IPC_MESSAGE_LOG(msg_class) | |
562 | |
563 #define IPC_SYNC_MESSAGE_CONTROL1_1(msg_class, type1_in, type1_out) \ | |
564 IPC_MESSAGE_LOG(msg_class) | |
565 | |
566 #define IPC_SYNC_MESSAGE_CONTROL1_2(msg_class, type1_in, type1_out, type2_out) \ | |
567 IPC_MESSAGE_LOG(msg_class) | |
568 | |
569 #define IPC_SYNC_MESSAGE_CONTROL1_3(msg_class, type1_in, type1_out, type2_out, t ype3_out) \ | |
570 IPC_MESSAGE_LOG(msg_class) | |
571 | |
572 #define IPC_SYNC_MESSAGE_CONTROL2_0(msg_class, type1_in, type2_in) \ | |
573 IPC_MESSAGE_LOG(msg_class) | |
574 | |
575 #define IPC_SYNC_MESSAGE_CONTROL2_1(msg_class, type1_in, type2_in, type1_out) \ | |
576 IPC_MESSAGE_LOG(msg_class) | |
577 | |
578 #define IPC_SYNC_MESSAGE_CONTROL2_2(msg_class, type1_in, type2_in, type1_out, ty pe2_out) \ | |
579 IPC_MESSAGE_LOG(msg_class) | |
580 | |
581 #define IPC_SYNC_MESSAGE_CONTROL2_3(msg_class, type1_in, type2_in, type1_out, ty pe2_out, type3_out) \ | |
582 IPC_MESSAGE_LOG(msg_class) | |
583 | |
584 #define IPC_SYNC_MESSAGE_CONTROL3_1(msg_class, type1_in, type2_in, type3_in, typ e1_out) \ | |
585 IPC_MESSAGE_LOG(msg_class) | |
586 | |
587 #define IPC_SYNC_MESSAGE_CONTROL3_2(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out) \ | |
588 IPC_MESSAGE_LOG(msg_class) | |
589 | |
590 #define IPC_SYNC_MESSAGE_CONTROL3_3(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out) \ | |
591 IPC_MESSAGE_LOG(msg_class) | |
592 | |
593 #define IPC_SYNC_MESSAGE_CONTROL3_4(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out, type4_out) \ | |
594 IPC_MESSAGE_LOG(msg_class) | |
595 | |
596 #define IPC_SYNC_MESSAGE_CONTROL4_1(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out) \ | |
597 IPC_MESSAGE_LOG(msg_class) | |
598 | |
599 #define IPC_SYNC_MESSAGE_CONTROL4_2(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out, type2_out) \ | |
600 IPC_MESSAGE_LOG(msg_class) | |
601 | |
602 #define IPC_SYNC_MESSAGE_ROUTED0_0(msg_class) \ | |
603 IPC_MESSAGE_LOG(msg_class) | |
604 | |
605 #define IPC_SYNC_MESSAGE_ROUTED0_1(msg_class, type1_out) \ | |
606 IPC_MESSAGE_LOG(msg_class) | |
607 | |
608 #define IPC_SYNC_MESSAGE_ROUTED0_2(msg_class, type1_out, type2_out) \ | |
609 IPC_MESSAGE_LOG(msg_class) | |
610 | |
611 #define IPC_SYNC_MESSAGE_ROUTED0_3(msg_class, type1_out, type2_out, type3_out) \ | |
612 IPC_MESSAGE_LOG(msg_class) | |
613 | |
614 #define IPC_SYNC_MESSAGE_ROUTED1_0(msg_class, type1_in) \ | |
615 IPC_MESSAGE_LOG(msg_class) | |
616 | |
617 #define IPC_SYNC_MESSAGE_ROUTED1_1(msg_class, type1_in, type1_out) \ | |
618 IPC_MESSAGE_LOG(msg_class) | |
619 | |
620 #define IPC_SYNC_MESSAGE_ROUTED1_2(msg_class, type1_in, type1_out, type2_out) \ | |
621 IPC_MESSAGE_LOG(msg_class) | |
622 | |
623 #define IPC_SYNC_MESSAGE_ROUTED1_3(msg_class, type1_in, type1_out, type2_out, ty pe3_out) \ | |
624 IPC_MESSAGE_LOG(msg_class) | |
625 | |
626 #define IPC_SYNC_MESSAGE_ROUTED1_4(msg_class, type1_in, type1_out, type2_out, ty pe3_out, type4_out) \ | |
627 IPC_MESSAGE_LOG(msg_class) | |
628 | |
629 #define IPC_SYNC_MESSAGE_ROUTED2_0(msg_class, type1_in, type2_in) \ | |
630 IPC_MESSAGE_LOG(msg_class) | |
631 | |
632 #define IPC_SYNC_MESSAGE_ROUTED2_1(msg_class, type1_in, type2_in, type1_out) \ | |
633 IPC_MESSAGE_LOG(msg_class) | |
634 | |
635 #define IPC_SYNC_MESSAGE_ROUTED2_2(msg_class, type1_in, type2_in, type1_out, typ e2_out) \ | |
636 IPC_MESSAGE_LOG(msg_class) | |
637 | |
638 #define IPC_SYNC_MESSAGE_ROUTED2_3(msg_class, type1_in, type2_in, type1_out, typ e2_out, type3_out) \ | |
639 IPC_MESSAGE_LOG(msg_class) | |
640 | |
641 #define IPC_SYNC_MESSAGE_ROUTED3_0(msg_class, type1_in, type2_in, type3_in) \ | |
642 IPC_MESSAGE_LOG(msg_class) | |
643 | |
644 #define IPC_SYNC_MESSAGE_ROUTED3_1(msg_class, type1_in, type2_in, type3_in, type 1_out) \ | |
645 IPC_MESSAGE_LOG(msg_class) | |
646 | |
647 #define IPC_SYNC_MESSAGE_ROUTED3_2(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out) \ | |
648 IPC_MESSAGE_LOG(msg_class) | |
649 | |
650 #define IPC_SYNC_MESSAGE_ROUTED3_3(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out) \ | |
651 IPC_MESSAGE_LOG(msg_class) | |
652 | |
653 #define IPC_SYNC_MESSAGE_ROUTED3_4(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out, type4_out) \ | |
654 IPC_MESSAGE_LOG(msg_class) | |
655 | |
656 #define IPC_SYNC_MESSAGE_ROUTED4_0(msg_class, type1_in, type2_in, type3_in, type 4_in) \ | |
657 IPC_MESSAGE_LOG(msg_class) | |
658 | |
659 #define IPC_SYNC_MESSAGE_ROUTED4_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out) \ | |
660 IPC_MESSAGE_LOG(msg_class) | |
661 | |
662 #define IPC_SYNC_MESSAGE_ROUTED4_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out) \ | |
663 IPC_MESSAGE_LOG(msg_class) | |
664 | |
665 #define IPC_SYNC_MESSAGE_ROUTED4_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out, type3_out) \ | |
666 IPC_MESSAGE_LOG(msg_class) | |
667 | |
668 #define IPC_SYNC_MESSAGE_ROUTED5_0(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in) \ | |
669 IPC_MESSAGE_LOG(msg_class) | |
670 | |
671 #define IPC_SYNC_MESSAGE_ROUTED5_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out) \ | |
672 IPC_MESSAGE_LOG(msg_class) | |
673 | |
674 #define IPC_SYNC_MESSAGE_ROUTED5_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out) \ | |
675 IPC_MESSAGE_LOG(msg_class) | |
676 | |
677 #define IPC_SYNC_MESSAGE_ROUTED5_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out, type3_out) \ | |
678 IPC_MESSAGE_LOG(msg_class) | |
679 | |
680 #elif defined(IPC_MESSAGE_MACROS_CLASSES) | |
681 #undef IPC_MESSAGE_MACROS_CLASSES | |
682 | |
683 | |
684 // Undefine the macros from the previous pass (if any). | |
685 #undef IPC_BEGIN_MESSAGES | |
686 #undef IPC_END_MESSAGES | |
687 #undef IPC_MESSAGE_CONTROL0 | |
688 #undef IPC_MESSAGE_CONTROL1 | |
689 #undef IPC_MESSAGE_CONTROL2 | |
690 #undef IPC_MESSAGE_CONTROL3 | |
691 #undef IPC_MESSAGE_CONTROL4 | |
692 #undef IPC_MESSAGE_CONTROL5 | |
693 #undef IPC_MESSAGE_ROUTED0 | |
694 #undef IPC_MESSAGE_ROUTED1 | |
695 #undef IPC_MESSAGE_ROUTED2 | |
696 #undef IPC_MESSAGE_ROUTED3 | |
697 #undef IPC_MESSAGE_ROUTED4 | |
698 #undef IPC_MESSAGE_ROUTED5 | |
699 #undef IPC_SYNC_MESSAGE_CONTROL0_0 | |
700 #undef IPC_SYNC_MESSAGE_CONTROL0_1 | |
701 #undef IPC_SYNC_MESSAGE_CONTROL0_2 | |
702 #undef IPC_SYNC_MESSAGE_CONTROL0_3 | |
703 #undef IPC_SYNC_MESSAGE_CONTROL1_0 | |
704 #undef IPC_SYNC_MESSAGE_CONTROL1_1 | |
705 #undef IPC_SYNC_MESSAGE_CONTROL1_2 | |
706 #undef IPC_SYNC_MESSAGE_CONTROL1_3 | |
707 #undef IPC_SYNC_MESSAGE_CONTROL2_0 | |
708 #undef IPC_SYNC_MESSAGE_CONTROL2_1 | |
709 #undef IPC_SYNC_MESSAGE_CONTROL2_2 | |
710 #undef IPC_SYNC_MESSAGE_CONTROL2_3 | |
711 #undef IPC_SYNC_MESSAGE_CONTROL3_1 | |
712 #undef IPC_SYNC_MESSAGE_CONTROL3_2 | |
713 #undef IPC_SYNC_MESSAGE_CONTROL3_3 | |
714 #undef IPC_SYNC_MESSAGE_CONTROL3_4 | |
715 #undef IPC_SYNC_MESSAGE_CONTROL4_1 | |
716 #undef IPC_SYNC_MESSAGE_CONTROL4_2 | |
717 #undef IPC_SYNC_MESSAGE_ROUTED0_0 | |
718 #undef IPC_SYNC_MESSAGE_ROUTED0_1 | |
719 #undef IPC_SYNC_MESSAGE_ROUTED0_2 | |
720 #undef IPC_SYNC_MESSAGE_ROUTED0_3 | |
721 #undef IPC_SYNC_MESSAGE_ROUTED1_0 | |
722 #undef IPC_SYNC_MESSAGE_ROUTED1_1 | |
723 #undef IPC_SYNC_MESSAGE_ROUTED1_2 | |
724 #undef IPC_SYNC_MESSAGE_ROUTED1_3 | |
725 #undef IPC_SYNC_MESSAGE_ROUTED1_4 | |
726 #undef IPC_SYNC_MESSAGE_ROUTED2_0 | |
727 #undef IPC_SYNC_MESSAGE_ROUTED2_1 | |
728 #undef IPC_SYNC_MESSAGE_ROUTED2_2 | |
729 #undef IPC_SYNC_MESSAGE_ROUTED2_3 | |
730 #undef IPC_SYNC_MESSAGE_ROUTED3_0 | |
731 #undef IPC_SYNC_MESSAGE_ROUTED3_1 | |
732 #undef IPC_SYNC_MESSAGE_ROUTED3_2 | |
733 #undef IPC_SYNC_MESSAGE_ROUTED3_3 | |
734 #undef IPC_SYNC_MESSAGE_ROUTED3_4 | |
735 #undef IPC_SYNC_MESSAGE_ROUTED4_0 | |
736 #undef IPC_SYNC_MESSAGE_ROUTED4_1 | |
737 #undef IPC_SYNC_MESSAGE_ROUTED4_2 | |
738 #undef IPC_SYNC_MESSAGE_ROUTED4_3 | |
739 #undef IPC_SYNC_MESSAGE_ROUTED5_0 | |
740 #undef IPC_SYNC_MESSAGE_ROUTED5_1 | |
741 #undef IPC_SYNC_MESSAGE_ROUTED5_2 | |
742 #undef IPC_SYNC_MESSAGE_ROUTED5_3 | |
743 | |
744 #define IPC_BEGIN_MESSAGES(label) | |
745 #define IPC_END_MESSAGES(label) | |
746 | |
747 #define IPC_MESSAGE_CONTROL0(msg_class) \ | |
748 class msg_class : public IPC::Message { \ | |
749 public: \ | |
750 enum { ID = msg_class##__ID }; \ | |
751 msg_class() \ | |
752 : IPC::Message(MSG_ROUTING_CONTROL, \ | |
753 ID, \ | |
754 PRIORITY_NORMAL) {} \ | |
755 }; | |
756 | |
757 #define IPC_MESSAGE_CONTROL1(msg_class, type1) \ | |
758 class msg_class : public IPC::MessageWithTuple< Tuple1<type1> > { \ | |
759 public: \ | |
760 enum { ID = msg_class##__ID }; \ | |
761 msg_class(const type1& arg1); \ | |
762 ~msg_class(); \ | |
763 static void Log(const Message* msg, std::string* l); \ | |
764 }; | |
765 | |
766 #define IPC_MESSAGE_CONTROL2(msg_class, type1, type2) \ | |
767 class msg_class : public IPC::MessageWithTuple< Tuple2<type1, type2> > { \ | |
768 public: \ | |
769 enum { ID = msg_class##__ID }; \ | |
770 msg_class(const type1& arg1, const type2& arg2); \ | |
771 ~msg_class(); \ | |
772 static void Log(const Message* msg, std::string* l); \ | |
773 }; | |
774 | |
775 #define IPC_MESSAGE_CONTROL3(msg_class, type1, type2, type3) \ | |
776 class msg_class : \ | |
777 public IPC::MessageWithTuple< Tuple3<type1, type2, type3> > { \ | |
778 public: \ | |
779 enum { ID = msg_class##__ID }; \ | |
780 msg_class(const type1& arg1, const type2& arg2, const type3& arg3); \ | |
781 ~msg_class(); \ | |
782 static void Log(const Message* msg, std::string* l); \ | |
783 }; | |
784 | |
785 #define IPC_MESSAGE_CONTROL4(msg_class, type1, type2, type3, type4) \ | |
786 class msg_class : \ | |
787 public IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> > { \ | |
788 public: \ | |
789 enum { ID = msg_class##__ID }; \ | |
790 msg_class(const type1& arg1, const type2& arg2, const type3& arg3, \ | |
791 const type4& arg4); \ | |
792 ~msg_class(); \ | |
793 static void Log(const Message* msg, std::string* l); \ | |
794 }; | |
795 | |
796 #define IPC_MESSAGE_CONTROL5(msg_class, type1, type2, type3, type4, type5) \ | |
797 class msg_class : \ | |
798 public IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, \ | |
799 type5> > { \ | |
800 public: \ | |
801 enum { ID = msg_class##__ID }; \ | |
802 msg_class(const type1& arg1, const type2& arg2, \ | |
803 const type3& arg3, const type4& arg4, const type5& arg5); \ | |
804 ~msg_class(); \ | |
805 static void Log(const Message* msg, std::string* l); \ | |
806 }; | |
807 | |
808 #define IPC_MESSAGE_ROUTED0(msg_class) \ | |
809 class msg_class : public IPC::Message { \ | |
810 public: \ | |
811 enum { ID = msg_class##__ID }; \ | |
812 msg_class(int32 routing_id) \ | |
813 : IPC::Message(routing_id, ID, PRIORITY_NORMAL) {} \ | |
814 }; | |
815 | |
816 #define IPC_MESSAGE_ROUTED1(msg_class, type1) \ | |
817 class msg_class : public IPC::MessageWithTuple< Tuple1<type1> > { \ | |
818 public: \ | |
819 enum { ID = msg_class##__ID }; \ | |
820 msg_class(int32 routing_id, const type1& arg1); \ | |
821 ~msg_class(); \ | |
822 static void Log(const Message* msg, std::string* l); \ | |
823 }; | |
824 | |
825 #define IPC_MESSAGE_ROUTED2(msg_class, type1, type2) \ | |
826 class msg_class \ | |
827 : public IPC::MessageWithTuple< Tuple2<type1, type2> > { \ | |
828 public: \ | |
829 enum { ID = msg_class##__ID }; \ | |
830 msg_class(int32 routing_id, const type1& arg1, const type2& arg2); \ | |
831 ~msg_class(); \ | |
832 static void Log(const Message* msg, std::string* l); \ | |
833 }; | |
834 | |
835 #define IPC_MESSAGE_ROUTED3(msg_class, type1, type2, type3) \ | |
836 class msg_class \ | |
837 : public IPC::MessageWithTuple< Tuple3<type1, type2, type3> > { \ | |
838 public: \ | |
839 enum { ID = msg_class##__ID }; \ | |
840 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
841 const type3& arg3); \ | |
842 ~msg_class(); \ | |
843 static void Log(const Message* msg, std::string* l); \ | |
844 }; | |
845 | |
846 #define IPC_MESSAGE_ROUTED4(msg_class, type1, type2, type3, type4) \ | |
847 class msg_class \ | |
848 : public IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> > { \ | |
849 public: \ | |
850 enum { ID = msg_class##__ID }; \ | |
851 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
852 const type3& arg3, const type4& arg4); \ | |
853 ~msg_class(); \ | |
854 static void Log(const Message* msg, std::string* l); \ | |
855 }; | |
856 | |
857 #define IPC_MESSAGE_ROUTED5(msg_class, type1, type2, type3, type4, type5) \ | |
858 class msg_class \ | |
859 : public IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, \ | |
860 type5> > { \ | |
861 public: \ | |
862 enum { ID = msg_class##__ID }; \ | |
863 msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \ | |
864 const type3& arg3, const type4& arg4, const type5& arg5); \ | |
865 ~msg_class(); \ | |
866 static void Log(const Message* msg, std::string* l); \ | |
867 }; | |
868 | |
869 #define IPC_SYNC_MESSAGE_CONTROL0_0(msg_class) \ | |
870 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple0 > { \ | |
871 public: \ | |
872 enum { ID = msg_class##__ID }; \ | |
873 msg_class(); \ | |
874 ~msg_class(); \ | |
875 static void Log(const Message* msg, std::string* l); \ | |
876 }; | |
877 | |
878 #define IPC_SYNC_MESSAGE_CONTROL0_1(msg_class, type1_out) \ | |
879 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple1<type1_out&> > {\ | |
880 public: \ | |
881 enum { ID = msg_class##__ID }; \ | |
882 msg_class(type1_out* arg1); \ | |
883 ~msg_class(); \ | |
884 static void Log(const Message* msg, std::string* l); \ | |
885 }; | |
886 | |
887 #define IPC_SYNC_MESSAGE_CONTROL0_2(msg_class, type1_out, type2_out) \ | |
888 class msg_class : \ | |
889 public IPC::MessageWithReply<Tuple0, Tuple2<type1_out&, type2_out&> > { \ | |
890 public: \ | |
891 enum { ID = msg_class##__ID }; \ | |
892 msg_class(type1_out* arg1, type2_out* arg2); \ | |
893 ~msg_class(); \ | |
894 static void Log(const Message* msg, std::string* l); \ | |
895 }; | |
896 | |
897 #define IPC_SYNC_MESSAGE_CONTROL0_3(msg_class, type1_out, type2_out, type3_out) \ | |
898 class msg_class : \ | |
899 public IPC::MessageWithReply<Tuple0, \ | |
900 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
901 public: \ | |
902 enum { ID = msg_class##__ID }; \ | |
903 msg_class(type1_out* arg1, type2_out* arg2, type3_out* arg3); \ | |
904 ~msg_class(); \ | |
905 static void Log(const Message* msg, std::string* l); \ | |
906 }; | |
907 | |
908 #define IPC_SYNC_MESSAGE_CONTROL1_0(msg_class, type1_in) \ | |
909 class msg_class : \ | |
910 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple0 > { \ | |
911 public: \ | |
912 enum { ID = msg_class##__ID }; \ | |
913 msg_class(const type1_in& arg1); \ | |
914 ~msg_class(); \ | |
915 static void Log(const Message* msg, std::string* l); \ | |
916 }; | |
917 | |
918 #define IPC_SYNC_MESSAGE_CONTROL1_1(msg_class, type1_in, type1_out) \ | |
919 class msg_class : \ | |
920 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple1<type1_out&> > { \ | |
921 public: \ | |
922 enum { ID = msg_class##__ID }; \ | |
923 msg_class(const type1_in& arg1, type1_out* arg2); \ | |
924 ~msg_class(); \ | |
925 static void Log(const Message* msg, std::string* l); \ | |
926 }; | |
927 | |
928 #define IPC_SYNC_MESSAGE_CONTROL1_2(msg_class, type1_in, type1_out, type2_out) \ | |
929 class msg_class : \ | |
930 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple2<type1_out&, type2_ou t&> > { \ | |
931 public: \ | |
932 enum { ID = msg_class##__ID }; \ | |
933 msg_class(const type1_in& arg1, type1_out* arg2, type2_out* arg3); \ | |
934 ~msg_class(); \ | |
935 static void Log(const Message* msg, std::string* l); \ | |
936 }; | |
937 | |
938 #define IPC_SYNC_MESSAGE_CONTROL1_3(msg_class, type1_in, type1_out, type2_out, t ype3_out) \ | |
939 class msg_class : \ | |
940 public IPC::MessageWithReply<Tuple1<type1_in>, \ | |
941 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
942 public: \ | |
943 enum { ID = msg_class##__ID }; \ | |
944 msg_class(const type1_in& arg1, type1_out* arg2, type2_out* arg3, type3_out* arg4); \ | |
945 ~msg_class(); \ | |
946 static void Log(const Message* msg, std::string* l); \ | |
947 }; | |
948 | |
949 #define IPC_SYNC_MESSAGE_CONTROL2_0(msg_class, type1_in, type2_in) \ | |
950 class msg_class : \ | |
951 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple0 > { \ | |
952 public: \ | |
953 enum { ID = msg_class##__ID }; \ | |
954 msg_class(const type1_in& arg1, const type2_in& arg2); \ | |
955 ~msg_class(); \ | |
956 static void Log(const Message* msg, std::string* l); \ | |
957 }; | |
958 | |
959 #define IPC_SYNC_MESSAGE_CONTROL2_1(msg_class, type1_in, type2_in, type1_out) \ | |
960 class msg_class : \ | |
961 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple1<type1_out& > > { \ | |
962 public: \ | |
963 enum { ID = msg_class##__ID }; \ | |
964 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3); \ | |
965 ~msg_class(); \ | |
966 static void Log(const Message* msg, std::string* l); \ | |
967 }; | |
968 | |
969 #define IPC_SYNC_MESSAGE_CONTROL2_2(msg_class, type1_in, type2_in, type1_out, ty pe2_out) \ | |
970 class msg_class : \ | |
971 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
972 Tuple2<type1_out&, type2_out&> > { \ | |
973 public: \ | |
974 enum { ID = msg_class##__ID }; \ | |
975 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3, type2_ out* arg4); \ | |
976 ~msg_class(); \ | |
977 static void Log(const Message* msg, std::string* l); \ | |
978 }; | |
979 | |
980 #define IPC_SYNC_MESSAGE_CONTROL2_3(msg_class, type1_in, type2_in, type1_out, ty pe2_out, type3_out) \ | |
981 class msg_class : \ | |
982 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
983 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
984 public: \ | |
985 enum { ID = msg_class##__ID }; \ | |
986 msg_class(const type1_in& arg1, const type2_in& arg2, type1_out* arg3, type2_ out* arg4, type3_out* arg5); \ | |
987 ~msg_class(); \ | |
988 static void Log(const Message* msg, std::string* l); \ | |
989 }; | |
990 | |
991 #define IPC_SYNC_MESSAGE_CONTROL3_1(msg_class, type1_in, type2_in, type3_in, typ e1_out) \ | |
992 class msg_class : \ | |
993 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
994 Tuple1<type1_out&> > { \ | |
995 public: \ | |
996 enum { ID = msg_class##__ID }; \ | |
997 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, t ype1_out* arg4); \ | |
998 ~msg_class(); \ | |
999 static void Log(const Message* msg, std::string* l); \ | |
1000 }; | |
1001 | |
1002 #define IPC_SYNC_MESSAGE_CONTROL3_2(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out) \ | |
1003 class msg_class : \ | |
1004 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1005 Tuple2<type1_out&, type2_out&> > { \ | |
1006 public: \ | |
1007 enum { ID = msg_class##__ID }; \ | |
1008 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, t ype1_out* arg4, type2_out* arg5); \ | |
1009 ~msg_class(); \ | |
1010 static void Log(const Message* msg, std::string* l); \ | |
1011 }; | |
1012 | |
1013 #define IPC_SYNC_MESSAGE_CONTROL3_3(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out) \ | |
1014 class msg_class : \ | |
1015 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1016 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
1017 public: \ | |
1018 enum { ID = msg_class##__ID }; \ | |
1019 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, t ype1_out* arg4, type2_out* arg5, type3_out* arg6); \ | |
1020 ~msg_class(); \ | |
1021 static void Log(const Message* msg, std::string* l); \ | |
1022 }; | |
1023 | |
1024 #define IPC_SYNC_MESSAGE_CONTROL3_4(msg_class, type1_in, type2_in, type3_in, typ e1_out, type2_out, type3_out, type4_out) \ | |
1025 class msg_class : \ | |
1026 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1027 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> > { \ | |
1028 public: \ | |
1029 enum { ID = msg_class##__ID }; \ | |
1030 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, t ype1_out* arg4, type2_out* arg5, type3_out* arg6, type4_out* arg7); \ | |
1031 ~msg_class(); \ | |
1032 static void Log(const Message* msg, std::string* l); \ | |
1033 }; | |
1034 | |
1035 #define IPC_SYNC_MESSAGE_CONTROL4_1(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out) \ | |
1036 class msg_class : \ | |
1037 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1038 Tuple1<type1_out&> > { \ | |
1039 public: \ | |
1040 enum { ID = msg_class##__ID }; \ | |
1041 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, c onst type4_in& arg4, type1_out* arg6); \ | |
1042 ~msg_class(); \ | |
1043 static void Log(const Message* msg, std::string* l); \ | |
1044 }; | |
1045 | |
1046 #define IPC_SYNC_MESSAGE_CONTROL4_2(msg_class, type1_in, type2_in, type3_in, typ e4_in, type1_out, type2_out) \ | |
1047 class msg_class : \ | |
1048 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1049 Tuple2<type1_out&, type2_out&> > { \ | |
1050 public: \ | |
1051 enum { ID = msg_class##__ID }; \ | |
1052 msg_class(const type1_in& arg1, const type2_in& arg2, const type3_in& arg3, c onst type4_in& arg4, type1_out* arg5, type2_out* arg6); \ | |
1053 ~msg_class(); \ | |
1054 static void Log(const Message* msg, std::string* l); \ | |
1055 }; | |
1056 | |
1057 #define IPC_SYNC_MESSAGE_ROUTED0_0(msg_class) \ | |
1058 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple0 > { \ | |
1059 public: \ | |
1060 enum { ID = msg_class##__ID }; \ | |
1061 msg_class(int routing_id); \ | |
1062 ~msg_class(); \ | |
1063 static void Log(const Message* msg, std::string* l); \ | |
1064 }; | |
1065 | |
1066 #define IPC_SYNC_MESSAGE_ROUTED0_1(msg_class, type1_out) \ | |
1067 class msg_class : public IPC::MessageWithReply<Tuple0, Tuple1<type1_out&> > { \ | |
1068 public: \ | |
1069 enum { ID = msg_class##__ID }; \ | |
1070 msg_class(int routing_id, type1_out* arg1); \ | |
1071 ~msg_class(); \ | |
1072 static void Log(const Message* msg, std::string* l); \ | |
1073 }; | |
1074 | |
1075 #define IPC_SYNC_MESSAGE_ROUTED0_2(msg_class, type1_out, type2_out) \ | |
1076 class msg_class : \ | |
1077 public IPC::MessageWithReply<Tuple0, Tuple2<type1_out&, type2_out&> > { \ | |
1078 public: \ | |
1079 enum { ID = msg_class##__ID }; \ | |
1080 msg_class(int routing_id, type1_out* arg1, type2_out* arg2); \ | |
1081 ~msg_class(); \ | |
1082 static void Log(const Message* msg, std::string* l); \ | |
1083 }; | |
1084 | |
1085 #define IPC_SYNC_MESSAGE_ROUTED0_3(msg_class, type1_out, type2_out, type3_out) \ | |
1086 class msg_class : \ | |
1087 public IPC::MessageWithReply<Tuple0, \ | |
1088 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
1089 public: \ | |
1090 enum { ID = msg_class##__ID }; \ | |
1091 msg_class(int routing_id, type1_out* arg1, type2_out* arg2, type3_out* arg3); \ | |
1092 ~msg_class(); \ | |
1093 static void Log(const Message* msg, std::string* l); \ | |
1094 }; | |
1095 | |
1096 #define IPC_SYNC_MESSAGE_ROUTED1_0(msg_class, type1_in) \ | |
1097 class msg_class : \ | |
1098 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple0 > { \ | |
1099 public: \ | |
1100 enum { ID = msg_class##__ID }; \ | |
1101 msg_class(int routing_id, const type1_in& arg1); \ | |
1102 ~msg_class(); \ | |
1103 static void Log(const Message* msg, std::string* l); \ | |
1104 }; | |
1105 | |
1106 #define IPC_SYNC_MESSAGE_ROUTED1_1(msg_class, type1_in, type1_out) \ | |
1107 class msg_class : \ | |
1108 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple1<type1_out&> > { \ | |
1109 public: \ | |
1110 enum { ID = msg_class##__ID }; \ | |
1111 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2); \ | |
1112 ~msg_class(); \ | |
1113 static void Log(const Message* msg, std::string* l); \ | |
1114 }; | |
1115 | |
1116 #define IPC_SYNC_MESSAGE_ROUTED1_2(msg_class, type1_in, type1_out, type2_out) \ | |
1117 class msg_class : \ | |
1118 public IPC::MessageWithReply<Tuple1<type1_in>, Tuple2<type1_out&, type2_ou t&> > { \ | |
1119 public: \ | |
1120 enum { ID = msg_class##__ID }; \ | |
1121 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* a rg3); \ | |
1122 ~msg_class(); \ | |
1123 static void Log(const Message* msg, std::string* l); \ | |
1124 }; | |
1125 | |
1126 #define IPC_SYNC_MESSAGE_ROUTED1_3(msg_class, type1_in, type1_out, type2_out, ty pe3_out) \ | |
1127 class msg_class : \ | |
1128 public IPC::MessageWithReply<Tuple1<type1_in>, \ | |
1129 Tuple3<type1_out&, type2_out&, type3_out&> >{ \ | |
1130 public: \ | |
1131 enum { ID = msg_class##__ID }; \ | |
1132 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* a rg3, type3_out* arg4); \ | |
1133 ~msg_class(); \ | |
1134 static void Log(const Message* msg, std::string* l); \ | |
1135 }; | |
1136 | |
1137 #define IPC_SYNC_MESSAGE_ROUTED1_4(msg_class, type1_in, type1_out, type2_out, ty pe3_out, type4_out) \ | |
1138 class msg_class : \ | |
1139 public IPC::MessageWithReply<Tuple1<type1_in>, \ | |
1140 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> >{ \ | |
1141 public: \ | |
1142 enum { ID = msg_class##__ID }; \ | |
1143 msg_class(int routing_id, const type1_in& arg1, type1_out* arg2, type2_out* a rg3, type3_out* arg4, type4_out* arg5); \ | |
1144 ~msg_class(); \ | |
1145 static void Log(const Message* msg, std::string* l); \ | |
1146 }; | |
1147 | |
1148 #define IPC_SYNC_MESSAGE_ROUTED2_0(msg_class, type1_in, type2_in) \ | |
1149 class msg_class : \ | |
1150 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple0 > { \ | |
1151 public: \ | |
1152 enum { ID = msg_class##__ID }; \ | |
1153 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2); \ | |
1154 ~msg_class(); \ | |
1155 static void Log(const Message* msg, std::string* l); \ | |
1156 }; | |
1157 | |
1158 #define IPC_SYNC_MESSAGE_ROUTED2_1(msg_class, type1_in, type2_in, type1_out) \ | |
1159 class msg_class : \ | |
1160 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, Tuple1<type1_out& > > { \ | |
1161 public: \ | |
1162 enum { ID = msg_class##__ID }; \ | |
1163 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_o ut* arg3); \ | |
1164 ~msg_class(); \ | |
1165 static void Log(const Message* msg, std::string* l); \ | |
1166 }; | |
1167 | |
1168 #define IPC_SYNC_MESSAGE_ROUTED2_2(msg_class, type1_in, type2_in, type1_out, typ e2_out) \ | |
1169 class msg_class : \ | |
1170 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
1171 Tuple2<type1_out&, type2_out&> > { \ | |
1172 public: \ | |
1173 enum { ID = msg_class##__ID }; \ | |
1174 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_o ut* arg3, type2_out* arg4); \ | |
1175 ~msg_class(); \ | |
1176 static void Log(const Message* msg, std::string* l); \ | |
1177 }; | |
1178 | |
1179 #define IPC_SYNC_MESSAGE_ROUTED2_3(msg_class, type1_in, type2_in, type1_out, typ e2_out, type3_out) \ | |
1180 class msg_class : \ | |
1181 public IPC::MessageWithReply<Tuple2<type1_in, type2_in>, \ | |
1182 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
1183 public: \ | |
1184 enum { ID = msg_class##__ID }; \ | |
1185 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, type1_o ut* arg3, type2_out* arg4, type3_out* arg5); \ | |
1186 ~msg_class(); \ | |
1187 static void Log(const Message* msg, std::string* l); \ | |
1188 }; | |
1189 | |
1190 #define IPC_SYNC_MESSAGE_ROUTED3_0(msg_class, type1_in, type2_in, type3_in) \ | |
1191 class msg_class : \ | |
1192 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, Tuple0 > { \ | |
1193 public: \ | |
1194 enum { ID = msg_class##__ID }; \ | |
1195 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3); \ | |
1196 ~msg_class(); \ | |
1197 static void Log(const Message* msg, std::string* l); \ | |
1198 }; | |
1199 | |
1200 #define IPC_SYNC_MESSAGE_ROUTED3_1(msg_class, type1_in, type2_in, type3_in, type 1_out) \ | |
1201 class msg_class : \ | |
1202 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1203 Tuple1<type1_out&> > { \ | |
1204 public: \ | |
1205 enum { ID = msg_class##__ID }; \ | |
1206 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, type1_out* arg4); \ | |
1207 ~msg_class(); \ | |
1208 static void Log(const Message* msg, std::string* l); \ | |
1209 }; | |
1210 | |
1211 #define IPC_SYNC_MESSAGE_ROUTED3_2(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out) \ | |
1212 class msg_class : \ | |
1213 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1214 Tuple2<type1_out&, type2_out&> > { \ | |
1215 public: \ | |
1216 enum { ID = msg_class##__ID }; \ | |
1217 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, type1_out* arg4, type2_out* arg5); \ | |
1218 ~msg_class(); \ | |
1219 static void Log(const Message* msg, std::string* l); \ | |
1220 }; | |
1221 | |
1222 #define IPC_SYNC_MESSAGE_ROUTED3_3(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out) \ | |
1223 class msg_class : \ | |
1224 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1225 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
1226 public: \ | |
1227 enum { ID = msg_class##__ID }; \ | |
1228 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6); \ | |
1229 ~msg_class(); \ | |
1230 static void Log(const Message* msg, std::string* l); \ | |
1231 }; | |
1232 | |
1233 #define IPC_SYNC_MESSAGE_ROUTED3_4(msg_class, type1_in, type2_in, type3_in, type 1_out, type2_out, type3_out, type4_out) \ | |
1234 class msg_class : \ | |
1235 public IPC::MessageWithReply<Tuple3<type1_in, type2_in, type3_in>, \ | |
1236 Tuple4<type1_out&, type2_out&, type3_out&, type4_out&> > { \ | |
1237 public: \ | |
1238 enum { ID = msg_class##__ID }; \ | |
1239 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, type1_out* arg4, type2_out* arg5, type3_out* arg6, type4_out* arg 7); \ | |
1240 ~msg_class(); \ | |
1241 static void Log(const Message* msg, std::string* l); \ | |
1242 }; | |
1243 | |
1244 #define IPC_SYNC_MESSAGE_ROUTED4_0(msg_class, type1_in, type2_in, type3_in, type 4_in) \ | |
1245 class msg_class : \ | |
1246 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1247 Tuple0 > { \ | |
1248 public: \ | |
1249 enum { ID = msg_class##__ID }; \ | |
1250 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4); \ | |
1251 ~msg_class(); \ | |
1252 static void Log(const Message* msg, std::string* l); \ | |
1253 }; | |
1254 | |
1255 #define IPC_SYNC_MESSAGE_ROUTED4_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out) \ | |
1256 class msg_class : \ | |
1257 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1258 Tuple1<type1_out&> > { \ | |
1259 public: \ | |
1260 enum { ID = msg_class##__ID }; \ | |
1261 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, type1_out* arg6); \ | |
1262 ~msg_class(); \ | |
1263 static void Log(const Message* msg, std::string* l); \ | |
1264 }; | |
1265 | |
1266 #define IPC_SYNC_MESSAGE_ROUTED4_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out) \ | |
1267 class msg_class : \ | |
1268 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1269 Tuple2<type1_out&, type2_out&> > { \ | |
1270 public: \ | |
1271 enum { ID = msg_class##__ID }; \ | |
1272 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, type1_out* arg5, type2_out* arg6); \ | |
1273 ~msg_class(); \ | |
1274 static void Log(const Message* msg, std::string* l); \ | |
1275 }; | |
1276 | |
1277 #define IPC_SYNC_MESSAGE_ROUTED4_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type1_out, type2_out, type3_out) \ | |
1278 class msg_class : \ | |
1279 public IPC::MessageWithReply<Tuple4<type1_in, type2_in, type3_in, type4_in >, \ | |
1280 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
1281 public: \ | |
1282 enum { ID = msg_class##__ID }; \ | |
1283 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, type1_out* arg5, type2_out* arg6, type3_out * arg7); \ | |
1284 ~msg_class(); \ | |
1285 static void Log(const Message* msg, std::string* l); \ | |
1286 }; | |
1287 | |
1288 #define IPC_SYNC_MESSAGE_ROUTED5_0(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in) \ | |
1289 class msg_class : \ | |
1290 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
1291 Tuple0 > { \ | |
1292 public: \ | |
1293 enum { ID = msg_class##__ID }; \ | |
1294 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, const type5_in& arg5); \ | |
1295 ~msg_class(); \ | |
1296 static void Log(const Message* msg, std::string* l); \ | |
1297 }; | |
1298 | |
1299 #define IPC_SYNC_MESSAGE_ROUTED5_1(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out) \ | |
1300 class msg_class : \ | |
1301 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
1302 Tuple1<type1_out&> > { \ | |
1303 public: \ | |
1304 enum { ID = msg_class##__ID }; \ | |
1305 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, const type5_in& arg5, type1_out* arg6); \ | |
1306 ~msg_class(); \ | |
1307 static void Log(const Message* msg, std::string* l); \ | |
1308 }; | |
1309 | |
1310 #define IPC_SYNC_MESSAGE_ROUTED5_2(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out) \ | |
1311 class msg_class : \ | |
1312 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
1313 Tuple2<type1_out&, type2_out&> > { \ | |
1314 public: \ | |
1315 enum { ID = msg_class##__ID }; \ | |
1316 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, const type4_in& arg5, type1_out* arg6, type 2_out* arg7); \ | |
1317 ~msg_class(); \ | |
1318 static void Log(const Message* msg, std::string* l); \ | |
1319 }; | |
1320 | |
1321 #define IPC_SYNC_MESSAGE_ROUTED5_3(msg_class, type1_in, type2_in, type3_in, type 4_in, type5_in, type1_out, type2_out, type3_out) \ | |
1322 class msg_class : \ | |
1323 public IPC::MessageWithReply<Tuple5<type1_in, type2_in, type3_in, type4_in , type5_in>, \ | |
1324 Tuple3<type1_out&, type2_out&, type3_out&> > { \ | |
1325 public: \ | |
1326 enum { ID = msg_class##__ID }; \ | |
1327 msg_class(int routing_id, const type1_in& arg1, const type2_in& arg2, const t ype3_in& arg3, const type4_in& arg4, const type4_in& arg5, type1_out* arg6, type 2_out* arg7, type3_out* arg8); \ | |
1328 ~msg_class(); \ | |
1329 static void Log(const Message* msg, std::string* l); \ | |
1330 }; | |
1331 | |
1332 #endif // #if defined() | |
OLD | NEW |