Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(569)

Side by Side Diff: content/common/indexed_db/indexed_db_dispatcher.h

Issue 10834039: Plumb through the rest of OnSuccessWithKey (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | content/common/indexed_db/indexed_db_dispatcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 #ifndef CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_ 5 #ifndef CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_
6 #define CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_ 6 #define CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 19 matching lines...) Expand all
30 } 30 }
31 31
32 namespace WebKit { 32 namespace WebKit {
33 class WebFrame; 33 class WebFrame;
34 class WebIDBKeyRange; 34 class WebIDBKeyRange;
35 class WebIDBTransaction; 35 class WebIDBTransaction;
36 } 36 }
37 37
38 namespace content { 38 namespace content {
39 class IndexedDBKey; 39 class IndexedDBKey;
40 class IndexedDBKeyPath;
40 class IndexedDBKeyRange; 41 class IndexedDBKeyRange;
41 class SerializedScriptValue; 42 class SerializedScriptValue;
42 } 43 }
43 44
44 CONTENT_EXPORT extern const size_t kMaxIDBValueSizeInBytes; 45 CONTENT_EXPORT extern const size_t kMaxIDBValueSizeInBytes;
45 46
46 // Handle the indexed db related communication for this context thread - the 47 // Handle the indexed db related communication for this context thread - the
47 // main thread and each worker thread have their own copies. 48 // main thread and each worker thread have their own copies.
48 class CONTENT_EXPORT IndexedDBDispatcher 49 class CONTENT_EXPORT IndexedDBDispatcher
49 : public webkit_glue::WorkerTaskRunner::Observer { 50 : public webkit_glue::WorkerTaskRunner::Observer {
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 const IndexedDBMsg_CallbacksSuccessCursorContinue_Params& p); 236 const IndexedDBMsg_CallbacksSuccessCursorContinue_Params& p);
236 void OnSuccessCursorPrefetch( 237 void OnSuccessCursorPrefetch(
237 const IndexedDBMsg_CallbacksSuccessCursorPrefetch_Params& p); 238 const IndexedDBMsg_CallbacksSuccessCursorPrefetch_Params& p);
238 void OnSuccessStringList(int32 thread_id, 239 void OnSuccessStringList(int32 thread_id,
239 int32 response_id, 240 int32 response_id,
240 const std::vector<string16>& value); 241 const std::vector<string16>& value);
241 void OnSuccessSerializedScriptValue( 242 void OnSuccessSerializedScriptValue(
242 int32 thread_id, 243 int32 thread_id,
243 int32 response_id, 244 int32 response_id,
244 const content::SerializedScriptValue& value); 245 const content::SerializedScriptValue& value);
246 void OnSuccessSerializedScriptValueWithKey(
247 int32 thread_id,
248 int32 response_id,
249 const content::SerializedScriptValue& value,
250 const content::IndexedDBKey& primary_key,
251 const content::IndexedDBKeyPath& key_path);
245 void OnError(int32 thread_id, 252 void OnError(int32 thread_id,
246 int32 response_id, 253 int32 response_id,
247 int code, 254 int code,
248 const string16& message); 255 const string16& message);
249 void OnBlocked(int32 thread_id, int32 response_id); 256 void OnBlocked(int32 thread_id, int32 response_id);
250 void OnAbort(int32 thread_id, int32 transaction_id); 257 void OnAbort(int32 thread_id, int32 transaction_id);
251 void OnComplete(int32 thread_id, int32 transaction_id); 258 void OnComplete(int32 thread_id, int32 transaction_id);
252 void OnVersionChange(int32 thread_id, 259 void OnVersionChange(int32 thread_id,
253 int32 database_id, 260 int32 database_id,
254 const string16& newVersion); 261 const string16& newVersion);
255 262
256 // Reset cursor prefetch caches for all cursors except exception_cursor_id. 263 // Reset cursor prefetch caches for all cursors except exception_cursor_id.
257 void ResetCursorPrefetchCaches(int32 exception_cursor_id = -1); 264 void ResetCursorPrefetchCaches(int32 exception_cursor_id = -1);
258 265
259 // Careful! WebIDBCallbacks wraps non-threadsafe data types. It must be 266 // Careful! WebIDBCallbacks wraps non-threadsafe data types. It must be
260 // destroyed and used on the same thread it was created on. 267 // destroyed and used on the same thread it was created on.
261 IDMap<WebKit::WebIDBCallbacks, IDMapOwnPointer> pending_callbacks_; 268 IDMap<WebKit::WebIDBCallbacks, IDMapOwnPointer> pending_callbacks_;
262 IDMap<WebKit::WebIDBTransactionCallbacks, IDMapOwnPointer> 269 IDMap<WebKit::WebIDBTransactionCallbacks, IDMapOwnPointer>
263 pending_transaction_callbacks_; 270 pending_transaction_callbacks_;
264 IDMap<WebKit::WebIDBDatabaseCallbacks, IDMapOwnPointer> 271 IDMap<WebKit::WebIDBDatabaseCallbacks, IDMapOwnPointer>
265 pending_database_callbacks_; 272 pending_database_callbacks_;
266 273
267 // Map from cursor id to RendererWebIDBCursorImpl. 274 // Map from cursor id to RendererWebIDBCursorImpl.
268 std::map<int32, RendererWebIDBCursorImpl*> cursors_; 275 std::map<int32, RendererWebIDBCursorImpl*> cursors_;
269 276
270 DISALLOW_COPY_AND_ASSIGN(IndexedDBDispatcher); 277 DISALLOW_COPY_AND_ASSIGN(IndexedDBDispatcher);
271 }; 278 };
272 279
273 #endif // CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_ 280 #endif // CONTENT_COMMON_INDEXED_DB_INDEXED_DB_DISPATCHER_H_
OLDNEW
« no previous file with comments | « no previous file | content/common/indexed_db/indexed_db_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698