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

Unified Diff: runtime/vm/json_stream.h

Issue 1170503004: Initial Timeline Events (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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
Index: runtime/vm/json_stream.h
diff --git a/runtime/vm/json_stream.h b/runtime/vm/json_stream.h
index 4a061787afa18840eb60cb1ff690dfc7ffebcbd2..57204671e4879a8f7b22936f60372c850effaee8 100644
--- a/runtime/vm/json_stream.h
+++ b/runtime/vm/json_stream.h
@@ -10,9 +10,11 @@
#include "vm/allocation.h"
#include "vm/service.h"
+
namespace dart {
class Array;
+class Breakpoint;
class Field;
class GrowableObjectArray;
class Instance;
@@ -23,8 +25,8 @@ class Metric;
class Object;
class Script;
class ServiceEvent;
-class Breakpoint;
class String;
+class TimelineEvent;
class Zone;
@@ -127,6 +129,7 @@ class JSONStream : ValueObject {
void PrintValue(MessageQueue* queue);
void PrintValue(Isolate* isolate, bool ref = true);
bool PrintValueStr(const String& s, intptr_t limit);
+ void PrintValue(TimelineEvent* timeline_event);
void PrintServiceId(const Object& o);
void PrintPropertyBool(const char* name, bool b);
@@ -145,6 +148,7 @@ class JSONStream : ValueObject {
void PrintProperty(const char* name, Metric* metric);
void PrintProperty(const char* name, MessageQueue* queue);
void PrintProperty(const char* name, Isolate* isolate);
+ void PrintProperty(const char* name, TimelineEvent* timeline_event);
void PrintPropertyName(const char* name);
void PrintCommaIfNeeded();
bool NeedComma();
@@ -238,6 +242,9 @@ class JSONObject : public ValueObject {
void AddProperty(const char* name, Isolate* isolate) const {
stream_->PrintProperty(name, isolate);
}
+ void AddProperty(const char* name, TimelineEvent* timeline_event) const {
+ stream_->PrintProperty(name, timeline_event);
+ }
void AddPropertyF(const char* name, const char* format, ...) const
PRINTF_ATTRIBUTE(3, 4);
@@ -289,6 +296,9 @@ class JSONArray : public ValueObject {
void AddValue(MessageQueue* queue) const {
stream_->PrintValue(queue);
}
+ void AddValue(TimelineEvent* timeline_event) const {
+ stream_->PrintValue(timeline_event);
+ }
void AddValueF(const char* format, ...) const PRINTF_ATTRIBUTE(2, 3);
private:

Powered by Google App Engine
This is Rietveld 408576698