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

Side by Side Diff: third_party/WebKit/public/platform/WebDocumentSubresourceFilter.h

Issue 2683413003: Introduce AsyncDocumentSubresourceFilter. (Closed)
Patch Set: Fix fix blink test build. 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 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 WebDocumentSubresourceFilter_h 5 #ifndef WebDocumentSubresourceFilter_h
6 #define WebDocumentSubresourceFilter_h 6 #define WebDocumentSubresourceFilter_h
7 7
8 #include "public/platform/WebDocumentSubresourceFilterLoadPolicy.h"
8 #include "public/platform/WebURLRequest.h" 9 #include "public/platform/WebURLRequest.h"
9 10
10 namespace blink { 11 namespace blink {
11 12
12 class WebURL; 13 class WebURL;
13 14
14 class WebDocumentSubresourceFilter { 15 class WebDocumentSubresourceFilter {
15 public: 16 public:
16 enum LoadPolicy { Allow, Disallow, WouldDisallow };
17 virtual ~WebDocumentSubresourceFilter() {} 17 virtual ~WebDocumentSubresourceFilter() {}
18 virtual LoadPolicy getLoadPolicy(const WebURL& resourceUrl, 18
19 WebURLRequest::RequestContext) = 0; 19 virtual WebDocumentSubresourceFilterLoadPolicy getLoadPolicy(
20 const WebURL& resourceUrl,
21 WebURLRequest::RequestContext) = 0;
20 22
21 // Report that a resource loaded by the document (not a preload) was 23 // Report that a resource loaded by the document (not a preload) was
22 // disallowed. 24 // disallowed.
23 virtual void reportDisallowedLoad() = 0; 25 virtual void reportDisallowedLoad() = 0;
24 }; 26 };
25 27
26 } // namespace blink 28 } // namespace blink
27 29
28 #endif // WebDocumentSubresourceFilter_h 30 #endif // WebDocumentSubresourceFilter_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698