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

Side by Side Diff: content/browser/loader/url_loader_factory_impl.h

Issue 2824193002: Enable use_once_callback for //content/common/*.mojom (Closed)
Patch Set: rebase Created 3 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_LOADER_URL_LOADER_FACTORY_IMPL_H_ 5 #ifndef CONTENT_BROWSER_LOADER_URL_LOADER_FACTORY_IMPL_H_
6 #define CONTENT_BROWSER_LOADER_URL_LOADER_FACTORY_IMPL_H_ 6 #define CONTENT_BROWSER_LOADER_URL_LOADER_FACTORY_IMPL_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 13 matching lines...) Expand all
24 24
25 void CreateLoaderAndStart(mojom::URLLoaderAssociatedRequest request, 25 void CreateLoaderAndStart(mojom::URLLoaderAssociatedRequest request,
26 int32_t routing_id, 26 int32_t routing_id,
27 int32_t request_id, 27 int32_t request_id,
28 uint32_t options, 28 uint32_t options,
29 const ResourceRequest& url_request, 29 const ResourceRequest& url_request,
30 mojom::URLLoaderClientPtr client) override; 30 mojom::URLLoaderClientPtr client) override;
31 void SyncLoad(int32_t routing_id, 31 void SyncLoad(int32_t routing_id,
32 int32_t request_id, 32 int32_t request_id,
33 const ResourceRequest& request, 33 const ResourceRequest& request,
34 const SyncLoadCallback& callback) override; 34 SyncLoadCallback callback) override;
35 35
36 static void CreateLoaderAndStart(ResourceRequesterInfo* requester_info, 36 static void CreateLoaderAndStart(ResourceRequesterInfo* requester_info,
37 mojom::URLLoaderAssociatedRequest request, 37 mojom::URLLoaderAssociatedRequest request,
38 int32_t routing_id, 38 int32_t routing_id,
39 int32_t request_id, 39 int32_t request_id,
40 const ResourceRequest& url_request, 40 const ResourceRequest& url_request,
41 mojom::URLLoaderClientPtr client); 41 mojom::URLLoaderClientPtr client);
42 static void SyncLoad(ResourceRequesterInfo* requester_info, 42 static void SyncLoad(ResourceRequesterInfo* requester_info,
43 int32_t routing_id, 43 int32_t routing_id,
44 int32_t request_id, 44 int32_t request_id,
45 const ResourceRequest& request, 45 const ResourceRequest& request,
46 const SyncLoadCallback& callback); 46 SyncLoadCallback callback);
47 47
48 // Creates a URLLoaderFactoryImpl instance. The instance is held by the 48 // Creates a URLLoaderFactoryImpl instance. The instance is held by the
49 // StrongBinding in it, so this function doesn't return the instance. 49 // StrongBinding in it, so this function doesn't return the instance.
50 CONTENT_EXPORT static void Create( 50 CONTENT_EXPORT static void Create(
51 scoped_refptr<ResourceRequesterInfo> requester_info, 51 scoped_refptr<ResourceRequesterInfo> requester_info,
52 mojom::URLLoaderFactoryRequest request, 52 mojom::URLLoaderFactoryRequest request,
53 const scoped_refptr<base::SingleThreadTaskRunner>& io_thread_runner); 53 const scoped_refptr<base::SingleThreadTaskRunner>& io_thread_runner);
54 54
55 private: 55 private:
56 explicit URLLoaderFactoryImpl( 56 explicit URLLoaderFactoryImpl(
57 scoped_refptr<ResourceRequesterInfo> requester_info, 57 scoped_refptr<ResourceRequesterInfo> requester_info,
58 const scoped_refptr<base::SingleThreadTaskRunner>& io_thread_runner); 58 const scoped_refptr<base::SingleThreadTaskRunner>& io_thread_runner);
59 59
60 scoped_refptr<ResourceRequesterInfo> requester_info_; 60 scoped_refptr<ResourceRequesterInfo> requester_info_;
61 61
62 // Task runner for the IO thead. 62 // Task runner for the IO thead.
63 scoped_refptr<base::SingleThreadTaskRunner> io_thread_task_runner_; 63 scoped_refptr<base::SingleThreadTaskRunner> io_thread_task_runner_;
64 64
65 DISALLOW_COPY_AND_ASSIGN(URLLoaderFactoryImpl); 65 DISALLOW_COPY_AND_ASSIGN(URLLoaderFactoryImpl);
66 }; 66 };
67 67
68 } // namespace content 68 } // namespace content
69 69
70 #endif // CONTENT_BROWSER_LOADER_URL_LOADER_FACTORY_IMPL_H_ 70 #endif // CONTENT_BROWSER_LOADER_URL_LOADER_FACTORY_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/loader/test_url_loader_client.cc ('k') | content/browser/loader/url_loader_factory_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698