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

Side by Side Diff: Source/bindings/v8/ScriptDebugServer.h

Issue 290633009: DevTools: Show detailed information for exceptions during snippet execution. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 6 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) 2010, Google Inc. All rights reserved. 2 * Copyright (c) 2010, 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 16 matching lines...) Expand all
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 ScriptDebugServer_h 31 #ifndef ScriptDebugServer_h
32 #define ScriptDebugServer_h 32 #define ScriptDebugServer_h
33 33
34 #include "InspectorBackendDispatcher.h" 34 #include "InspectorBackendDispatcher.h"
35 #include "bindings/v8/ScopedPersistent.h" 35 #include "bindings/v8/ScopedPersistent.h"
36 #include "core/inspector/ScriptBreakpoint.h" 36 #include "core/inspector/ScriptBreakpoint.h"
37 #include "core/inspector/ScriptCallStack.h"
37 #include "core/inspector/ScriptDebugListener.h" 38 #include "core/inspector/ScriptDebugListener.h"
38 #include "wtf/HashMap.h" 39 #include "wtf/HashMap.h"
39 #include "wtf/Noncopyable.h" 40 #include "wtf/Noncopyable.h"
40 #include "wtf/PassOwnPtr.h" 41 #include "wtf/PassOwnPtr.h"
41 #include "wtf/Vector.h" 42 #include "wtf/Vector.h"
42 #include "wtf/text/StringHash.h" 43 #include "wtf/text/StringHash.h"
43 #include "wtf/text/WTFString.h" 44 #include "wtf/text/WTFString.h"
44 #include <v8-debug.h> 45 #include <v8-debug.h>
45 #include <v8.h> 46 #include <v8.h>
46 47
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 void runPendingTasks(); 93 void runPendingTasks();
93 94
94 bool isPaused(); 95 bool isPaused();
95 bool runningNestedMessageLoop() { return m_runningNestedMessageLoop; } 96 bool runningNestedMessageLoop() { return m_runningNestedMessageLoop; }
96 97
97 v8::Local<v8::Value> functionScopes(v8::Handle<v8::Function>); 98 v8::Local<v8::Value> functionScopes(v8::Handle<v8::Function>);
98 v8::Local<v8::Value> getInternalProperties(v8::Handle<v8::Object>&); 99 v8::Local<v8::Value> getInternalProperties(v8::Handle<v8::Object>&);
99 v8::Handle<v8::Value> setFunctionVariableValue(v8::Handle<v8::Value> functio nValue, int scopeNumber, const String& variableName, v8::Handle<v8::Value> newVa lue); 100 v8::Handle<v8::Value> setFunctionVariableValue(v8::Handle<v8::Value> functio nValue, int scopeNumber, const String& variableName, v8::Handle<v8::Value> newVa lue);
100 v8::Local<v8::Value> callDebuggerMethod(const char* functionName, int argc, v8::Handle<v8::Value> argv[]); 101 v8::Local<v8::Value> callDebuggerMethod(const char* functionName, int argc, v8::Handle<v8::Value> argv[]);
101 102
102 virtual void compileScript(ScriptState*, const String& expression, const Str ing& sourceURL, String* scriptId, String* exceptionMessage); 103 virtual void compileScript(ScriptState*, const String& expression, const Str ing& sourceURL, String* scriptId, String* exceptionDetailsText, int* lineNumber, int* columnNumber, RefPtr<ScriptCallStack>* stackTrace);
103 virtual void clearCompiledScripts(); 104 virtual void clearCompiledScripts();
104 virtual void runScript(ScriptState*, const String& scriptId, ScriptValue* re sult, bool* wasThrown, String* exceptionMessage); 105 virtual void runScript(ScriptState*, const String& scriptId, ScriptValue* re sult, bool* wasThrown, String* exceptionDetailsText, int* lineNumber, int* colum nNumber, RefPtr<ScriptCallStack>* stackTrace);
105 virtual void setPreprocessorSource(const String&) { } 106 virtual void setPreprocessorSource(const String&) { }
106 virtual void preprocessBeforeCompile(const v8::Debug::EventDetails&) { } 107 virtual void preprocessBeforeCompile(const v8::Debug::EventDetails&) { }
107 virtual PassOwnPtr<ScriptSourceCode> preprocess(LocalFrame*, const ScriptSou rceCode&); 108 virtual PassOwnPtr<ScriptSourceCode> preprocess(LocalFrame*, const ScriptSou rceCode&);
108 virtual String preprocessEventListener(LocalFrame*, const String& source, co nst String& url, const String& functionName); 109 virtual String preprocessEventListener(LocalFrame*, const String& source, co nst String& url, const String& functionName);
109 110
110 virtual void muteWarningsAndDeprecations() { } 111 virtual void muteWarningsAndDeprecations() { }
111 virtual void unmuteWarningsAndDeprecations() { } 112 virtual void unmuteWarningsAndDeprecations() { }
112 113
113 protected: 114 protected:
114 explicit ScriptDebugServer(v8::Isolate*); 115 explicit ScriptDebugServer(v8::Isolate*);
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 void stepCommandWithFrame(const char* functionName, const ScriptValue& frame ); 150 void stepCommandWithFrame(const char* functionName, const ScriptValue& frame );
150 PassRefPtr<JavaScriptCallFrame> wrapCallFrames(int maximumLimit, ScopeInfoDe tails); 151 PassRefPtr<JavaScriptCallFrame> wrapCallFrames(int maximumLimit, ScopeInfoDe tails);
151 152
152 bool m_runningNestedMessageLoop; 153 bool m_runningNestedMessageLoop;
153 }; 154 };
154 155
155 } // namespace WebCore 156 } // namespace WebCore
156 157
157 158
158 #endif // ScriptDebugServer_h 159 #endif // ScriptDebugServer_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698