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

Side by Side Diff: content/browser/indexed_db/indexed_db_dispatcher_host.h

Issue 2784003002: [IndexedDB] Mojo testing harness. (Closed)
Patch Set: comments, removed thread flushing Created 3 years, 7 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
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_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_ 5 #ifndef CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_
6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_ 6 #define CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
11 #include <memory> 11 #include <memory>
12 #include <string> 12 #include <string>
13 #include <utility> 13 #include <utility>
14 #include <vector> 14 #include <vector>
15 15
16 #include "base/macros.h" 16 #include "base/macros.h"
17 #include "base/memory/ref_counted.h" 17 #include "base/memory/ref_counted.h"
18 #include "content/browser/blob_storage/chrome_blob_storage_context.h" 18 #include "content/browser/blob_storage/chrome_blob_storage_context.h"
19 #include "content/common/content_export.h"
19 #include "content/common/indexed_db/indexed_db.mojom.h" 20 #include "content/common/indexed_db/indexed_db.mojom.h"
20 #include "content/public/browser/browser_thread.h" 21 #include "content/public/browser/browser_thread.h"
21 #include "content/public/browser/render_process_host_observer.h" 22 #include "content/public/browser/render_process_host_observer.h"
22 #include "mojo/public/cpp/bindings/associated_binding_set.h" 23 #include "mojo/public/cpp/bindings/associated_binding_set.h"
23 #include "mojo/public/cpp/bindings/strong_associated_binding_set.h" 24 #include "mojo/public/cpp/bindings/strong_associated_binding_set.h"
24 #include "net/url_request/url_request_context_getter.h" 25 #include "net/url_request/url_request_context_getter.h"
25 #include "storage/browser/blob/blob_data_handle.h" 26 #include "storage/browser/blob/blob_data_handle.h"
26 27
27 namespace base { 28 namespace base {
28 class SequencedTaskRunner; 29 class SequencedTaskRunner;
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 // Called by UI thread. Used to kill outstanding bindings and weak pointers 78 // Called by UI thread. Used to kill outstanding bindings and weak pointers
78 // in callbacks. 79 // in callbacks.
79 void RenderProcessExited(RenderProcessHost* host, 80 void RenderProcessExited(RenderProcessHost* host,
80 base::TerminationStatus status, 81 base::TerminationStatus status,
81 int exit_code) override; 82 int exit_code) override;
82 83
83 private: 84 private:
84 class IDBThreadHelper; 85 class IDBThreadHelper;
85 // Friends to enable OnDestruct() delegation. 86 // Friends to enable OnDestruct() delegation.
86 friend class BrowserThread; 87 friend class BrowserThread;
88 friend class IndexedDBDispatcherHostTest;
87 friend class base::DeleteHelper<IndexedDBDispatcherHost>; 89 friend class base::DeleteHelper<IndexedDBDispatcherHost>;
88 90
89 ~IndexedDBDispatcherHost() override; 91 ~IndexedDBDispatcherHost() override;
90 92
91 // indexed_db::mojom::Factory implementation: 93 // indexed_db::mojom::Factory implementation:
92 void GetDatabaseNames( 94 void GetDatabaseNames(
93 ::indexed_db::mojom::CallbacksAssociatedPtrInfo callbacks_info, 95 ::indexed_db::mojom::CallbacksAssociatedPtrInfo callbacks_info,
94 const url::Origin& origin) override; 96 const url::Origin& origin) override;
95 void Open(::indexed_db::mojom::CallbacksAssociatedPtrInfo callbacks_info, 97 void Open(::indexed_db::mojom::CallbacksAssociatedPtrInfo callbacks_info,
96 ::indexed_db::mojom::DatabaseCallbacksAssociatedPtrInfo 98 ::indexed_db::mojom::DatabaseCallbacksAssociatedPtrInfo
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 IDBThreadHelper* idb_helper_; 134 IDBThreadHelper* idb_helper_;
133 135
134 base::WeakPtrFactory<IndexedDBDispatcherHost> weak_factory_; 136 base::WeakPtrFactory<IndexedDBDispatcherHost> weak_factory_;
135 137
136 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBDispatcherHost); 138 DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBDispatcherHost);
137 }; 139 };
138 140
139 } // namespace content 141 } // namespace content
140 142
141 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_ 143 #endif // CONTENT_BROWSER_INDEXED_DB_INDEXED_DB_DISPATCHER_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698