1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // Message definition file, included multiple times, hence no include guard.
10 #include "content/common/indexed_db/indexed_db_key.h"
11 #include "content/common/indexed_db/indexed_db_key_path.h"
12 #include "content/common/indexed_db/indexed_db_key_range.h"
13 #include "content/common/indexed_db/indexed_db_param_traits.h"
14 #include "ipc/ipc_message_macros.h"
15 #include "ipc/ipc_param_traits.h"
16 #include "third_party/WebKit/public/platform/WebIDBCursor.h"
17 #include "third_party/WebKit/public/platform/WebIDBDatabase.h"
19 #undef IPC_MESSAGE_EXPORT
20 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT
21 #define IPC_MESSAGE_START IndexedDBMsgStart
23 // Argument structures used in messages
25 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebIDBCursor::Direction,
26 blink::WebIDBCursor::DirectionLast)
27 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebIDBDatabase::PutMode,
28 blink::WebIDBDatabase::PutModeLast)
29 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebIDBDatabase::TaskType,
30 blink::WebIDBDatabase::TaskTypeLast)
31 IPC_ENUM_TRAITS(blink::WebIDBDatabase::TransactionMode)
33 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebIDBDataLoss, blink::WebIDBDataLossTotal)
35 // An index id, and corresponding set of keys to insert.
36 typedef std::pair<int64, std::vector<content::IndexedDBKey> > IndexKeys;
38 // Used to enumerate indexed databases.
39 IPC_STRUCT_BEGIN(IndexedDBHostMsg_FactoryGetDatabaseNames_Params)
40 // The response should have these ids.
41 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
42 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
43 // The string id of the origin doing the initiating.
44 IPC_STRUCT_MEMBER(std::string, database_identifier)
47 // Used to open an indexed database.
48 IPC_STRUCT_BEGIN(IndexedDBHostMsg_FactoryOpen_Params)
49 // The response should have these ids.
50 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
51 // Identifier of the request
52 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
53 // Identifier for database callbacks
54 IPC_STRUCT_MEMBER(int32, ipc_database_callbacks_id)
55 // The string id of the origin doing the initiating.
56 IPC_STRUCT_MEMBER(std::string, database_identifier)
57 // The name of the database.
58 IPC_STRUCT_MEMBER(base::string16, name)
59 // The transaction id used if a database upgrade is needed.
60 IPC_STRUCT_MEMBER(int64, transaction_id)
61 // The requested version of the database.
62 IPC_STRUCT_MEMBER(int64, version)
65 // Used to delete an indexed database.
66 IPC_STRUCT_BEGIN(IndexedDBHostMsg_FactoryDeleteDatabase_Params)
67 // The response should have these ids.
68 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
69 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
70 // The string id of the origin doing the initiating.
71 IPC_STRUCT_MEMBER(std::string, database_identifier)
72 // The name of the database.
73 IPC_STRUCT_MEMBER(base::string16, name)
76 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseCreateTransaction_Params)
77 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
78 // The database the object store belongs to.
79 IPC_STRUCT_MEMBER(int32, ipc_database_id)
80 // The transaction id as minted by the frontend.
81 IPC_STRUCT_MEMBER(int64, transaction_id)
82 // To get to WebIDBDatabaseCallbacks.
83 IPC_STRUCT_MEMBER(int32, ipc_database_callbacks_id)
84 // The scope of the transaction.
85 IPC_STRUCT_MEMBER(std::vector<int64>, object_store_ids)
86 // The transaction mode.
87 IPC_STRUCT_MEMBER(blink::WebIDBDatabase::TransactionMode, mode)
90 // Used to create an object store.
91 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseCreateObjectStore_Params)
92 // The database the object store belongs to.
93 IPC_STRUCT_MEMBER(int32, ipc_database_id)
94 // The transaction its associated with.
95 IPC_STRUCT_MEMBER(int64, transaction_id)
96 // The storage id of the object store.
97 IPC_STRUCT_MEMBER(int64, object_store_id)
98 // The name of the object store.
99 IPC_STRUCT_MEMBER(base::string16, name)
100 // The keyPath of the object store.
101 IPC_STRUCT_MEMBER(content::IndexedDBKeyPath, key_path)
102 // Whether the object store created should have a key generator.
103 IPC_STRUCT_MEMBER(bool, auto_increment)
106 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseGet_Params)
107 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
108 // The id any response should contain.
109 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
110 // The database the object store belongs to.
111 IPC_STRUCT_MEMBER(int32, ipc_database_id)
112 // The transaction its associated with.
113 IPC_STRUCT_MEMBER(int64, transaction_id)
114 // The object store's id.
115 IPC_STRUCT_MEMBER(int64, object_store_id)
117 IPC_STRUCT_MEMBER(int64, index_id)
118 // The serialized key range.
119 IPC_STRUCT_MEMBER(content::IndexedDBKeyRange, key_range)
120 // If this is just retrieving the key
121 IPC_STRUCT_MEMBER(bool, key_only)
124 // Used to set a value in an object store.
125 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabasePut_Params)
126 // The id any response should contain.
127 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
128 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
129 // The database the object store belongs to.
130 IPC_STRUCT_MEMBER(int32, ipc_database_id)
131 // The transaction it's associated with.
132 IPC_STRUCT_MEMBER(int64, transaction_id)
133 // The object store's id.
134 IPC_STRUCT_MEMBER(int64, object_store_id)
136 IPC_STRUCT_MEMBER(int64, index_id)
138 IPC_STRUCT_MEMBER(std::string, value)
139 // The key to set it on (may not be "valid"/set in some cases).
140 IPC_STRUCT_MEMBER(content::IndexedDBKey, key)
141 // Whether this is an add or a put.
142 IPC_STRUCT_MEMBER(blink::WebIDBDatabase::PutMode, put_mode)
143 // The index ids and the list of keys for each index.
144 IPC_STRUCT_MEMBER(std::vector<IndexKeys>, index_keys)
147 // Used to open both cursors and object cursors in IndexedDB.
148 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseOpenCursor_Params)
149 // The response should have these ids.
150 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
151 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
152 // The database the object store belongs to.
153 IPC_STRUCT_MEMBER(int32, ipc_database_id)
154 // The transaction this request belongs to.
155 IPC_STRUCT_MEMBER(int64, transaction_id)
157 IPC_STRUCT_MEMBER(int64, object_store_id)
159 IPC_STRUCT_MEMBER(int64, index_id)
160 // The serialized key range.
161 IPC_STRUCT_MEMBER(content::IndexedDBKeyRange, key_range)
162 // The direction of this cursor.
163 IPC_STRUCT_MEMBER(blink::WebIDBCursor::Direction, direction)
164 // If this is just retrieving the key
165 IPC_STRUCT_MEMBER(bool, key_only)
166 // The priority of this cursor.
167 IPC_STRUCT_MEMBER(blink::WebIDBDatabase::TaskType, task_type)
170 // Used to open both cursors and object cursors in IndexedDB.
171 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseCount_Params)
172 // The response should have these ids.
173 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
174 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
175 // The transaction this request belongs to.
176 IPC_STRUCT_MEMBER(int64, transaction_id)
177 // The IPC id of the database.
178 IPC_STRUCT_MEMBER(int32, ipc_database_id)
180 IPC_STRUCT_MEMBER(int64, object_store_id)
182 IPC_STRUCT_MEMBER(int64, index_id)
183 // The serialized key range.
184 IPC_STRUCT_MEMBER(content::IndexedDBKeyRange, key_range)
187 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseDeleteRange_Params)
188 // The response should have these ids.
189 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
190 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
191 // The IPC id of the database.
192 IPC_STRUCT_MEMBER(int32, ipc_database_id)
193 // The transaction this request belongs to.
194 IPC_STRUCT_MEMBER(int64, transaction_id)
196 IPC_STRUCT_MEMBER(int64, object_store_id)
197 // The serialized key range.
198 IPC_STRUCT_MEMBER(content::IndexedDBKeyRange, key_range)
201 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseSetIndexKeys_Params)
202 // The IPC id of the database.
203 IPC_STRUCT_MEMBER(int32, ipc_database_id)
204 // The transaction this request belongs to.
205 IPC_STRUCT_MEMBER(int64, transaction_id)
206 // The object store's id.
207 IPC_STRUCT_MEMBER(int64, object_store_id)
208 // The object store key that we're setting index keys for.
209 IPC_STRUCT_MEMBER(content::IndexedDBKey, primary_key)
210 // The index ids and the list of keys for each index.
211 IPC_STRUCT_MEMBER(std::vector<IndexKeys>, index_keys)
214 // Used to create an index.
215 IPC_STRUCT_BEGIN(IndexedDBHostMsg_DatabaseCreateIndex_Params)
216 // The transaction this is associated with.
217 IPC_STRUCT_MEMBER(int64, transaction_id)
218 // The database being used.
219 IPC_STRUCT_MEMBER(int32, ipc_database_id)
220 // The object store the index belongs to.
221 IPC_STRUCT_MEMBER(int64, object_store_id)
222 // The storage id of the index.
223 IPC_STRUCT_MEMBER(int64, index_id)
224 // The name of the index.
225 IPC_STRUCT_MEMBER(base::string16, name)
226 // The keyPath of the index.
227 IPC_STRUCT_MEMBER(content::IndexedDBKeyPath, key_path)
228 // Whether the index created has unique keys.
229 IPC_STRUCT_MEMBER(bool, unique)
230 // Whether the index created produces keys for each array entry.
231 IPC_STRUCT_MEMBER(bool, multi_entry)
234 IPC_STRUCT_BEGIN(IndexedDBMsg_CallbacksSuccessIDBCursor_Params)
235 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
236 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
237 IPC_STRUCT_MEMBER(int32, ipc_cursor_id)
238 IPC_STRUCT_MEMBER(content::IndexedDBKey, key)
239 IPC_STRUCT_MEMBER(content::IndexedDBKey, primary_key)
240 IPC_STRUCT_MEMBER(std::string, value)
243 IPC_STRUCT_BEGIN(IndexedDBMsg_CallbacksSuccessCursorContinue_Params)
244 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
245 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
246 IPC_STRUCT_MEMBER(int32, ipc_cursor_id)
247 IPC_STRUCT_MEMBER(content::IndexedDBKey, key)
248 IPC_STRUCT_MEMBER(content::IndexedDBKey, primary_key)
249 IPC_STRUCT_MEMBER(std::string, value)
252 IPC_STRUCT_BEGIN(IndexedDBMsg_CallbacksSuccessCursorPrefetch_Params)
253 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
254 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
255 IPC_STRUCT_MEMBER(int32, ipc_cursor_id)
256 IPC_STRUCT_MEMBER(std::vector<content::IndexedDBKey>, keys)
257 IPC_STRUCT_MEMBER(std::vector<content::IndexedDBKey>, primary_keys)
258 IPC_STRUCT_MEMBER(std::vector<std::string>, values)
261 IPC_STRUCT_BEGIN(IndexedDBIndexMetadata)
262 IPC_STRUCT_MEMBER(int64, id)
263 IPC_STRUCT_MEMBER(base::string16, name)
264 IPC_STRUCT_MEMBER(content::IndexedDBKeyPath, keyPath)
265 IPC_STRUCT_MEMBER(bool, unique)
266 IPC_STRUCT_MEMBER(bool, multiEntry)
269 IPC_STRUCT_BEGIN(IndexedDBObjectStoreMetadata)
270 IPC_STRUCT_MEMBER(int64, id)
271 IPC_STRUCT_MEMBER(base::string16, name)
272 IPC_STRUCT_MEMBER(content::IndexedDBKeyPath, keyPath)
273 IPC_STRUCT_MEMBER(bool, autoIncrement)
274 IPC_STRUCT_MEMBER(int64, max_index_id)
275 IPC_STRUCT_MEMBER(std::vector<IndexedDBIndexMetadata>, indexes)
278 IPC_STRUCT_BEGIN(IndexedDBDatabaseMetadata)
279 IPC_STRUCT_MEMBER(int64, id)
280 IPC_STRUCT_MEMBER(base::string16, name)
281 IPC_STRUCT_MEMBER(base::string16, version)
282 IPC_STRUCT_MEMBER(int64, int_version)
283 IPC_STRUCT_MEMBER(int64, max_object_store_id)
284 IPC_STRUCT_MEMBER(std::vector<IndexedDBObjectStoreMetadata>, object_stores)
287 IPC_STRUCT_BEGIN(IndexedDBMsg_CallbacksUpgradeNeeded_Params)
288 IPC_STRUCT_MEMBER(int32, ipc_thread_id)
289 IPC_STRUCT_MEMBER(int32, ipc_callbacks_id)
290 IPC_STRUCT_MEMBER(int32, ipc_database_callbacks_id)
291 IPC_STRUCT_MEMBER(int32, ipc_database_id)
292 IPC_STRUCT_MEMBER(int64, old_version)
293 IPC_STRUCT_MEMBER(blink::WebIDBDataLoss, data_loss)
294 IPC_STRUCT_MEMBER(std::string, data_loss_message)
295 IPC_STRUCT_MEMBER(IndexedDBDatabaseMetadata, idb_metadata)
298 // Indexed DB messages sent from the browser to the renderer.
300 // The thread_id needs to be the first parameter in these messages. In the IO
301 // thread on the renderer/client process, an IDB message filter assumes the
302 // thread_id is the first int.
304 // IDBCallback message handlers.
305 IPC_MESSAGE_CONTROL1(IndexedDBMsg_CallbacksSuccessIDBCursor,
306 IndexedDBMsg_CallbacksSuccessIDBCursor_Params)
308 IPC_MESSAGE_CONTROL1(IndexedDBMsg_CallbacksSuccessCursorContinue,
309 IndexedDBMsg_CallbacksSuccessCursorContinue_Params)
311 IPC_MESSAGE_CONTROL1(IndexedDBMsg_CallbacksSuccessCursorAdvance,
312 IndexedDBMsg_CallbacksSuccessCursorContinue_Params)
314 IPC_MESSAGE_CONTROL1(IndexedDBMsg_CallbacksSuccessCursorPrefetch,
315 IndexedDBMsg_CallbacksSuccessCursorPrefetch_Params)
317 IPC_MESSAGE_CONTROL5(IndexedDBMsg_CallbacksSuccessIDBDatabase,
318 int32 /* ipc_thread_id */,
319 int32 /* ipc_callbacks_id */,
320 int32 /* ipc_database_callbacks_id */,
321 int32 /* ipc_database_id */,
322 IndexedDBDatabaseMetadata)
323 IPC_MESSAGE_CONTROL3(IndexedDBMsg_CallbacksSuccessIndexedDBKey,
324 int32 /* ipc_thread_id */,
325 int32 /* ipc_callbacks_id */,
326 content::IndexedDBKey /* indexed_db_key */)
327 IPC_MESSAGE_CONTROL3(IndexedDBMsg_CallbacksSuccessValue,
328 int32 /* ipc_thread_id */,
329 int32 /* ipc_callbacks_id */,
330 std::string /* value */)
331 IPC_MESSAGE_CONTROL5(IndexedDBMsg_CallbacksSuccessValueWithKey,
332 int32 /* ipc_thread_id */,
333 int32 /* ipc_callbacks_id */,
334 std::string /* value */,
335 content::IndexedDBKey /* indexed_db_key */,
336 content::IndexedDBKeyPath /* indexed_db_keypath */)
337 IPC_MESSAGE_CONTROL3(IndexedDBMsg_CallbacksSuccessInteger,
338 int32 /* ipc_thread_id */,
339 int32 /* ipc_callbacks_id */,
341 IPC_MESSAGE_CONTROL2(IndexedDBMsg_CallbacksSuccessUndefined,
342 int32 /* ipc_thread_id */,
343 int32 /* ipc_callbacks_id */)
344 IPC_MESSAGE_CONTROL3(IndexedDBMsg_CallbacksSuccessStringList,
345 int32 /* ipc_thread_id */,
346 int32 /* ipc_callbacks_id */,
347 std::vector<base::string16> /* dom_string_list */)
348 IPC_MESSAGE_CONTROL4(IndexedDBMsg_CallbacksError,
349 int32 /* ipc_thread_id */,
350 int32 /* ipc_callbacks_id */,
352 base::string16 /* message */)
353 IPC_MESSAGE_CONTROL2(IndexedDBMsg_CallbacksBlocked,
354 int32 /* ipc_thread_id */,
355 int32 /* ipc_callbacks_id */)
356 IPC_MESSAGE_CONTROL3(IndexedDBMsg_CallbacksIntBlocked,
357 int32 /* ipc_thread_id */,
358 int32 /* ipc_callbacks_id */,
359 int64 /* existing_version */)
360 IPC_MESSAGE_CONTROL1(IndexedDBMsg_CallbacksUpgradeNeeded,
361 IndexedDBMsg_CallbacksUpgradeNeeded_Params)
363 // IDBDatabaseCallback message handlers
364 IPC_MESSAGE_CONTROL2(IndexedDBMsg_DatabaseCallbacksForcedClose,
365 int32, /* ipc_thread_id */
366 int32) /* ipc_database_callbacks_id */
367 IPC_MESSAGE_CONTROL4(IndexedDBMsg_DatabaseCallbacksIntVersionChange,
368 int32, /* ipc_thread_id */
369 int32, /* ipc_database_callbacks_id */
370 int64, /* old_version */
371 int64) /* new_version */
372 IPC_MESSAGE_CONTROL5(IndexedDBMsg_DatabaseCallbacksAbort,
373 int32, /* ipc_thread_id */
374 int32, /* ipc_database_callbacks_id */
375 int64, /* transaction_id */
377 base::string16) /* message */
378 IPC_MESSAGE_CONTROL3(IndexedDBMsg_DatabaseCallbacksComplete,
379 int32, /* ipc_thread_id */
380 int32, /* ipc_database_callbacks_id */
381 int64) /* transaction_id */
383 // Indexed DB messages sent from the renderer to the browser.
385 // WebIDBCursor::advance() message.
386 IPC_MESSAGE_CONTROL4(IndexedDBHostMsg_CursorAdvance,
387 int32, /* ipc_cursor_id */
388 int32, /* ipc_thread_id */
389 int32, /* ipc_callbacks_id */
390 unsigned long) /* count */
392 // WebIDBCursor::continue() message.
393 IPC_MESSAGE_CONTROL5(IndexedDBHostMsg_CursorContinue,
394 int32, /* ipc_cursor_id */
395 int32, /* ipc_thread_id */
396 int32, /* ipc_callbacks_id */
397 content::IndexedDBKey, /* key */
398 content::IndexedDBKey) /* primary_key */
400 // WebIDBCursor::prefetchContinue() message.
401 IPC_MESSAGE_CONTROL4(IndexedDBHostMsg_CursorPrefetch,
402 int32, /* ipc_cursor_id */
403 int32, /* ipc_thread_id */
404 int32, /* ipc_callbacks_id */
407 // WebIDBCursor::prefetchReset() message.
408 IPC_MESSAGE_CONTROL3(IndexedDBHostMsg_CursorPrefetchReset,
409 int32, /* ipc_cursor_id */
410 int32, /* used_prefetches */
411 int32) /* used_prefetches */
413 // WebIDBFactory::getDatabaseNames() message.
414 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_FactoryGetDatabaseNames,
415 IndexedDBHostMsg_FactoryGetDatabaseNames_Params)
417 // WebIDBFactory::open() message.
418 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_FactoryOpen,
419 IndexedDBHostMsg_FactoryOpen_Params)
421 // WebIDBFactory::deleteDatabase() message.
422 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_FactoryDeleteDatabase,
423 IndexedDBHostMsg_FactoryDeleteDatabase_Params)
425 // WebIDBDatabase::createObjectStore() message.
426 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseCreateObjectStore,
427 IndexedDBHostMsg_DatabaseCreateObjectStore_Params)
429 // WebIDBDatabase::deleteObjectStore() message.
430 IPC_MESSAGE_CONTROL3(IndexedDBHostMsg_DatabaseDeleteObjectStore,
431 int32, /* ipc_database_id */
432 int64, /* transaction_id */
433 int64) /* object_store_id */
435 // WebIDBDatabase::createTransaction() message.
436 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseCreateTransaction,
437 IndexedDBHostMsg_DatabaseCreateTransaction_Params)
439 // WebIDBDatabase::close() message.
440 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseClose,
441 int32 /* ipc_database_callbacks_id */)
443 // WebIDBDatabase::~WebIDBDatabase() message.
444 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseDestroyed,
445 int32 /* ipc_database_id */)
447 // WebIDBDatabase::get() message.
448 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseGet,
449 IndexedDBHostMsg_DatabaseGet_Params)
451 // WebIDBDatabase::put() message.
452 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabasePut,
453 IndexedDBHostMsg_DatabasePut_Params)
455 // WebIDBDatabase::setIndexKeys() message.
456 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseSetIndexKeys,
457 IndexedDBHostMsg_DatabaseSetIndexKeys_Params)
459 // WebIDBDatabase::setIndexesReady() message.
460 IPC_MESSAGE_CONTROL4(IndexedDBHostMsg_DatabaseSetIndexesReady,
461 int32, /* ipc_database_id */
462 int64, /* transaction_id */
463 int64, /* object_store_id */
464 std::vector<int64>) /* index_ids */
466 // WebIDBDatabase::openCursor() message.
467 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseOpenCursor,
468 IndexedDBHostMsg_DatabaseOpenCursor_Params)
470 // WebIDBDatabase::count() message.
471 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseCount,
472 IndexedDBHostMsg_DatabaseCount_Params)
474 // WebIDBDatabase::deleteRange() message.
475 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseDeleteRange,
476 IndexedDBHostMsg_DatabaseDeleteRange_Params)
478 // WebIDBDatabase::clear() message.
479 IPC_MESSAGE_CONTROL5(IndexedDBHostMsg_DatabaseClear,
480 int32, /* ipc_thread_id */
481 int32, /* ipc_callbacks_id */
482 int32, /* ipc_database_id */
483 int64, /* transaction_id */
484 int64) /* object_store_id */
486 // WebIDBDatabase::createIndex() message.
487 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_DatabaseCreateIndex,
488 IndexedDBHostMsg_DatabaseCreateIndex_Params)
490 // WebIDBDatabase::deleteIndex() message.
491 IPC_MESSAGE_CONTROL4(IndexedDBHostMsg_DatabaseDeleteIndex,
492 int32, /* ipc_database_id */
493 int64, /* transaction_id */
494 int64, /* object_store_id */
495 int64) /* index_id */
497 // WebIDBDatabase::abort() message.
498 IPC_MESSAGE_CONTROL2(IndexedDBHostMsg_DatabaseAbort,
499 int32, /* ipc_database_id */
500 int64) /* transaction_id */
502 // WebIDBDatabase::commit() message.
503 IPC_MESSAGE_CONTROL2(IndexedDBHostMsg_DatabaseCommit,
504 int32, /* ipc_database_id */
505 int64) /* transaction_id */
507 // WebIDBDatabase::~WebIDBCursor() message.
508 IPC_MESSAGE_CONTROL1(IndexedDBHostMsg_CursorDestroyed,
509 int32 /* ipc_cursor_id */)