Lily Chen | ab36a11 | 2019-09-19 20:17:28 | [diff] [blame^] | 1 | // Copyright 2019 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 NET_COOKIES_COOKIE_ACCESS_DELEGATE_H_ |
| 6 | #define NET_COOKIES_COOKIE_ACCESS_DELEGATE_H_ |
| 7 | |
| 8 | #include "net/base/net_export.h" |
| 9 | #include "net/cookies/canonical_cookie.h" |
| 10 | #include "net/cookies/cookie_constants.h" |
| 11 | |
| 12 | namespace net { |
| 13 | |
| 14 | class NET_EXPORT CookieAccessDelegate { |
| 15 | public: |
| 16 | CookieAccessDelegate(); |
| 17 | virtual ~CookieAccessDelegate(); |
| 18 | |
| 19 | // Gets the access semantics to apply to |cookie|, based on its domain (i.e., |
| 20 | // whether a policy specifies that legacy access semantics should apply). |
| 21 | virtual CookieAccessSemantics GetAccessSemantics( |
| 22 | const CanonicalCookie& cookie) const = 0; |
| 23 | |
| 24 | private: |
| 25 | DISALLOW_COPY_AND_ASSIGN(CookieAccessDelegate); |
| 26 | }; |
| 27 | |
| 28 | } // namespace net |
| 29 | |
| 30 | #endif // NET_COOKIES_COOKIE_ACCESS_DELEGATE_H_ |