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

Side by Side Diff: content/browser/service_worker/service_worker_database.h

Issue 2873683002: PaymentHandler: Implement GetAllPaymentApps(). (Closed)
Patch Set: installed -> stored in public Created 3 years, 7 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 // database. 217 // database.
218 Status DeleteUserData(int64_t registration_id, 218 Status DeleteUserData(int64_t registration_id,
219 const std::vector<std::string>& user_data_names); 219 const std::vector<std::string>& user_data_names);
220 220
221 // Reads user data for all registrations that have data with |user_data_name| 221 // Reads user data for all registrations that have data with |user_data_name|
222 // from the database. Returns OK if they are successfully read or not found. 222 // from the database. Returns OK if they are successfully read or not found.
223 Status ReadUserDataForAllRegistrations( 223 Status ReadUserDataForAllRegistrations(
224 const std::string& user_data_name, 224 const std::string& user_data_name,
225 std::vector<std::pair<int64_t, std::string>>* user_data); 225 std::vector<std::pair<int64_t, std::string>>* user_data);
226 226
227 // Reads user data for all registrations that have data with |user_data_name|
228 // from the database. Returns OK if they are successfully read or not found.
229 Status ReadUserDataForAllRegistrationsByKeyPrefix(
230 const std::string& user_data_name_prefix,
231 std::vector<std::pair<int64_t, std::string>>* user_data);
232
227 // Resources should belong to one of following resource lists: uncommitted, 233 // Resources should belong to one of following resource lists: uncommitted,
228 // committed and purgeable. 234 // committed and purgeable.
229 // As new resources are put into the diskcache, they go into the uncommitted 235 // As new resources are put into the diskcache, they go into the uncommitted
230 // list. When a registration is saved that refers to those ids, they're moved 236 // list. When a registration is saved that refers to those ids, they're moved
231 // to the committed list. When a resource no longer has any registrations or 237 // to the committed list. When a resource no longer has any registrations or
232 // caches referring to it, it's added to the purgeable list. Periodically, 238 // caches referring to it, it's added to the purgeable list. Periodically,
233 // the purgeable list can be purged from the diskcache. At system startup, all 239 // the purgeable list can be purged from the diskcache. At system startup, all
234 // uncommitted ids are moved to the purgeable list. 240 // uncommitted ids are moved to the purgeable list.
235 241
236 // Reads resource ids from the uncommitted list. Returns OK on success. 242 // Reads resource ids from the uncommitted list. Returns OK on success.
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 FRIEND_TEST_ALL_PREFIXES(ServiceWorkerDatabaseTest, 414 FRIEND_TEST_ALL_PREFIXES(ServiceWorkerDatabaseTest,
409 UserData_UninitializedDatabase); 415 UserData_UninitializedDatabase);
410 FRIEND_TEST_ALL_PREFIXES(ServiceWorkerDatabaseTest, DestroyDatabase); 416 FRIEND_TEST_ALL_PREFIXES(ServiceWorkerDatabaseTest, DestroyDatabase);
411 417
412 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDatabase); 418 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDatabase);
413 }; 419 };
414 420
415 } // namespace content 421 } // namespace content
416 422
417 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_ 423 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DATABASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698