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

Side by Side Diff: Source/core/inspector/WorkerInspectorController.h

Issue 1133903005: DevTools: [wip] do not use InspectorInstrumentation for will/didProcessTask events. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 7 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
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 15 matching lines...) Expand all
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #ifndef WorkerInspectorController_h 31 #ifndef WorkerInspectorController_h
32 #define WorkerInspectorController_h 32 #define WorkerInspectorController_h
33 33
34 #include "core/inspector/InspectorBaseAgent.h" 34 #include "core/inspector/InspectorBaseAgent.h"
35 #include "core/inspector/InspectorRuntimeAgent.h" 35 #include "core/inspector/InspectorRuntimeAgent.h"
36 #include "public/platform/WebThread.h"
36 #include "wtf/FastAllocBase.h" 37 #include "wtf/FastAllocBase.h"
37 #include "wtf/Forward.h" 38 #include "wtf/Forward.h"
38 #include "wtf/Noncopyable.h" 39 #include "wtf/Noncopyable.h"
39 #include "wtf/OwnPtr.h" 40 #include "wtf/OwnPtr.h"
40 #include "wtf/RefPtr.h" 41 #include "wtf/RefPtr.h"
41 42
42 namespace blink { 43 namespace blink {
43 44
44 class AsyncCallTracker; 45 class AsyncCallTracker;
45 class InjectedScriptManager; 46 class InjectedScriptManager;
46 class InspectorBackendDispatcher; 47 class InspectorBackendDispatcher;
47 class InspectorFrontend; 48 class InspectorFrontend;
48 class InspectorFrontendChannel; 49 class InspectorFrontendChannel;
50 class InspectorProfilerAgent;
49 class InspectorStateClient; 51 class InspectorStateClient;
50 class InstrumentingAgents; 52 class InstrumentingAgents;
51 class WorkerDebuggerAgent; 53 class WorkerDebuggerAgent;
52 class WorkerGlobalScope; 54 class WorkerGlobalScope;
53 class WorkerRuntimeAgent; 55 class WorkerRuntimeAgent;
54 class WorkerScriptDebugServer; 56 class WorkerScriptDebugServer;
55 57
56 class WorkerInspectorController : public RefCountedWillBeGarbageCollectedFinaliz ed<WorkerInspectorController>, public InspectorRuntimeAgent::Client { 58 class WorkerInspectorController : public RefCountedWillBeGarbageCollectedFinaliz ed<WorkerInspectorController>, public InspectorRuntimeAgent::Client, public WebT hread::TaskObserver {
57 WTF_MAKE_NONCOPYABLE(WorkerInspectorController); 59 WTF_MAKE_NONCOPYABLE(WorkerInspectorController);
58 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED(WorkerInspectorController); 60 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED(WorkerInspectorController);
59 public: 61 public:
60 explicit WorkerInspectorController(WorkerGlobalScope*); 62 explicit WorkerInspectorController(WorkerGlobalScope*);
61 ~WorkerInspectorController(); 63 ~WorkerInspectorController();
62 DECLARE_TRACE(); 64 DECLARE_TRACE();
63 65
64 void registerModuleAgent(PassOwnPtrWillBeRawPtr<InspectorAgent>); 66 void registerModuleAgent(PassOwnPtrWillBeRawPtr<InspectorAgent>);
65 void connectFrontend(); 67 void connectFrontend();
66 void disconnectFrontend(); 68 void disconnectFrontend();
67 void restoreInspectorStateFromCookie(const String& inspectorCookie); 69 void restoreInspectorStateFromCookie(const String& inspectorCookie);
68 void dispatchMessageFromFrontend(const String&); 70 void dispatchMessageFromFrontend(const String&);
69 void dispose(); 71 void dispose();
70 void interruptAndDispatchInspectorCommands(); 72 void interruptAndDispatchInspectorCommands();
71 73
72 void pauseOnStart(); 74 void pauseOnStart();
73 75
74 private: 76 private:
75 friend InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobal Scope*); 77 friend InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobal Scope*);
76 78
77 // InspectorRuntimeAgent::Client implementation. 79 // InspectorRuntimeAgent::Client implementation.
78 void resumeStartup() override; 80 void resumeStartup() override;
79 bool isRunRequired() override; 81 bool isRunRequired() override;
80 82
83 void willProcessTask() override;
84 void didProcessTask() override;
85
81 RawPtrWillBeMember<WorkerGlobalScope> m_workerGlobalScope; 86 RawPtrWillBeMember<WorkerGlobalScope> m_workerGlobalScope;
82 OwnPtr<InspectorStateClient> m_stateClient; 87 OwnPtr<InspectorStateClient> m_stateClient;
83 OwnPtrWillBeMember<InspectorCompositeState> m_state; 88 OwnPtrWillBeMember<InspectorCompositeState> m_state;
84 RefPtrWillBeMember<InstrumentingAgents> m_instrumentingAgents; 89 RefPtrWillBeMember<InstrumentingAgents> m_instrumentingAgents;
85 OwnPtrWillBeMember<InjectedScriptManager> m_injectedScriptManager; 90 OwnPtrWillBeMember<InjectedScriptManager> m_injectedScriptManager;
86 OwnPtrWillBeMember<WorkerScriptDebugServer> m_debugServer; 91 OwnPtrWillBeMember<WorkerScriptDebugServer> m_debugServer;
87 InspectorAgentRegistry m_agents; 92 InspectorAgentRegistry m_agents;
88 OwnPtr<InspectorFrontendChannel> m_frontendChannel; 93 OwnPtr<InspectorFrontendChannel> m_frontendChannel;
89 OwnPtr<InspectorFrontend> m_frontend; 94 OwnPtr<InspectorFrontend> m_frontend;
90 RefPtrWillBeMember<InspectorBackendDispatcher> m_backendDispatcher; 95 RefPtrWillBeMember<InspectorBackendDispatcher> m_backendDispatcher;
91 RawPtrWillBeMember<WorkerDebuggerAgent> m_workerDebuggerAgent; 96 RawPtrWillBeMember<WorkerDebuggerAgent> m_workerDebuggerAgent;
92 OwnPtrWillBeMember<AsyncCallTracker> m_asyncCallTracker; 97 OwnPtrWillBeMember<AsyncCallTracker> m_asyncCallTracker;
98 RawPtrWillBeMember<InspectorProfilerAgent> m_profilerAgent;
93 RawPtrWillBeMember<WorkerRuntimeAgent> m_workerRuntimeAgent; 99 RawPtrWillBeMember<WorkerRuntimeAgent> m_workerRuntimeAgent;
94 bool m_paused; 100 bool m_paused;
95 }; 101 };
96 102
97 } 103 }
98 104
99 #endif // WorkerInspectorController_h 105 #endif // WorkerInspectorController_h
OLDNEW
« no previous file with comments | « Source/core/inspector/WorkerDebuggerAgent.cpp ('k') | Source/core/inspector/WorkerInspectorController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698