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

Side by Side Diff: third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.h

Issue 2738953002: Rename WebParsedFeaturePolicyHeader to WebParsedFeaturePolicy (Closed)
Patch Set: ParsedFeaturePolicyHeader => ParsedFeaturePolicy (content version) Created 3 years, 9 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 FeaturePolicy_h 5 #ifndef FeaturePolicy_h
6 #define FeaturePolicy_h 6 #define FeaturePolicy_h
7 7
8 #include "platform/PlatformExport.h" 8 #include "platform/PlatformExport.h"
9 #include "platform/weborigin/SecurityOrigin.h" 9 #include "platform/weborigin/SecurityOrigin.h"
10 #include "public/platform/WebFeaturePolicy.h" 10 #include "public/platform/WebFeaturePolicy.h"
11 #include "wtf/RefPtr.h" 11 #include "wtf/RefPtr.h"
12 #include "wtf/Vector.h" 12 #include "wtf/Vector.h"
13 #include "wtf/text/WTFString.h" 13 #include "wtf/text/WTFString.h"
14 14
15 #include <memory> 15 #include <memory>
16 16
17 namespace blink { 17 namespace blink {
18 18
19 // Returns the corresponding WebFeaturePolicyFeature enum given a feature 19 // Returns the corresponding WebFeaturePolicyFeature enum given a feature
20 // string. 20 // string.
21 PLATFORM_EXPORT WebFeaturePolicyFeature 21 PLATFORM_EXPORT WebFeaturePolicyFeature
22 getWebFeaturePolicyFeature(const String& feature); 22 getWebFeaturePolicyFeature(const String& feature);
23 23
24 // Converts a JSON feature policy string into a vector of whitelists, one for 24 // Converts a JSON feature policy string into a vector of whitelists, one for
25 // each feature specified. Unrecognized features are parsed and included 25 // each feature specified. Unrecognized features are parsed and included
26 // but will be filtered out when the policy is constructed. If |messages| is 26 // but will be filtered out when the policy is constructed. If |messages| is
27 // not null, then any errors in the input will cause an error message to be 27 // not null, then any errors in the input will cause an error message to be
28 // appended to it. 28 // appended to it.
29 PLATFORM_EXPORT WebParsedFeaturePolicyHeader 29 PLATFORM_EXPORT WebParsedFeaturePolicy
30 parseFeaturePolicy(const String& policy, 30 parseFeaturePolicy(const String& policy,
31 RefPtr<SecurityOrigin>, 31 RefPtr<SecurityOrigin>,
32 Vector<String>* messages); 32 Vector<String>* messages);
33 33
34 } // namespace blink 34 } // namespace blink
35 35
36 #endif // FeaturePolicy_h 36 #endif // FeaturePolicy_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698