| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8DebuggerAgentImpl_h | 5 #ifndef V8DebuggerAgentImpl_h |
| 6 #define V8DebuggerAgentImpl_h | 6 #define V8DebuggerAgentImpl_h |
| 7 | 7 |
| 8 #include "platform/inspector_protocol/Backend.h" | 8 #include "platform/inspector_protocol/Backend.h" |
| 9 #include "platform/inspector_protocol/Collections.h" | 9 #include "platform/inspector_protocol/Collections.h" |
| 10 #include "platform/inspector_protocol/Frontend.h" | 10 #include "platform/inspector_protocol/Frontend.h" |
| 11 #include "platform/inspector_protocol/String16.h" | 11 #include "platform/inspector_protocol/String16.h" |
| 12 #include "platform/v8_inspector/V8DebuggerImpl.h" | 12 #include "platform/v8_inspector/V8DebuggerImpl.h" |
| 13 | 13 |
| 14 namespace blink { | 14 namespace blink { |
| 15 | 15 |
| 16 class JavaScriptCallFrame; | 16 class JavaScriptCallFrame; |
| 17 class PromiseTracker; | 17 class PromiseTracker; |
| 18 class V8InspectorSessionImpl; | 18 class V8InspectorSessionImpl; |
| 19 class V8Regex; | 19 class V8Regex; |
| 20 class V8StackTraceImpl; | 20 class V8StackTraceImpl; |
| 21 | 21 |
| 22 namespace protocol { | 22 namespace protocol { |
| 23 class DictionaryValue; | 23 class DictionaryValue; |
| 24 } | 24 } |
| 25 | 25 |
| 26 using protocol::Maybe; | 26 using protocol::Maybe; |
| 27 | 27 |
| 28 class V8DebuggerAgentImpl : public protocol::Backend::Debugger { | 28 class V8DebuggerAgentImpl : public protocol::Debugger::Backend { |
| 29 PROTOCOL_DISALLOW_COPY(V8DebuggerAgentImpl); | 29 PROTOCOL_DISALLOW_COPY(V8DebuggerAgentImpl); |
| 30 public: | 30 public: |
| 31 enum SkipPauseRequest { | 31 enum SkipPauseRequest { |
| 32 RequestNoSkip, | 32 RequestNoSkip, |
| 33 RequestContinue, | 33 RequestContinue, |
| 34 RequestStepInto, | 34 RequestStepInto, |
| 35 RequestStepOut, | 35 RequestStepOut, |
| 36 RequestStepFrame | 36 RequestStepFrame |
| 37 }; | 37 }; |
| 38 | 38 |
| 39 enum BreakpointSource { | 39 enum BreakpointSource { |
| 40 UserBreakpointSource, | 40 UserBreakpointSource, |
| 41 DebugCommandBreakpointSource, | 41 DebugCommandBreakpointSource, |
| 42 MonitorCommandBreakpointSource | 42 MonitorCommandBreakpointSource |
| 43 }; | 43 }; |
| 44 | 44 |
| 45 V8DebuggerAgentImpl(V8InspectorSessionImpl*, protocol::Frontend::Debugger*,
protocol::DictionaryValue* state); | 45 V8DebuggerAgentImpl(V8InspectorSessionImpl*, protocol::Debugger::Frontend*,
protocol::DictionaryValue* state); |
| 46 ~V8DebuggerAgentImpl() override; | 46 ~V8DebuggerAgentImpl() override; |
| 47 void restore(); | 47 void restore(); |
| 48 | 48 |
| 49 // Part of the protocol. | 49 // Part of the protocol. |
| 50 void enable(ErrorString*) override; | 50 void enable(ErrorString*) override; |
| 51 void disable(ErrorString*) override; | 51 void disable(ErrorString*) override; |
| 52 void setBreakpointsActive(ErrorString*, bool active) override; | 52 void setBreakpointsActive(ErrorString*, bool active) override; |
| 53 void setSkipAllPauses(ErrorString*, bool skipped) override; | 53 void setSkipAllPauses(ErrorString*, bool skipped) override; |
| 54 void setBreakpointByUrl(ErrorString*, | 54 void setBreakpointByUrl(ErrorString*, |
| 55 int lineNumber, | 55 int lineNumber, |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 200 NoStep = 0, | 200 NoStep = 0, |
| 201 StepInto, | 201 StepInto, |
| 202 StepOver, | 202 StepOver, |
| 203 StepOut | 203 StepOut |
| 204 }; | 204 }; |
| 205 | 205 |
| 206 V8DebuggerImpl* m_debugger; | 206 V8DebuggerImpl* m_debugger; |
| 207 V8InspectorSessionImpl* m_session; | 207 V8InspectorSessionImpl* m_session; |
| 208 bool m_enabled; | 208 bool m_enabled; |
| 209 protocol::DictionaryValue* m_state; | 209 protocol::DictionaryValue* m_state; |
| 210 protocol::Frontend::Debugger* m_frontend; | 210 protocol::Debugger::Frontend* m_frontend; |
| 211 v8::Isolate* m_isolate; | 211 v8::Isolate* m_isolate; |
| 212 v8::Global<v8::Context> m_pausedContext; | 212 v8::Global<v8::Context> m_pausedContext; |
| 213 JavaScriptCallFrames m_pausedCallFrames; | 213 JavaScriptCallFrames m_pausedCallFrames; |
| 214 ScriptsMap m_scripts; | 214 ScriptsMap m_scripts; |
| 215 BreakpointIdToDebuggerBreakpointIdsMap m_breakpointIdToDebuggerBreakpointIds
; | 215 BreakpointIdToDebuggerBreakpointIdsMap m_breakpointIdToDebuggerBreakpointIds
; |
| 216 DebugServerBreakpointToBreakpointIdAndSourceMap m_serverBreakpoints; | 216 DebugServerBreakpointToBreakpointIdAndSourceMap m_serverBreakpoints; |
| 217 String16 m_continueToLocationBreakpointId; | 217 String16 m_continueToLocationBreakpointId; |
| 218 String16 m_breakReason; | 218 String16 m_breakReason; |
| 219 std::unique_ptr<protocol::DictionaryValue> m_breakAuxData; | 219 std::unique_ptr<protocol::DictionaryValue> m_breakAuxData; |
| 220 DebuggerStep m_scheduledDebuggerStep; | 220 DebuggerStep m_scheduledDebuggerStep; |
| (...skipping 16 matching lines...) Expand all Loading... |
| 237 #endif | 237 #endif |
| 238 protocol::Vector<std::unique_ptr<V8StackTraceImpl>> m_currentStacks; | 238 protocol::Vector<std::unique_ptr<V8StackTraceImpl>> m_currentStacks; |
| 239 std::unique_ptr<V8Regex> m_blackboxPattern; | 239 std::unique_ptr<V8Regex> m_blackboxPattern; |
| 240 protocol::HashMap<String16, protocol::Vector<std::pair<int, int>>> m_blackbo
xedPositions; | 240 protocol::HashMap<String16, protocol::Vector<std::pair<int, int>>> m_blackbo
xedPositions; |
| 241 }; | 241 }; |
| 242 | 242 |
| 243 } // namespace blink | 243 } // namespace blink |
| 244 | 244 |
| 245 | 245 |
| 246 #endif // V8DebuggerAgentImpl_h | 246 #endif // V8DebuggerAgentImpl_h |
| OLD | NEW |