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

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

Issue 2968123002: Introduce ServiceWorkerRegistrationOptions struct for service worker options (Closed)
Patch Set: address more comments Created 3 years, 5 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_REGISTER_JOB_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_REGISTER_JOB_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_REGISTER_JOB_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_REGISTER_JOB_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 30 matching lines...) Expand all
41 public EmbeddedWorkerInstance::Listener { 41 public EmbeddedWorkerInstance::Listener {
42 public: 42 public:
43 typedef base::Callback<void(ServiceWorkerStatusCode status, 43 typedef base::Callback<void(ServiceWorkerStatusCode status,
44 const std::string& status_message, 44 const std::string& status_message,
45 ServiceWorkerRegistration* registration)> 45 ServiceWorkerRegistration* registration)>
46 RegistrationCallback; 46 RegistrationCallback;
47 47
48 // For registration jobs. 48 // For registration jobs.
49 CONTENT_EXPORT ServiceWorkerRegisterJob( 49 CONTENT_EXPORT ServiceWorkerRegisterJob(
50 base::WeakPtr<ServiceWorkerContextCore> context, 50 base::WeakPtr<ServiceWorkerContextCore> context,
51 const GURL& pattern, 51 const GURL& script_url,
52 const GURL& script_url); 52 const ServiceWorkerRegistrationOptions& options);
53 53
54 // For update jobs. 54 // For update jobs.
55 CONTENT_EXPORT ServiceWorkerRegisterJob( 55 CONTENT_EXPORT ServiceWorkerRegisterJob(
56 base::WeakPtr<ServiceWorkerContextCore> context, 56 base::WeakPtr<ServiceWorkerContextCore> context,
57 ServiceWorkerRegistration* registration, 57 ServiceWorkerRegistration* registration,
58 bool force_bypass_cache, 58 bool force_bypass_cache,
59 bool skip_script_comparison); 59 bool skip_script_comparison);
60 ~ServiceWorkerRegisterJob() override; 60 ~ServiceWorkerRegisterJob() override;
61 61
62 // Registers a callback to be called when the promise would resolve (whether 62 // Registers a callback to be called when the promise would resolve (whether
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 std::string promise_resolved_status_message_; 166 std::string promise_resolved_status_message_;
167 scoped_refptr<ServiceWorkerRegistration> promise_resolved_registration_; 167 scoped_refptr<ServiceWorkerRegistration> promise_resolved_registration_;
168 base::WeakPtrFactory<ServiceWorkerRegisterJob> weak_factory_; 168 base::WeakPtrFactory<ServiceWorkerRegisterJob> weak_factory_;
169 169
170 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerRegisterJob); 170 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerRegisterJob);
171 }; 171 };
172 172
173 } // namespace content 173 } // namespace content
174 174
175 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_REGISTER_JOB_H_ 175 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_REGISTER_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698