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

Unified Diff: runtime/observatory/lib/src/repositories/event.dart

Issue 2980733003: Introduced support for external services registration in the ServiceProtocol (Closed)
Patch Set: Address comments Created 3 years, 5 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
Index: runtime/observatory/lib/src/repositories/event.dart
diff --git a/runtime/observatory/lib/src/repositories/event.dart b/runtime/observatory/lib/src/repositories/event.dart
index 4c07f945cb553013f2e6d553874971c36658943f..dc9b3978cdc424160b05968bc859ae6fd6ae1916 100644
--- a/runtime/observatory/lib/src/repositories/event.dart
+++ b/runtime/observatory/lib/src/repositories/event.dart
@@ -33,6 +33,9 @@ class EventRepository implements M.EventRepository {
final Stream<M.ExtensionEvent> onExtensionEvent;
final Stream<M.TimelineEventsEvent> onTimelineEvents;
final Stream<M.ConnectionClosedEvent> onConnectionClosed;
+ final Stream<M.ServiceEvent> onServiceEvent;
+ final Stream<M.ServiceRegisteredEvent> onServiceRegistered;
+ final Stream<M.ServiceUnregisteredEvent> onServiceUnregistered;
EventRepository() : this._(new StreamController.broadcast());
@@ -46,7 +49,8 @@ class EventRepository implements M.EventRepository {
controller.stream.where((e) => e is M.LoggingEvent),
controller.stream.where((e) => e is M.ExtensionEvent),
controller.stream.where((e) => e is M.TimelineEventsEvent),
- controller.stream.where((e) => e is M.ConnectionClosedEvent));
+ controller.stream.where((e) => e is M.ConnectionClosedEvent),
+ controller.stream.where((e) => e is M.ServiceEvent));
EventRepository.__(
StreamController controller,
@@ -57,7 +61,8 @@ class EventRepository implements M.EventRepository {
Stream<M.LoggingEvent> onLoggingEvent,
Stream<M.ExtensionEvent> onExtensionEvent,
Stream<M.TimelineEventsEvent> onTimelineEvents,
- Stream<M.ConnectionClosedEvent> onConnectionClosed)
+ Stream<M.ConnectionClosedEvent> onConnectionClosed,
+ Stream<M.ServiceEvent> onServiceEvent)
: _onEvent = controller,
onVMEvent = onVMEvent,
onVMUpdate = onVMEvent.where((e) => e is M.VMUpdateEvent),
@@ -93,7 +98,12 @@ class EventRepository implements M.EventRepository {
onLoggingEvent = onLoggingEvent,
onExtensionEvent = onExtensionEvent,
onTimelineEvents = onTimelineEvents,
- onConnectionClosed = onConnectionClosed;
+ onConnectionClosed = onConnectionClosed,
+ onServiceEvent = onServiceEvent,
+ onServiceRegistered =
+ onServiceEvent.where((e) => e is M.ServiceRegisteredEvent),
+ onServiceUnregistered =
+ onServiceEvent.where((e) => e is M.ServiceUnregisteredEvent);
void add(M.Event e) {
_onEvent.add(e);
« no previous file with comments | « runtime/observatory/lib/src/models/repositories/isolate.dart ('k') | runtime/observatory/lib/src/repositories/isolate.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698