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 "bindings/core/v8/SerializedScriptValue.h" | 36 #include "bindings/core/v8/SerializedScriptValue.h" |
37 #include "core/workers/AbstractWorker.h" | 37 #include "core/workers/AbstractWorker.h" |
38 #include "modules/ModulesExport.h" | 38 #include "modules/ModulesExport.h" |
39 #include "public/platform/modules/serviceworker/WebServiceWorker.h" | 39 #include "public/platform/modules/serviceworker/WebServiceWorker.h" |
40 #include "public/platform/modules/serviceworker/WebServiceWorkerProxy.h" | 40 #include "public/platform/modules/serviceworker/WebServiceWorkerProxy.h" |
41 #include "wtf/PassRefPtr.h" | 41 #include "wtf/PassRefPtr.h" |
42 #include <memory> | 42 #include <memory> |
43 | 43 |
44 namespace blink { | 44 namespace blink { |
45 | 45 |
46 class MODULES_EXPORT ServiceWorker final : public AbstractWorker, | 46 class MODULES_EXPORT ServiceWorker final |
47 public ActiveScriptWrappable, | 47 : public AbstractWorker, |
48 public WebServiceWorkerProxy { | 48 public ActiveScriptWrappable<ServiceWorker>, |
| 49 public WebServiceWorkerProxy { |
49 DEFINE_WRAPPERTYPEINFO(); | 50 DEFINE_WRAPPERTYPEINFO(); |
50 USING_GARBAGE_COLLECTED_MIXIN(ServiceWorker); | 51 USING_GARBAGE_COLLECTED_MIXIN(ServiceWorker); |
51 | 52 |
52 public: | 53 public: |
53 static ServiceWorker* from(ExecutionContext*, | 54 static ServiceWorker* from(ExecutionContext*, |
54 std::unique_ptr<WebServiceWorker::Handle>); | 55 std::unique_ptr<WebServiceWorker::Handle>); |
55 | 56 |
56 ~ServiceWorker() override; | 57 ~ServiceWorker() override; |
57 DECLARE_VIRTUAL_TRACE(); | 58 DECLARE_VIRTUAL_TRACE(); |
58 | 59 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 void contextDestroyed() override; | 92 void contextDestroyed() override; |
92 | 93 |
93 // A handle to the service worker representation in the embedder. | 94 // A handle to the service worker representation in the embedder. |
94 std::unique_ptr<WebServiceWorker::Handle> m_handle; | 95 std::unique_ptr<WebServiceWorker::Handle> m_handle; |
95 bool m_wasStopped; | 96 bool m_wasStopped; |
96 }; | 97 }; |
97 | 98 |
98 } // namespace blink | 99 } // namespace blink |
99 | 100 |
100 #endif // ServiceWorker_h | 101 #endif // ServiceWorker_h |
OLD | NEW |