| 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/Collections.h" | 8 #include "platform/inspector_protocol/Collections.h" |
| 9 #include "platform/inspector_protocol/Dispatcher.h" | 9 #include "platform/inspector_protocol/Dispatcher.h" |
| 10 #include "platform/inspector_protocol/Frontend.h" | 10 #include "platform/inspector_protocol/Frontend.h" |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 int traceAsyncOperationStarting(const String16& description) override; | 170 int traceAsyncOperationStarting(const String16& description) override; |
| 171 void traceAsyncCallbackStarting(int operationId) override; | 171 void traceAsyncCallbackStarting(int operationId) override; |
| 172 void traceAsyncCallbackCompleted() override; | 172 void traceAsyncCallbackCompleted() override; |
| 173 void traceAsyncOperationCompleted(int operationId) override; | 173 void traceAsyncOperationCompleted(int operationId) override; |
| 174 bool trackingAsyncCalls() const override { return m_maxAsyncCallStackDepth;
} | 174 bool trackingAsyncCalls() const override { return m_maxAsyncCallStackDepth;
} |
| 175 | 175 |
| 176 void didUpdatePromise(const String16& eventType, PassOwnPtr<protocol::Debugg
er::PromiseDetails>); | 176 void didUpdatePromise(const String16& eventType, PassOwnPtr<protocol::Debugg
er::PromiseDetails>); |
| 177 void reset(); | 177 void reset(); |
| 178 | 178 |
| 179 // Interface for V8DebuggerImpl | 179 // Interface for V8DebuggerImpl |
| 180 SkipPauseRequest didPause(v8::Local<v8::Context>, v8::Local<v8::Object> call
Frames, v8::Local<v8::Value> exception, const protocol::Vector<String16>& hitBre
akpoints, bool isPromiseRejection); | 180 SkipPauseRequest didPause(v8::Local<v8::Context>, PassOwnPtr<JavaScriptCallF
rame> callFrames, v8::Local<v8::Value> exception, const protocol::Vector<String1
6>& hitBreakpoints, bool isPromiseRejection); |
| 181 void didContinue(); | 181 void didContinue(); |
| 182 void didParseSource(const V8DebuggerParsedScript&); | 182 void didParseSource(const V8DebuggerParsedScript&); |
| 183 bool v8AsyncTaskEventsEnabled() const; | 183 bool v8AsyncTaskEventsEnabled() const; |
| 184 void didReceiveV8AsyncTaskEvent(v8::Local<v8::Context>, const String16& even
tType, const String16& eventName, int id); | 184 void didReceiveV8AsyncTaskEvent(v8::Local<v8::Context>, const String16& even
tType, const String16& eventName, int id); |
| 185 bool v8PromiseEventsEnabled() const; | 185 bool v8PromiseEventsEnabled() const; |
| 186 void didReceiveV8PromiseEvent(v8::Local<v8::Context>, v8::Local<v8::Object>
promise, v8::Local<v8::Value> parentPromise, int status); | 186 void didReceiveV8PromiseEvent(v8::Local<v8::Context>, v8::Local<v8::Object>
promise, v8::Local<v8::Value> parentPromise, int status); |
| 187 | 187 |
| 188 v8::Isolate* isolate() { return m_isolate; } | 188 v8::Isolate* isolate() { return m_isolate; } |
| 189 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } | 189 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } |
| 190 V8StackTraceImpl* currentAsyncCallChain(); | 190 V8StackTraceImpl* currentAsyncCallChain(); |
| 191 | 191 |
| 192 private: | 192 private: |
| 193 bool checkEnabled(ErrorString*); | 193 bool checkEnabled(ErrorString*); |
| 194 void enable(); | 194 void enable(); |
| 195 | 195 |
| 196 SkipPauseRequest shouldSkipExceptionPause(); | 196 SkipPauseRequest shouldSkipExceptionPause(); |
| 197 SkipPauseRequest shouldSkipStepPause(); | 197 SkipPauseRequest shouldSkipStepPause(); |
| 198 | 198 |
| 199 void schedulePauseOnNextStatementIfSteppingInto(); | 199 void schedulePauseOnNextStatementIfSteppingInto(); |
| 200 | 200 |
| 201 PassOwnPtr<protocol::Array<protocol::Debugger::CallFrame>> currentCallFrames
(); | 201 PassOwnPtr<protocol::Array<protocol::Debugger::CallFrame>> currentCallFrames
(ErrorString*); |
| 202 PassOwnPtr<protocol::Runtime::StackTrace> currentAsyncStackTrace(); | 202 PassOwnPtr<protocol::Runtime::StackTrace> currentAsyncStackTrace(); |
| 203 | 203 |
| 204 void clearCurrentAsyncOperation(); | 204 void clearCurrentAsyncOperation(); |
| 205 void resetAsyncCallTracker(); | 205 void resetAsyncCallTracker(); |
| 206 | 206 |
| 207 void changeJavaScriptRecursionLevel(int step); | 207 void changeJavaScriptRecursionLevel(int step); |
| 208 | 208 |
| 209 void setPauseOnExceptionsImpl(ErrorString*, int); | 209 void setPauseOnExceptionsImpl(ErrorString*, int); |
| 210 | 210 |
| 211 PassOwnPtr<protocol::Debugger::Location> resolveBreakpoint(const String16& b
reakpointId, const String16& scriptId, const ScriptBreakpoint&, BreakpointSource
); | 211 PassOwnPtr<protocol::Debugger::Location> resolveBreakpoint(const String16& b
reakpointId, const String16& scriptId, const ScriptBreakpoint&, BreakpointSource
); |
| (...skipping 22 matching lines...) Expand all Loading... |
| 234 }; | 234 }; |
| 235 | 235 |
| 236 InjectedScriptManager* m_injectedScriptManager; | 236 InjectedScriptManager* m_injectedScriptManager; |
| 237 V8DebuggerImpl* m_debugger; | 237 V8DebuggerImpl* m_debugger; |
| 238 int m_contextGroupId; | 238 int m_contextGroupId; |
| 239 bool m_enabled; | 239 bool m_enabled; |
| 240 protocol::DictionaryValue* m_state; | 240 protocol::DictionaryValue* m_state; |
| 241 protocol::Frontend::Debugger* m_frontend; | 241 protocol::Frontend::Debugger* m_frontend; |
| 242 v8::Isolate* m_isolate; | 242 v8::Isolate* m_isolate; |
| 243 v8::Global<v8::Context> m_pausedContext; | 243 v8::Global<v8::Context> m_pausedContext; |
| 244 v8::Global<v8::Object> m_currentCallStack; | 244 OwnPtr<JavaScriptCallFrame> m_currentCallStack; |
| 245 ScriptsMap m_scripts; | 245 ScriptsMap m_scripts; |
| 246 BreakpointIdToDebuggerBreakpointIdsMap m_breakpointIdToDebuggerBreakpointIds
; | 246 BreakpointIdToDebuggerBreakpointIdsMap m_breakpointIdToDebuggerBreakpointIds
; |
| 247 DebugServerBreakpointToBreakpointIdAndSourceMap m_serverBreakpoints; | 247 DebugServerBreakpointToBreakpointIdAndSourceMap m_serverBreakpoints; |
| 248 String16 m_continueToLocationBreakpointId; | 248 String16 m_continueToLocationBreakpointId; |
| 249 String16 m_breakReason; | 249 String16 m_breakReason; |
| 250 OwnPtr<protocol::DictionaryValue> m_breakAuxData; | 250 OwnPtr<protocol::DictionaryValue> m_breakAuxData; |
| 251 DebuggerStep m_scheduledDebuggerStep; | 251 DebuggerStep m_scheduledDebuggerStep; |
| 252 bool m_skipNextDebuggerStepOut; | 252 bool m_skipNextDebuggerStepOut; |
| 253 bool m_javaScriptPauseScheduled; | 253 bool m_javaScriptPauseScheduled; |
| 254 bool m_steppingFromFramework; | 254 bool m_steppingFromFramework; |
| (...skipping 21 matching lines...) Expand all Loading... |
| 276 int m_currentAsyncOperationId; | 276 int m_currentAsyncOperationId; |
| 277 bool m_pendingTraceAsyncOperationCompleted; | 277 bool m_pendingTraceAsyncOperationCompleted; |
| 278 bool m_startingStepIntoAsync; | 278 bool m_startingStepIntoAsync; |
| 279 protocol::HashMap<String16, protocol::Vector<std::pair<int, int>>> m_blackbo
xedPositions; | 279 protocol::HashMap<String16, protocol::Vector<std::pair<int, int>>> m_blackbo
xedPositions; |
| 280 }; | 280 }; |
| 281 | 281 |
| 282 } // namespace blink | 282 } // namespace blink |
| 283 | 283 |
| 284 | 284 |
| 285 #endif // V8DebuggerAgentImpl_h | 285 #endif // V8DebuggerAgentImpl_h |
| OLD | NEW |