OLD | NEW |
1 // Copyright (c) 2017 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2017 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 #import "ios/net/cookies/cookie_store_ios_persistent.h" | 5 #import "ios/net/cookies/cookie_store_ios_persistent.h" |
6 | 6 |
7 #import <Foundation/Foundation.h> | 7 #import <Foundation/Foundation.h> |
8 | 8 |
9 #include "ios/net/cookies/system_cookie_util.h" | 9 #include "ios/net/cookies/system_cookie_util.h" |
10 #include "net/cookies/cookie_monster.h" | 10 #include "net/cookies/cookie_monster.h" |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 CookiePriority priority, | 50 CookiePriority priority, |
51 const SetCookiesCallback& callback) { | 51 const SetCookiesCallback& callback) { |
52 DCHECK(thread_checker().CalledOnValidThread()); | 52 DCHECK(thread_checker().CalledOnValidThread()); |
53 | 53 |
54 cookie_monster()->SetCookieWithDetailsAsync( | 54 cookie_monster()->SetCookieWithDetailsAsync( |
55 url, name, value, domain, path, creation_time, expiration_time, | 55 url, name, value, domain, path, creation_time, expiration_time, |
56 last_access_time, secure, http_only, same_site, priority, | 56 last_access_time, secure, http_only, same_site, priority, |
57 WrapSetCallback(callback)); | 57 WrapSetCallback(callback)); |
58 } | 58 } |
59 | 59 |
| 60 void CookieStoreIOSPersistent::SetCanonicalCookieAsync( |
| 61 const CanonicalCookie& cookie, |
| 62 bool secure_source, |
| 63 bool modify_http_only, |
| 64 const SetCookiesCallback& callback) { |
| 65 DCHECK(thread_checker().CalledOnValidThread()); |
| 66 |
| 67 cookie_monster()->SetCanonicalCookieAsync( |
| 68 cookie, secure_source, modify_http_only, WrapSetCallback(callback)); |
| 69 } |
| 70 |
60 void CookieStoreIOSPersistent::GetCookiesWithOptionsAsync( | 71 void CookieStoreIOSPersistent::GetCookiesWithOptionsAsync( |
61 const GURL& url, | 72 const GURL& url, |
62 const net::CookieOptions& options, | 73 const net::CookieOptions& options, |
63 const GetCookiesCallback& callback) { | 74 const GetCookiesCallback& callback) { |
64 DCHECK(thread_checker().CalledOnValidThread()); | 75 DCHECK(thread_checker().CalledOnValidThread()); |
65 cookie_monster()->GetCookiesWithOptionsAsync(url, options, callback); | 76 cookie_monster()->GetCookiesWithOptionsAsync(url, options, callback); |
66 } | 77 } |
67 | 78 |
68 void CookieStoreIOSPersistent::GetCookieListWithOptionsAsync( | 79 void CookieStoreIOSPersistent::GetCookieListWithOptionsAsync( |
69 const GURL& url, | 80 const GURL& url, |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
132 } | 143 } |
133 | 144 |
134 #pragma mark - | 145 #pragma mark - |
135 #pragma mark Private methods | 146 #pragma mark Private methods |
136 | 147 |
137 void CookieStoreIOSPersistent::WriteToCookieMonster(NSArray* system_cookies) {} | 148 void CookieStoreIOSPersistent::WriteToCookieMonster(NSArray* system_cookies) {} |
138 | 149 |
139 void CookieStoreIOSPersistent::OnSystemCookiesChanged() {} | 150 void CookieStoreIOSPersistent::OnSystemCookiesChanged() {} |
140 | 151 |
141 } // namespace net | 152 } // namespace net |
OLD | NEW |