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

Side by Side Diff: content/child/web_url_loader_impl.h

Issue 2695333002: Mojo C++ bindings: remove usage of AssociatedGroup from content/ (Closed)
Patch Set: . Created 3 years, 10 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_CHILD_WEB_URL_LOADER_IMPL_H_ 5 #ifndef CONTENT_CHILD_WEB_URL_LOADER_IMPL_H_
6 #define CONTENT_CHILD_WEB_URL_LOADER_IMPL_H_ 6 #define CONTENT_CHILD_WEB_URL_LOADER_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 "content/common/content_export.h" 10 #include "content/common/content_export.h"
11 #include "content/common/url_loader_factory.mojom.h" 11 #include "content/common/url_loader_factory.mojom.h"
12 #include "content/public/common/resource_response.h" 12 #include "content/public/common/resource_response.h"
13 #include "net/url_request/redirect_info.h" 13 #include "net/url_request/redirect_info.h"
14 #include "third_party/WebKit/public/platform/WebURLLoader.h" 14 #include "third_party/WebKit/public/platform/WebURLLoader.h"
15 #include "url/gurl.h" 15 #include "url/gurl.h"
16 16
17 namespace mojo {
18 class AssociatedGroup;
19 } // namespace mojo
20
21 namespace content { 17 namespace content {
22 18
23 class ResourceDispatcher; 19 class ResourceDispatcher;
24 struct ResourceResponseInfo; 20 struct ResourceResponseInfo;
25 21
26 // PlzNavigate: Used to override parameters of the navigation request. 22 // PlzNavigate: Used to override parameters of the navigation request.
27 struct CONTENT_EXPORT StreamOverrideParameters { 23 struct CONTENT_EXPORT StreamOverrideParameters {
28 public: 24 public:
29 StreamOverrideParameters(); 25 StreamOverrideParameters();
30 ~StreamOverrideParameters(); 26 ~StreamOverrideParameters();
31 // TODO(clamy): The browser should be made aware on destruction of this struct 27 // TODO(clamy): The browser should be made aware on destruction of this struct
32 // that it can release its associated stream handle. 28 // that it can release its associated stream handle.
33 GURL stream_url; 29 GURL stream_url;
34 ResourceResponseHead response; 30 ResourceResponseHead response;
35 std::vector<GURL> redirects; 31 std::vector<GURL> redirects;
36 std::vector<ResourceResponseInfo> redirect_responses; 32 std::vector<ResourceResponseInfo> redirect_responses;
37 33
38 // The delta between the actual transfer size and the one reported by the 34 // The delta between the actual transfer size and the one reported by the
39 // AsyncResourceLoader due to not having the ResourceResponse. 35 // AsyncResourceLoader due to not having the ResourceResponse.
40 int total_transfer_size_delta; 36 int total_transfer_size_delta;
41 }; 37 };
42 38
43 class CONTENT_EXPORT WebURLLoaderImpl 39 class CONTENT_EXPORT WebURLLoaderImpl
44 : public NON_EXPORTED_BASE(blink::WebURLLoader) { 40 : public NON_EXPORTED_BASE(blink::WebURLLoader) {
45 public: 41 public:
46 42
47 // Takes ownership of |web_task_runner|. 43 // Takes ownership of |web_task_runner|.
48 WebURLLoaderImpl(ResourceDispatcher* resource_dispatcher, 44 WebURLLoaderImpl(ResourceDispatcher* resource_dispatcher,
49 mojom::URLLoaderFactory* url_loader_factory, 45 mojom::URLLoaderFactory* url_loader_factory);
50 mojo::AssociatedGroup* associated_group);
51 ~WebURLLoaderImpl() override; 46 ~WebURLLoaderImpl() override;
52 47
53 static void PopulateURLResponse(const GURL& url, 48 static void PopulateURLResponse(const GURL& url,
54 const ResourceResponseInfo& info, 49 const ResourceResponseInfo& info,
55 blink::WebURLResponse* response, 50 blink::WebURLResponse* response,
56 bool report_security_info); 51 bool report_security_info);
57 static blink::WebURLRequest PopulateURLRequestForRedirect( 52 static blink::WebURLRequest PopulateURLRequestForRedirect(
58 const blink::WebURLRequest& request, 53 const blink::WebURLRequest& request,
59 const net::RedirectInfo& redirect_info, 54 const net::RedirectInfo& redirect_info,
60 blink::WebURLRequest::SkipServiceWorker skip_service_worker); 55 blink::WebURLRequest::SkipServiceWorker skip_service_worker);
(...skipping 19 matching lines...) Expand all
80 class Context; 75 class Context;
81 class RequestPeerImpl; 76 class RequestPeerImpl;
82 scoped_refptr<Context> context_; 77 scoped_refptr<Context> context_;
83 78
84 DISALLOW_COPY_AND_ASSIGN(WebURLLoaderImpl); 79 DISALLOW_COPY_AND_ASSIGN(WebURLLoaderImpl);
85 }; 80 };
86 81
87 } // namespace content 82 } // namespace content
88 83
89 #endif // CONTENT_CHILD_WEB_URL_LOADER_IMPL_H_ 84 #endif // CONTENT_CHILD_WEB_URL_LOADER_IMPL_H_
OLDNEW
« no previous file with comments | « content/child/url_response_body_consumer_unittest.cc ('k') | content/child/web_url_loader_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698