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

Side by Side Diff: content/renderer/service_worker/worker_fetch_context_info_impl.h

Issue 2701753003: [WIP] off-main-thread loading
Patch Set: small fix Created 3 years, 8 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
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_RENDERER_SERVICE_WORKER_WORKER_FETCH_CONTEXT_INFO_IMPL_H_
6 #define CONTENT_RENDERER_SERVICE_WORKER_WORKER_FETCH_CONTEXT_INFO_IMPL_H_
7
8 #include "content/child/thread_safe_sender.h"
9 #include "content/common/service_worker/service_worker_types.h"
10 #include "content/common/worker_fetch_context_factory.mojom.h"
11 #include "ipc/ipc_message.h"
12 #include "third_party/WebKit/public/platform/WebWorkerFetchContext.h"
13
14 namespace content {
15
16 class WorkerFetchContextInfoImpl : public blink::WebWorkerFetchContextInfo {
17 public:
18 WorkerFetchContextInfoImpl(
19 mojom::WorkerFetchContextFactoryPtrInfo factory_info);
20 ~WorkerFetchContextInfoImpl() override;
21
22 std::unique_ptr<blink::WebWorkerFetchContext> CreateContext(
23 base::SingleThreadTaskRunner* loading_task_runner) override;
24 void setAppCacheHostID(int appcache_host_id) override;
25 void setParentFrameID(int parent_frame_id) override;
26 void setServiceWorkerProviderID(int service_worker_provider_id) override;
27 void setIsSecureContext(bool is_secure_context) override;
28 void setIsControlledByServiceWorker(bool contolled) override;
29 void willSendRequest(blink::WebURLRequest&) override;
30
31 private:
32 mojom::WorkerFetchContextFactoryPtrInfo factory_info_;
33 int service_worker_provider_id_ = kInvalidServiceWorkerProviderId;
34 int appcache_host_id_ = 0;
35 int parent_frame_id_ = MSG_ROUTING_NONE;
36 bool is_secure_context_ = false;
37 bool is_controlled_by_service_worker_ = false;
38 scoped_refptr<ThreadSafeSender> thread_safe_sender_;
39 };
40
41 } // namespace content
42
43 #endif // CONTENT_RENDERER_SERVICE_WORKER_WORKER_FETCH_CONTEXT_INFO_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698