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

Side by Side Diff: third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.h

Issue 1921143002: [DevTools] Align Console implementation with The JSey way (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move-part-command-line-api-to-native
Patch Set: Created 4 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) 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 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 void didExecuteScript(v8::Local<v8::Context>) override; 114 void didExecuteScript(v8::Local<v8::Context>) override;
115 PassOwnPtr<V8StackTrace> createStackTrace(v8::Local<v8::StackTrace>, size_t maxStackSize) override; 115 PassOwnPtr<V8StackTrace> createStackTrace(v8::Local<v8::StackTrace>, size_t maxStackSize) override;
116 PassOwnPtr<V8StackTrace> captureStackTrace(size_t maxStackSize) override; 116 PassOwnPtr<V8StackTrace> captureStackTrace(size_t maxStackSize) override;
117 117
118 using ContextByIdMap = protocol::HashMap<int, OwnPtr<InspectedContext>>; 118 using ContextByIdMap = protocol::HashMap<int, OwnPtr<InspectedContext>>;
119 void discardInspectedContext(int contextGroupId, int contextId); 119 void discardInspectedContext(int contextGroupId, int contextId);
120 const ContextByIdMap* contextGroup(int contextGroupId); 120 const ContextByIdMap* contextGroup(int contextGroupId);
121 void disconnect(V8InspectorSessionImpl*); 121 void disconnect(V8InspectorSessionImpl*);
122 V8InspectorSessionImpl* sessionForContextGroup(int contextGroupId); 122 V8InspectorSessionImpl* sessionForContextGroup(int contextGroupId);
123 123
124 v8::MaybeLocal<v8::FunctionTemplate> functionTemplate(const String16& name);
125 void setFunctionTemplate(const String16& name, v8::Local<v8::FunctionTemplat e>);
126
127 private: 124 private:
128 void enable(); 125 void enable();
129 void disable(); 126 void disable();
130 V8DebuggerAgentImpl* findEnabledDebuggerAgent(int contextGroupId); 127 V8DebuggerAgentImpl* findEnabledDebuggerAgent(int contextGroupId);
131 V8DebuggerAgentImpl* findEnabledDebuggerAgent(v8::Local<v8::Context>); 128 V8DebuggerAgentImpl* findEnabledDebuggerAgent(v8::Local<v8::Context>);
132 129
133 void compileDebuggerScript(); 130 void compileDebuggerScript();
134 v8::MaybeLocal<v8::Value> callDebuggerMethod(const char* functionName, int a rgc, v8::Local<v8::Value> argv[]); 131 v8::MaybeLocal<v8::Value> callDebuggerMethod(const char* functionName, int a rgc, v8::Local<v8::Value> argv[]);
135 v8::Local<v8::Context> debuggerContext() const; 132 v8::Local<v8::Context> debuggerContext() const;
136 void clearBreakpoints(); 133 void clearBreakpoints();
(...skipping 11 matching lines...) Expand all
148 void handleV8AsyncTaskEvent(V8DebuggerAgentImpl*, v8::Local<v8::Context>, v8 ::Local<v8::Object> executionState, v8::Local<v8::Object> eventData); 145 void handleV8AsyncTaskEvent(V8DebuggerAgentImpl*, v8::Local<v8::Context>, v8 ::Local<v8::Object> executionState, v8::Local<v8::Object> eventData);
149 146
150 v8::Isolate* m_isolate; 147 v8::Isolate* m_isolate;
151 V8DebuggerClient* m_client; 148 V8DebuggerClient* m_client;
152 using ContextsByGroupMap = protocol::HashMap<int, OwnPtr<ContextByIdMap>>; 149 using ContextsByGroupMap = protocol::HashMap<int, OwnPtr<ContextByIdMap>>;
153 ContextsByGroupMap m_contexts; 150 ContextsByGroupMap m_contexts;
154 using SessionMap = protocol::HashMap<int, V8InspectorSessionImpl*>; 151 using SessionMap = protocol::HashMap<int, V8InspectorSessionImpl*>;
155 SessionMap m_sessions; 152 SessionMap m_sessions;
156 int m_enabledAgentsCount; 153 int m_enabledAgentsCount;
157 bool m_breakpointsActivated; 154 bool m_breakpointsActivated;
158 v8::Global<v8::FunctionTemplate> m_breakProgramCallbackTemplate;
159 v8::Global<v8::Object> m_debuggerScript; 155 v8::Global<v8::Object> m_debuggerScript;
160 v8::Global<v8::Context> m_debuggerContext; 156 v8::Global<v8::Context> m_debuggerContext;
161 v8::Local<v8::Object> m_executionState; 157 v8::Local<v8::Object> m_executionState;
162 v8::Local<v8::Context> m_pausedContext; 158 v8::Local<v8::Context> m_pausedContext;
163 bool m_runningNestedMessageLoop; 159 bool m_runningNestedMessageLoop;
164 v8::Global<v8::Context> m_regexContext; 160 v8::Global<v8::Context> m_regexContext;
165 using FunctionTemplateMap = protocol::HashMap<String16, OwnPtr<v8::Global<v8 ::FunctionTemplate>>>;
166 FunctionTemplateMap m_templates;
167 }; 161 };
168 162
169 } // namespace blink 163 } // namespace blink
170 164
171 165
172 #endif // V8DebuggerImpl_h 166 #endif // V8DebuggerImpl_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698