| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 #include "ios/net/cookies/cookie_store_ios.h" | 5 #include "ios/net/cookies/cookie_store_ios.h" |
| 6 | 6 |
| 7 #import <Foundation/Foundation.h> | 7 #import <Foundation/Foundation.h> |
| 8 | 8 |
| 9 #include "base/bind_helpers.h" | 9 #include "base/bind_helpers.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 store_->DeleteCanonicalCookieAsync(cookie, callback); | 145 store_->DeleteCanonicalCookieAsync(cookie, callback); |
| 146 } | 146 } |
| 147 | 147 |
| 148 void DeleteAllCreatedBetweenAsync(const base::Time& delete_begin, | 148 void DeleteAllCreatedBetweenAsync(const base::Time& delete_begin, |
| 149 const base::Time& delete_end, | 149 const base::Time& delete_end, |
| 150 const DeleteCallback& callback) override { | 150 const DeleteCallback& callback) override { |
| 151 RoundTrip(); | 151 RoundTrip(); |
| 152 store_->DeleteAllCreatedBetweenAsync(delete_begin, delete_end, callback); | 152 store_->DeleteAllCreatedBetweenAsync(delete_begin, delete_end, callback); |
| 153 } | 153 } |
| 154 | 154 |
| 155 void DeleteAllCreatedBetweenForHostAsync( | 155 void DeleteAllCreatedBetweenWithPredicateAsync( |
| 156 const base::Time delete_begin, | 156 const base::Time& delete_begin, |
| 157 const base::Time delete_end, | 157 const base::Time& delete_end, |
| 158 const GURL& url, | 158 const CookiePredicate& predicate, |
| 159 const DeleteCallback& callback) override { | 159 const DeleteCallback& callback) override { |
| 160 RoundTrip(); | 160 RoundTrip(); |
| 161 store_->DeleteAllCreatedBetweenForHostAsync(delete_begin, delete_end, url, | 161 store_->DeleteAllCreatedBetweenWithPredicateAsync(delete_begin, delete_end, |
| 162 callback); | 162 predicate, callback); |
| 163 } | 163 } |
| 164 | 164 |
| 165 void DeleteSessionCookiesAsync(const DeleteCallback& callback) override { | 165 void DeleteSessionCookiesAsync(const DeleteCallback& callback) override { |
| 166 RoundTrip(); | 166 RoundTrip(); |
| 167 store_->DeleteSessionCookiesAsync(callback); | 167 store_->DeleteSessionCookiesAsync(callback); |
| 168 } | 168 } |
| 169 | 169 |
| 170 void FlushStore(const base::Closure& callback) override { | 170 void FlushStore(const base::Closure& callback) override { |
| 171 RoundTrip(); | 171 RoundTrip(); |
| 172 store_->FlushStore(callback); | 172 store_->FlushStore(callback); |
| (...skipping 816 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 989 EXPECT_EQ(2U, cookies.size()); | 989 EXPECT_EQ(2U, cookies.size()); |
| 990 // this deletes the callback | 990 // this deletes the callback |
| 991 handle.reset(); | 991 handle.reset(); |
| 992 SetSystemCookie(kTestCookieURL, "abc", "jkl"); | 992 SetSystemCookie(kTestCookieURL, "abc", "jkl"); |
| 993 EXPECT_EQ(2U, cookies.size()); | 993 EXPECT_EQ(2U, cookies.size()); |
| 994 DeleteSystemCookie(kTestCookieURL, "abc"); | 994 DeleteSystemCookie(kTestCookieURL, "abc"); |
| 995 store_->UnSynchronize(); | 995 store_->UnSynchronize(); |
| 996 } | 996 } |
| 997 | 997 |
| 998 } // namespace net | 998 } // namespace net |
| OLD | NEW |