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

Unified Diff: runtime/vm/service.h

Issue 1166433008: 2nd attempt at adding streamListen/streamCancel to the service protocol. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: fix context objects Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/service.h
diff --git a/runtime/vm/service.h b/runtime/vm/service.h
index 4ca3eb01c83f22fcfa962e7b646825159d0e30bf..a7a7569369cb95238737d728a6426c734c19c09f 100644
--- a/runtime/vm/service.h
+++ b/runtime/vm/service.h
@@ -67,7 +67,14 @@ class Service : public AllStatic {
// Handles a message which is directed to a particular isolate.
static void HandleIsolateMessage(Isolate* isolate, const Array& message);
- static bool NeedsEvents();
+ static bool NeedsIsolateEvents() { return needs_isolate_events_; }
+ static bool NeedsDebugEvents() { return needs_debug_events_; }
+ static bool NeedsGCEvents() { return needs_gc_events_; }
+ static bool NeedsEchoEvents() { return needs_echo_events_; }
+ static bool NeedsGraphEvents() { return needs_graph_events_; }
+
+ static void ListenStream(const char* stream_id);
+ static void CancelStream(const char* stream_id);
static void HandleEvent(ServiceEvent* event);
@@ -94,15 +101,24 @@ class Service : public AllStatic {
static EmbedderServiceHandler* FindIsolateEmbedderHandler(const char* name);
static EmbedderServiceHandler* FindRootEmbedderHandler(const char* name);
- static void SendEvent(intptr_t eventType,
+ static void SendEvent(const char* stream_id,
+ const char* event_type,
const Object& eventMessage);
// Does not take ownership of 'data'.
- static void SendEvent(const String& meta,
- const uint8_t* data,
- intptr_t size);
+ static void SendEventWithData(const char* stream_id,
+ const char* event_type,
+ const String& meta,
+ const uint8_t* data,
+ intptr_t size);
static EmbedderServiceHandler* isolate_service_handler_head_;
static EmbedderServiceHandler* root_service_handler_head_;
+
+ static bool needs_isolate_events_;
+ static bool needs_debug_events_;
+ static bool needs_gc_events_;
+ static bool needs_echo_events_;
+ static bool needs_graph_events_;
};
} // namespace dart
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698