OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 25 matching lines...) Expand all Loading... |
36 #include <memory> | 36 #include <memory> |
37 | 37 |
38 namespace blink { | 38 namespace blink { |
39 | 39 |
40 class WorkerThreadStartupData; | 40 class WorkerThreadStartupData; |
41 | 41 |
42 class MODULES_EXPORT ServiceWorkerThread final : public WorkerThread { | 42 class MODULES_EXPORT ServiceWorkerThread final : public WorkerThread { |
43 public: | 43 public: |
44 static std::unique_ptr<ServiceWorkerThread> create( | 44 static std::unique_ptr<ServiceWorkerThread> create( |
45 PassRefPtr<WorkerLoaderProxy>, | 45 PassRefPtr<WorkerLoaderProxy>, |
46 WorkerReportingProxy&, | 46 WorkerReportingProxy&); |
47 ParentFrameTaskRunners*); | |
48 ~ServiceWorkerThread() override; | 47 ~ServiceWorkerThread() override; |
49 | 48 |
50 WorkerBackingThread& workerBackingThread() override { | 49 WorkerBackingThread& workerBackingThread() override { |
51 return *m_workerBackingThread; | 50 return *m_workerBackingThread; |
52 } | 51 } |
53 void clearWorkerBackingThread() override; | 52 void clearWorkerBackingThread() override; |
54 | 53 |
55 protected: | 54 protected: |
56 WorkerOrWorkletGlobalScope* createWorkerGlobalScope( | 55 WorkerOrWorkletGlobalScope* createWorkerGlobalScope( |
57 std::unique_ptr<WorkerThreadStartupData>) override; | 56 std::unique_ptr<WorkerThreadStartupData>) override; |
58 | 57 |
59 private: | 58 private: |
60 ServiceWorkerThread(PassRefPtr<WorkerLoaderProxy>, | 59 ServiceWorkerThread(PassRefPtr<WorkerLoaderProxy>, WorkerReportingProxy&); |
61 WorkerReportingProxy&, | |
62 ParentFrameTaskRunners*); | |
63 std::unique_ptr<WorkerBackingThread> m_workerBackingThread; | 60 std::unique_ptr<WorkerBackingThread> m_workerBackingThread; |
64 }; | 61 }; |
65 | 62 |
66 } // namespace blink | 63 } // namespace blink |
67 | 64 |
68 #endif // ServiceWorkerThread_h | 65 #endif // ServiceWorkerThread_h |
OLD | NEW |