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

Side by Side Diff: android_webview/browser/aw_request_handler.h

Issue 1350553005: [Android WebView] Call shouldInterceptRequest on a background thread (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments addressed Created 5 years, 2 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_REQUEST_HANDLER_H_
6 #define ANDROID_WEBVIEW_BROWSER_AW_REQUEST_HANDLER_H_
7
8 #include "android_webview/browser/net/android_stream_reader_url_request_job.h"
9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h"
11
12 namespace net {
13 class URLRequest;
14 class URLRequestJob;
15 class NetworkDelegate;
16 }
17
18 namespace android_webview {
19
20 class AwWebResourceResponse;
21
22 class AwRequestHandler : public base::RefCounted<AwRequestHandler> {
mmenke 2015/09/29 15:56:05 This class really needs some documentation, as do
mmenke 2015/09/29 15:56:05 Refcounting this seems like a bad idea, that's jus
mnaganov (inactive) 2015/09/29 23:45:35 Not relevant anymore.
mnaganov (inactive) 2015/09/29 23:45:35 It seems that we actually can do without it, remov
23 public:
24 AwRequestHandler();
25
26 AndroidStreamReaderURLRequestJob* MaybeInterceptRequest(
27 net::URLRequest* request,
28 net::NetworkDelegate* network_delegate);
29
30 private:
31 friend class base::RefCounted<AwRequestHandler>;
32
33 ~AwRequestHandler();
mmenke 2015/09/29 15:56:05 +override
mnaganov (inactive) 2015/09/29 23:45:35 Not relevant anymore.
34 bool QueryForAwWebResourceResponse(net::URLRequest* request);
35 void QueryForAwWebResourceResponseDone(
36 scoped_ptr<AwWebResourceResponse> response);
37
38 scoped_refptr<AndroidStreamReaderURLRequestJob> job_;
39
40 DISALLOW_COPY_AND_ASSIGN(AwRequestHandler);
41 };
42
43 } // namespace android_webview
44
45 #endif // ANDROID_WEBVIEW_BROWSER_AW_REQUEST_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698