| OLD | NEW |
| 1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 the V8 project 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 V8_INSPECTOR_V8DEBUGGER_H_ | 5 #ifndef V8_INSPECTOR_V8DEBUGGER_H_ |
| 6 #define V8_INSPECTOR_V8DEBUGGER_H_ | 6 #define V8_INSPECTOR_V8DEBUGGER_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "src/base/macros.h" | 10 #include "src/base/macros.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 JavaScriptCallFrames* newCallFrames, protocol::Maybe<bool>* stackChanged, | 55 JavaScriptCallFrames* newCallFrames, protocol::Maybe<bool>* stackChanged, |
| 56 bool* compileError); | 56 bool* compileError); |
| 57 JavaScriptCallFrames currentCallFrames(int limit = 0); | 57 JavaScriptCallFrames currentCallFrames(int limit = 0); |
| 58 | 58 |
| 59 // Each script inherits debug data from v8::Context where it has been | 59 // Each script inherits debug data from v8::Context where it has been |
| 60 // compiled. | 60 // compiled. |
| 61 // Only scripts whose debug data matches |contextGroupId| will be reported. | 61 // Only scripts whose debug data matches |contextGroupId| will be reported. |
| 62 // Passing 0 will result in reporting all scripts. | 62 // Passing 0 will result in reporting all scripts. |
| 63 void getCompiledScripts(int contextGroupId, | 63 void getCompiledScripts(int contextGroupId, |
| 64 std::vector<std::unique_ptr<V8DebuggerScript>>&); | 64 std::vector<std::unique_ptr<V8DebuggerScript>>&); |
| 65 void reportRequestedModules(); |
| 65 void enable(); | 66 void enable(); |
| 66 void disable(); | 67 void disable(); |
| 67 | 68 |
| 68 bool isPaused(); | 69 bool isPaused(); |
| 69 v8::Local<v8::Context> pausedContext() { return m_pausedContext; } | 70 v8::Local<v8::Context> pausedContext() { return m_pausedContext; } |
| 70 | 71 |
| 71 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } | 72 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } |
| 72 V8StackTraceImpl* currentAsyncCallChain(); | 73 V8StackTraceImpl* currentAsyncCallChain(); |
| 73 void setAsyncCallStackDepth(V8DebuggerAgentImpl*, int); | 74 void setAsyncCallStackDepth(V8DebuggerAgentImpl*, int); |
| 74 std::unique_ptr<V8StackTraceImpl> createStackTrace(v8::Local<v8::StackTrace>); | 75 std::unique_ptr<V8StackTraceImpl> createStackTrace(v8::Local<v8::StackTrace>); |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 void BreakProgramRequested(v8::Local<v8::Context> paused_context, | 145 void BreakProgramRequested(v8::Local<v8::Context> paused_context, |
| 145 v8::Local<v8::Object> exec_state, | 146 v8::Local<v8::Object> exec_state, |
| 146 v8::Local<v8::Value> break_points_hit) override; | 147 v8::Local<v8::Value> break_points_hit) override; |
| 147 void ExceptionThrown(v8::Local<v8::Context> paused_context, | 148 void ExceptionThrown(v8::Local<v8::Context> paused_context, |
| 148 v8::Local<v8::Object> exec_state, | 149 v8::Local<v8::Object> exec_state, |
| 149 v8::Local<v8::Value> exception, | 150 v8::Local<v8::Value> exception, |
| 150 bool is_promise_rejection, bool is_uncaught) override; | 151 bool is_promise_rejection, bool is_uncaught) override; |
| 151 bool IsFunctionBlackboxed(v8::Local<v8::debug::Script> script, | 152 bool IsFunctionBlackboxed(v8::Local<v8::debug::Script> script, |
| 152 const v8::debug::Location& start, | 153 const v8::debug::Location& start, |
| 153 const v8::debug::Location& end) override; | 154 const v8::debug::Location& end) override; |
| 155 void ModuleRequested(v8::Local<v8::debug::Script> referer, |
| 156 v8::Local<v8::debug::Script> requested, |
| 157 v8::Local<v8::String> specifier) override; |
| 154 | 158 |
| 155 v8::Isolate* m_isolate; | 159 v8::Isolate* m_isolate; |
| 156 V8InspectorImpl* m_inspector; | 160 V8InspectorImpl* m_inspector; |
| 157 int m_enableCount; | 161 int m_enableCount; |
| 158 bool m_breakpointsActivated; | 162 bool m_breakpointsActivated; |
| 159 v8::Global<v8::Object> m_debuggerScript; | 163 v8::Global<v8::Object> m_debuggerScript; |
| 160 v8::Global<v8::Context> m_debuggerContext; | 164 v8::Global<v8::Context> m_debuggerContext; |
| 161 v8::Local<v8::Object> m_executionState; | 165 v8::Local<v8::Object> m_executionState; |
| 162 v8::Local<v8::Context> m_pausedContext; | 166 v8::Local<v8::Context> m_pausedContext; |
| 163 bool m_runningNestedMessageLoop; | 167 bool m_runningNestedMessageLoop; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 182 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; | 186 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; |
| 183 | 187 |
| 184 WasmTranslation m_wasmTranslation; | 188 WasmTranslation m_wasmTranslation; |
| 185 | 189 |
| 186 DISALLOW_COPY_AND_ASSIGN(V8Debugger); | 190 DISALLOW_COPY_AND_ASSIGN(V8Debugger); |
| 187 }; | 191 }; |
| 188 | 192 |
| 189 } // namespace v8_inspector | 193 } // namespace v8_inspector |
| 190 | 194 |
| 191 #endif // V8_INSPECTOR_V8DEBUGGER_H_ | 195 #endif // V8_INSPECTOR_V8DEBUGGER_H_ |
| OLD | NEW |