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

Side by Side Diff: runtime/vm/service.h

Issue 1270103002: Allow Dart code to register service protocol handlers (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « runtime/vm/json_stream.cc ('k') | runtime/vm/service.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_SERVICE_H_ 5 #ifndef VM_SERVICE_H_
6 #define VM_SERVICE_H_ 6 #define VM_SERVICE_H_
7 7
8 #include "include/dart_tools_api.h" 8 #include "include/dart_tools_api.h"
9 9
10 #include "vm/allocation.h" 10 #include "vm/allocation.h"
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 } 137 }
138 138
139 private: 139 private:
140 static void InvokeMethod(Isolate* isolate, const Array& message); 140 static void InvokeMethod(Isolate* isolate, const Array& message);
141 141
142 static void EmbedderHandleMessage(EmbedderServiceHandler* handler, 142 static void EmbedderHandleMessage(EmbedderServiceHandler* handler,
143 JSONStream* js); 143 JSONStream* js);
144 144
145 static EmbedderServiceHandler* FindIsolateEmbedderHandler(const char* name); 145 static EmbedderServiceHandler* FindIsolateEmbedderHandler(const char* name);
146 static EmbedderServiceHandler* FindRootEmbedderHandler(const char* name); 146 static EmbedderServiceHandler* FindRootEmbedderHandler(const char* name);
147 147 static bool ExtensionHandlerExists(const String& name);
148 static bool InvokeExtensionHandler(const String& name,
149 const Array& parameter_keys,
150 const Array& parameter_values,
151 const Instance& reply_port,
152 const Instance& id);
148 static void SendEvent(const char* stream_id, 153 static void SendEvent(const char* stream_id,
149 const char* event_type, 154 const char* event_type,
150 const Object& eventMessage); 155 const Object& eventMessage);
151 156
152 // Does not take ownership of 'data'. 157 // Does not take ownership of 'data'.
153 static void SendEventWithData(const char* stream_id, 158 static void SendEventWithData(const char* stream_id,
154 const char* event_type, 159 const char* event_type,
155 const String& meta, 160 const String& meta,
156 const uint8_t* data, 161 const uint8_t* data,
157 intptr_t size); 162 intptr_t size);
(...skipping 10 matching lines...) Expand all
168 static bool needs_isolate_events_; 173 static bool needs_isolate_events_;
169 static bool needs_debug_events_; 174 static bool needs_debug_events_;
170 static bool needs_gc_events_; 175 static bool needs_gc_events_;
171 static bool needs_echo_events_; 176 static bool needs_echo_events_;
172 static bool needs_graph_events_; 177 static bool needs_graph_events_;
173 }; 178 };
174 179
175 } // namespace dart 180 } // namespace dart
176 181
177 #endif // VM_SERVICE_H_ 182 #endif // VM_SERVICE_H_
OLDNEW
« no previous file with comments | « runtime/vm/json_stream.cc ('k') | runtime/vm/service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698