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

Side by Side Diff: content/common/background_sync_service.mojom

Issue 1282013004: BackgroundSyncManager tracks client registrations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Clean up Created 5 years, 4 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 module content; 5 module content;
6 6
7 import "content/public/common/background_sync.mojom"; 7 import "content/public/common/background_sync.mojom";
8 import "content/public/common/permission_status.mojom"; 8 import "content/public/common/permission_status.mojom";
9 import "content/public/common/service_worker_event_status.mojom"; 9 import "content/public/common/service_worker_event_status.mojom";
10 10
11 enum BackgroundSyncError { 11 enum BackgroundSyncError {
12 NONE, 12 NONE,
13 STORAGE, 13 STORAGE,
14 NOT_FOUND, 14 NOT_FOUND,
15 NO_SERVICE_WORKER, 15 NO_SERVICE_WORKER,
16 NOT_ALLOWED, 16 NOT_ALLOWED,
17 MAX=NOT_ALLOWED 17 MAX=NOT_ALLOWED
18 }; 18 };
19 19
20 interface BackgroundSyncService { 20 interface BackgroundSyncService {
21 Register(SyncRegistration options, int64 service_worker_registration_id) 21 Register(SyncRegistration options, int64 service_worker_registration_id)
22 => (BackgroundSyncError err, SyncRegistration options); 22 => (BackgroundSyncError err, SyncRegistration options);
23 GetRegistration(BackgroundSyncPeriodicity periodicity, string tag, 23 GetRegistration(BackgroundSyncPeriodicity periodicity, string tag,
24 int64 service_worker_registration_id) 24 int64 service_worker_registration_id)
25 => (BackgroundSyncError err, SyncRegistration? registration); 25 => (BackgroundSyncError err, SyncRegistration? registration);
26 GetRegistrations(BackgroundSyncPeriodicity periodicity, 26 GetRegistrations(BackgroundSyncPeriodicity periodicity,
27 int64 service_worker_registration_id) 27 int64 service_worker_registration_id)
28 => (BackgroundSyncError err, array<SyncRegistration> registrations); 28 => (BackgroundSyncError err, array<SyncRegistration> registrations);
29 Unregister(BackgroundSyncPeriodicity periodicity, int64 id, string tag, 29 Unregister(BackgroundSyncPeriodicity periodicity, int64 id,
30 int64 service_worker_registration_id) => (BackgroundSyncError err); 30 int64 service_worker_registration_id) => (BackgroundSyncError err);
31 GetPermissionStatus(BackgroundSyncPeriodicity periodicity, 31 GetPermissionStatus(BackgroundSyncPeriodicity periodicity,
32 int64 service_worker_registration_id) 32 int64 service_worker_registration_id)
33 => (BackgroundSyncError err, PermissionStatus status); 33 => (BackgroundSyncError err, PermissionStatus status);
34 TrackRegistration(SyncRegistration registration);
35 ReleaseRegistration(int64 sync_id);
34 }; 36 };
35 37
36 interface BackgroundSyncServiceClient { 38 interface BackgroundSyncServiceClient {
37 Sync(SyncRegistration registration) 39 Sync(SyncRegistration registration)
38 => (ServiceWorkerEventStatus status); 40 => (ServiceWorkerEventStatus status);
39 }; 41 };
40 42
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698