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

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

Issue 1752463002: Cleanup TrialToken in preparation of moving it to content/common. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 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
« no previous file with comments | « third_party/WebKit/Source/core/origin_trials/OriginTrialContextTest.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 WebTrialTokenValidator_h 5 #ifndef WebTrialTokenValidator_h
6 #define WebTrialTokenValidator_h 6 #define WebTrialTokenValidator_h
7 7
8 #include "public/platform/WebCallbacks.h" 8 #include "public/platform/WebCallbacks.h"
9 #include "public/platform/WebSecurityOrigin.h"
9 #include "public/platform/WebString.h" 10 #include "public/platform/WebString.h"
10 11
11 namespace blink { 12 namespace blink {
12 13
13 // This interface abstracts the task of validating a token for an experimental 14 // This interface abstracts the task of validating a token for an experimental
14 // feature. Experimental features can be turned on and off at runtime for a 15 // feature. Experimental features can be turned on and off at runtime for a
15 // specific renderer, depending on the presence of a valid token provided by 16 // specific renderer, depending on the presence of a valid token provided by
16 // the origin. 17 // the origin.
17 // 18 //
18 // More documentation on the design of the experimental framework is at 19 // More documentation on the design of the experimental framework is at
19 // https://docs.google.com/document/d/1qVP2CK1lbfmtIJRIm6nwuEFFhGhYbtThLQPo3CSTt mg 20 // https://docs.google.com/document/d/1qVP2CK1lbfmtIJRIm6nwuEFFhGhYbtThLQPo3CSTt mg
20 21
21 class WebTrialTokenValidator { 22 class WebTrialTokenValidator {
22 public: 23 public:
23 virtual ~WebTrialTokenValidator() {} 24 virtual ~WebTrialTokenValidator() {}
24 25
25 // Returns true if the given token is valid for the specified origin and 26 // Returns true if the given token is valid for the specified origin and
26 // feature name. 27 // feature name.
27 virtual bool validateToken(const WebString& token, const WebString& origin, const WebString& featureName) = 0; 28 virtual bool validateToken(const WebString& token, const WebSecurityOrigin&, const WebString& featureName) = 0;
28 }; 29 };
29 30
30 } // namespace blink 31 } // namespace blink
31 32
32 #endif // WebTrialTokenValidator_h 33 #endif // WebTrialTokenValidator_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/origin_trials/OriginTrialContextTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698