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

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

Issue 2012753003: DevTools: consolidate protocol generators for front-end, backend and type builder. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 14 matching lines...) Expand all
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
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 V8RuntimeAgentImpl_h 31 #ifndef V8RuntimeAgentImpl_h
32 #define V8RuntimeAgentImpl_h 32 #define V8RuntimeAgentImpl_h
33 33
34 #include "platform/inspector_protocol/Allocator.h" 34 #include "platform/inspector_protocol/Allocator.h"
35 #include "platform/inspector_protocol/Backend.h"
36 #include "platform/inspector_protocol/Frontend.h"
37 #include "platform/inspector_protocol/String16.h" 35 #include "platform/inspector_protocol/String16.h"
36 #include "platform/inspector_protocol/TypeBuilder.h"
38 37
39 #include <v8.h> 38 #include <v8.h>
40 39
41 namespace blink { 40 namespace blink {
42 41
43 class InjectedScript; 42 class InjectedScript;
44 class InspectedContext; 43 class InspectedContext;
45 class RemoteObjectIdBase; 44 class RemoteObjectIdBase;
46 class V8DebuggerImpl; 45 class V8DebuggerImpl;
47 class V8InspectorSessionImpl; 46 class V8InspectorSessionImpl;
48 47
49 namespace protocol { 48 namespace protocol {
50 class DictionaryValue; 49 class DictionaryValue;
51 } 50 }
52 51
53 using protocol::Maybe; 52 using protocol::Maybe;
54 53
55 class V8RuntimeAgentImpl : public protocol::Runtime::Backend { 54 class V8RuntimeAgentImpl : public protocol::Runtime::Backend {
56 PROTOCOL_DISALLOW_COPY(V8RuntimeAgentImpl); 55 PROTOCOL_DISALLOW_COPY(V8RuntimeAgentImpl);
57 public: 56 public:
58 V8RuntimeAgentImpl(V8InspectorSessionImpl*, protocol::Runtime::Frontend*, pr otocol::DictionaryValue* state); 57 V8RuntimeAgentImpl(V8InspectorSessionImpl*, protocol::FrontendChannel*, prot ocol::DictionaryValue* state);
59 ~V8RuntimeAgentImpl() override; 58 ~V8RuntimeAgentImpl() override;
60 void restore(); 59 void restore();
61 60
62 // Part of the protocol. 61 // Part of the protocol.
63 void enable(ErrorString*) override; 62 void enable(ErrorString*) override;
64 void disable(ErrorString*) override; 63 void disable(ErrorString*) override;
65 void evaluate(ErrorString*, 64 void evaluate(ErrorString*,
66 const String16& expression, 65 const String16& expression,
67 const Maybe<String16>& objectGroup, 66 const Maybe<String16>& objectGroup,
68 const Maybe<bool>& includeCommandLineAPI, 67 const Maybe<bool>& includeCommandLineAPI,
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 Maybe<protocol::Runtime::ExceptionDetails>*) override; 112 Maybe<protocol::Runtime::ExceptionDetails>*) override;
114 113
115 void reset(); 114 void reset();
116 void reportExecutionContextCreated(InspectedContext*); 115 void reportExecutionContextCreated(InspectedContext*);
117 void reportExecutionContextDestroyed(InspectedContext*); 116 void reportExecutionContextDestroyed(InspectedContext*);
118 void inspect(std::unique_ptr<protocol::Runtime::RemoteObject> objectToInspec t, std::unique_ptr<protocol::DictionaryValue> hints); 117 void inspect(std::unique_ptr<protocol::Runtime::RemoteObject> objectToInspec t, std::unique_ptr<protocol::DictionaryValue> hints);
119 118
120 private: 119 private:
121 V8InspectorSessionImpl* m_session; 120 V8InspectorSessionImpl* m_session;
122 protocol::DictionaryValue* m_state; 121 protocol::DictionaryValue* m_state;
123 protocol::Runtime::Frontend* m_frontend; 122 protocol::Runtime::Frontend m_frontend;
124 V8DebuggerImpl* m_debugger; 123 V8DebuggerImpl* m_debugger;
125 bool m_enabled; 124 bool m_enabled;
126 protocol::HashMap<String16, std::unique_ptr<v8::Global<v8::Script>>> m_compi ledScripts; 125 protocol::HashMap<String16, std::unique_ptr<v8::Global<v8::Script>>> m_compi ledScripts;
127 }; 126 };
128 127
129 } // namespace blink 128 } // namespace blink
130 129
131 #endif // V8RuntimeAgentImpl_h 130 #endif // V8RuntimeAgentImpl_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698