| Index: content/public/browser/service_worker_context.h
|
| diff --git a/content/public/browser/service_worker_context.h b/content/public/browser/service_worker_context.h
|
| index 594408a44c923a37c38bd37d7a2696b74cdde04c..94ab73f67e2d59d2a68035e03932f6f5b4b50b8c 100644
|
| --- a/content/public/browser/service_worker_context.h
|
| +++ b/content/public/browser/service_worker_context.h
|
| @@ -5,6 +5,9 @@
|
| #ifndef CONTENT_PUBLIC_BROWSER_SERVICE_WORKER_CONTEXT_H_
|
| #define CONTENT_PUBLIC_BROWSER_SERVICE_WORKER_CONTEXT_H_
|
|
|
| +#include <set>
|
| +#include <string>
|
| +
|
| #include "base/basictypes.h"
|
| #include "base/callback_forward.h"
|
| #include "content/public/browser/service_worker_usage_info.h"
|
| @@ -24,6 +27,15 @@ class ServiceWorkerContext {
|
| typedef base::Callback<void(const std::vector<ServiceWorkerUsageInfo>&
|
| usage_info)> GetUsageInfoCallback;
|
|
|
| + // Registers the header name which should not be passed to the ServiceWorker.
|
| + // Must be called from the IO thread.
|
| + CONTENT_EXPORT static void AddExcludedHeadersForFetchEvent(
|
| + const std::set<std::string>& header_names);
|
| +
|
| + // Returns true if the header name should not be passed to the ServiceWorker.
|
| + // Must be called from the IO thread.
|
| + static bool IsExcludedHeaderNameForFetchEvent(const std::string& header_name);
|
| +
|
| // Equivalent to calling navigator.serviceWorker.register(script_url, {scope:
|
| // pattern}) from a renderer, except that |pattern| is an absolute URL instead
|
| // of relative to some current origin. |callback| is passed true when the JS
|
|
|