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

Side by Side Diff: sync/internal_api/public/http_bridge.h

Issue 13243003: Move MessageLoop to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « sync/internal_api/public/engine/passive_model_worker.h ('k') | ui/aura/test/aura_test_base.h » ('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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_ 5 #ifndef SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_
6 #define SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_ 6 #define SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/gtest_prod_util.h" 12 #include "base/gtest_prod_util.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/synchronization/lock.h" 14 #include "base/synchronization/lock.h"
15 #include "base/synchronization/waitable_event.h" 15 #include "base/synchronization/waitable_event.h"
16 #include "googleurl/src/gurl.h" 16 #include "googleurl/src/gurl.h"
17 #include "net/url_request/url_fetcher_delegate.h" 17 #include "net/url_request/url_fetcher_delegate.h"
18 #include "net/url_request/url_request_context.h" 18 #include "net/url_request/url_request_context.h"
19 #include "net/url_request/url_request_context_getter.h" 19 #include "net/url_request/url_request_context_getter.h"
20 #include "sync/base/sync_export.h" 20 #include "sync/base/sync_export.h"
21 #include "sync/internal_api/public/http_post_provider_factory.h" 21 #include "sync/internal_api/public/http_post_provider_factory.h"
22 #include "sync/internal_api/public/http_post_provider_interface.h" 22 #include "sync/internal_api/public/http_post_provider_interface.h"
23 23
24 class HttpBridgeTest;
25
26 namespace base {
24 class MessageLoop; 27 class MessageLoop;
25 class HttpBridgeTest; 28 }
26 29
27 namespace net { 30 namespace net {
28 class HttpResponseHeaders; 31 class HttpResponseHeaders;
29 class HttpUserAgentSettings; 32 class HttpUserAgentSettings;
30 class URLFetcher; 33 class URLFetcher;
31 } 34 }
32 35
33 namespace syncer { 36 namespace syncer {
34 37
35 // A bridge between the syncer and Chromium HTTP layers. 38 // A bridge between the syncer and Chromium HTTP layers.
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 // RequestContext definition for details. 153 // RequestContext definition for details.
151 const scoped_refptr<RequestContextGetter> context_getter_for_request_; 154 const scoped_refptr<RequestContextGetter> context_getter_for_request_;
152 155
153 const scoped_refptr<base::SingleThreadTaskRunner> network_task_runner_; 156 const scoped_refptr<base::SingleThreadTaskRunner> network_task_runner_;
154 157
155 // The message loop of the thread we were created on. This is the thread that 158 // The message loop of the thread we were created on. This is the thread that
156 // will block on MakeSynchronousPost while the IO thread fetches data from 159 // will block on MakeSynchronousPost while the IO thread fetches data from
157 // the network. 160 // the network.
158 // This should be the main syncer thread (SyncerThread) which is what blocks 161 // This should be the main syncer thread (SyncerThread) which is what blocks
159 // on network IO through curl_easy_perform. 162 // on network IO through curl_easy_perform.
160 MessageLoop* const created_on_loop_; 163 base::MessageLoop* const created_on_loop_;
161 164
162 // The URL to POST to. 165 // The URL to POST to.
163 GURL url_for_request_; 166 GURL url_for_request_;
164 167
165 // POST payload information. 168 // POST payload information.
166 std::string content_type_; 169 std::string content_type_;
167 std::string request_content_; 170 std::string request_content_;
168 std::string extra_headers_; 171 std::string extra_headers_;
169 172
170 // A waitable event we use to provide blocking semantics to 173 // A waitable event we use to provide blocking semantics to
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 225
223 const scoped_refptr<HttpBridge::RequestContextGetter> 226 const scoped_refptr<HttpBridge::RequestContextGetter>
224 request_context_getter_; 227 request_context_getter_;
225 228
226 DISALLOW_COPY_AND_ASSIGN(HttpBridgeFactory); 229 DISALLOW_COPY_AND_ASSIGN(HttpBridgeFactory);
227 }; 230 };
228 231
229 } // namespace syncer 232 } // namespace syncer
230 233
231 #endif // SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_ 234 #endif // SYNC_INTERNAL_API_PUBLIC_HTTP_BRIDGE_H_
OLDNEW
« no previous file with comments | « sync/internal_api/public/engine/passive_model_worker.h ('k') | ui/aura/test/aura_test_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698