Chromium Code Reviews| OLD | NEW |
|---|---|
| (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. | |
|
hiroshige
2017/02/22 01:21:31
Duplicated in [1]. Shall we rebase [1] onto this C
kouhei (in TOK)
2017/02/22 07:08:04
Actually this CL implements other parts of Modulat
| |
| 4 | |
| 5 #ifndef DummyModulator_h | |
| 6 #define DummyModulator_h | |
| 7 | |
| 8 #include "core/CoreExport.h" | |
| 9 #include "core/dom/Modulator.h" | |
| 10 #include "platform/heap/Handle.h" | |
| 11 | |
| 12 namespace blink { | |
| 13 | |
| 14 class ModuleScriptLoaderClient; | |
| 15 class ScriptModuleResolver; | |
| 16 class WebTaskRunner; | |
| 17 class ModuleScriptFetchRequest; | |
| 18 | |
| 19 // DummyModulator provides empty Modulator interface implementation w/ | |
| 20 // NOTREACHED(). | |
| 21 // | |
| 22 // DummyModulator is useful for unit-testing. | |
| 23 // Not all module implementation components require full-blown Modulator | |
| 24 // implementation. Unit tests can implement a subset of Modulator interface | |
| 25 // which is exercised from unit-under-test. | |
| 26 class CORE_EXPORT DummyModulator | |
| 27 : public GarbageCollectedFinalized<DummyModulator>, | |
| 28 public Modulator { | |
| 29 USING_GARBAGE_COLLECTED_MIXIN(DummyModulator); | |
| 30 | |
| 31 public: | |
| 32 DummyModulator() = default; | |
| 33 virtual ~DummyModulator() {} | |
|
kouhei (in TOK)
2017/02/21 06:50:58
Probably I need to uninline these to make cl.exe h
| |
| 34 DEFINE_INLINE_TRACE() {} | |
| 35 | |
| 36 ScriptModuleResolver* scriptModuleResolver() override { | |
| 37 NOTREACHED(); | |
| 38 return nullptr; | |
| 39 } | |
| 40 | |
| 41 WebTaskRunner* taskRunner() override { | |
| 42 NOTREACHED(); | |
| 43 return nullptr; | |
| 44 }; | |
| 45 | |
| 46 void fetchNewSingleModule(const ModuleScriptFetchRequest&, | |
| 47 ModuleGraphLevel, | |
| 48 ModuleScriptLoaderClient*) override { | |
| 49 NOTREACHED(); | |
| 50 } | |
| 51 }; | |
| 52 | |
| 53 } // namespace blink | |
| 54 | |
| 55 #endif | |
| OLD | NEW |