Chromium Code Reviews| Index: runtime/vm/json_stream.cc |
| diff --git a/runtime/vm/json_stream.cc b/runtime/vm/json_stream.cc |
| index e75ba30f6c3458f82cf1505323a1db8ad01a31ad..f0b0cd925c8472d6b1c6c9e5d9e535a177110d8d 100644 |
| --- a/runtime/vm/json_stream.cc |
| +++ b/runtime/vm/json_stream.cc |
| @@ -14,6 +14,7 @@ |
| #include "vm/safepoint.h" |
| #include "vm/service.h" |
| #include "vm/service_event.h" |
| +#include "vm/thread_registry.h" |
| #include "vm/timeline.h" |
| #include "vm/unicode.h" |
| @@ -540,6 +541,22 @@ void JSONStream::PrintValue(Isolate* isolate, bool ref) { |
| } |
| +void JSONStream::PrintValue(ThreadRegistry* reg) { |
| + PrintCommaIfNeeded(); |
| + reg->PrintJSON(this); |
| +} |
| + |
| + |
| +void JSONStream::PrintValue(Thread* thread) { |
| + PrintCommaIfNeeded(); |
| + thread->PrintJSON(this); |
| +} |
| + |
|
zra
2016/12/08 18:54:13
Please keep two newlines between functions in sour
bkonyi
2016/12/08 20:58:32
Done.
|
| +void JSONStream::PrintValue(Zone* zone) { |
| + PrintCommaIfNeeded(); |
| + zone->PrintJSON(this); |
| +} |
| + |
|
zra
2016/12/08 18:54:13
ditto
bkonyi
2016/12/08 20:58:32
Done.
|
| void JSONStream::PrintValue(const TimelineEvent* timeline_event) { |
| PrintCommaIfNeeded(); |
| timeline_event->PrintJSON(this); |
| @@ -663,6 +680,24 @@ void JSONStream::PrintProperty(const char* name, Isolate* isolate) { |
| } |
| +void JSONStream::PrintProperty(const char* name, ThreadRegistry* reg) { |
| + PrintPropertyName(name); |
| + PrintValue(reg); |
| +} |
| + |
| + |
| +void JSONStream::PrintProperty(const char* name, Thread* thread) { |
| + PrintPropertyName(name); |
| + PrintValue(thread); |
| +} |
| + |
| + |
| +void JSONStream::PrintProperty(const char* name, Zone* zone) { |
| + PrintPropertyName(name); |
| + PrintValue(zone); |
| +} |
| + |
| + |
| void JSONStream::PrintProperty(const char* name, |
| const TimelineEvent* timeline_event) { |
| PrintPropertyName(name); |