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

Side by Side Diff: net/cookies/cookie_monster_store_test.h

Issue 2937963003: Shift cookie system callbacks to OnceCallback to impedance match mojo. (Closed)
Patch Set: Finish Merge Created 3 years, 6 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 // This file contains test infrastructure for multiple files 5 // This file contains test infrastructure for multiple files
6 // (current cookie_monster_unittest.cc and cookie_monster_perftest.cc) 6 // (current cookie_monster_unittest.cc and cookie_monster_perftest.cc)
7 // that need to test out CookieMonster interactions with the backing store. 7 // that need to test out CookieMonster interactions with the backing store.
8 // It should only be included by test code. 8 // It should only be included by test code.
9 9
10 #ifndef NET_COOKIES_COOKIE_MONSTER_STORE_TEST_H_ 10 #ifndef NET_COOKIES_COOKIE_MONSTER_STORE_TEST_H_
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 void LoadCookiesForKey(const std::string& key, 93 void LoadCookiesForKey(const std::string& key,
94 const LoadedCallback& loaded_callback) override; 94 const LoadedCallback& loaded_callback) override;
95 95
96 void AddCookie(const CanonicalCookie& cookie) override; 96 void AddCookie(const CanonicalCookie& cookie) override;
97 97
98 void UpdateCookieAccessTime(const CanonicalCookie& cookie) override; 98 void UpdateCookieAccessTime(const CanonicalCookie& cookie) override;
99 99
100 void DeleteCookie(const CanonicalCookie& cookie) override; 100 void DeleteCookie(const CanonicalCookie& cookie) override;
101 101
102 void Flush(const base::Closure& callback) override; 102 void Flush(base::OnceClosure callback) override;
103 103
104 void SetForceKeepSessionState() override; 104 void SetForceKeepSessionState() override;
105 105
106 protected: 106 protected:
107 ~MockPersistentCookieStore() override; 107 ~MockPersistentCookieStore() override;
108 108
109 private: 109 private:
110 CommandList commands_; 110 CommandList commands_;
111 111
112 bool store_load_commands_; 112 bool store_load_commands_;
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 167
168 void LoadCookiesForKey(const std::string& key, 168 void LoadCookiesForKey(const std::string& key,
169 const LoadedCallback& loaded_callback) override; 169 const LoadedCallback& loaded_callback) override;
170 170
171 void AddCookie(const CanonicalCookie& cookie) override; 171 void AddCookie(const CanonicalCookie& cookie) override;
172 172
173 void UpdateCookieAccessTime(const CanonicalCookie& cookie) override; 173 void UpdateCookieAccessTime(const CanonicalCookie& cookie) override;
174 174
175 void DeleteCookie(const CanonicalCookie& cookie) override; 175 void DeleteCookie(const CanonicalCookie& cookie) override;
176 176
177 void Flush(const base::Closure& callback) override; 177 void Flush(base::OnceClosure callback) override;
178 178
179 void SetForceKeepSessionState() override; 179 void SetForceKeepSessionState() override;
180 180
181 protected: 181 protected:
182 ~MockSimplePersistentCookieStore() override; 182 ~MockSimplePersistentCookieStore() override;
183 183
184 private: 184 private:
185 typedef std::map<int64_t, CanonicalCookie> CanonicalCookieMap; 185 typedef std::map<int64_t, CanonicalCookie> CanonicalCookieMap;
186 186
187 CanonicalCookieMap cookies_; 187 CanonicalCookieMap cookies_;
(...skipping 15 matching lines...) Expand all
203 std::unique_ptr<CookieMonster> CreateMonsterFromStoreForGC( 203 std::unique_ptr<CookieMonster> CreateMonsterFromStoreForGC(
204 int num_secure_cookies, 204 int num_secure_cookies,
205 int num_old_secure_cookies, 205 int num_old_secure_cookies,
206 int num_non_secure_cookies, 206 int num_non_secure_cookies,
207 int num_old_non_secure_cookies, 207 int num_old_non_secure_cookies,
208 int days_old); 208 int days_old);
209 209
210 } // namespace net 210 } // namespace net
211 211
212 #endif // NET_COOKIES_COOKIE_MONSTER_STORE_TEST_H_ 212 #endif // NET_COOKIES_COOKIE_MONSTER_STORE_TEST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698