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

Unified Diff: runtime/vm/isolate_reload.h

Issue 2186303002: Added JSON reporting to reload. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | runtime/vm/isolate_reload.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/isolate_reload.h
diff --git a/runtime/vm/isolate_reload.h b/runtime/vm/isolate_reload.h
index ce316f6dd2e61a33a1bbf9898964b819892f6639..0a3b591322616f9e20f7fea12a200d2f2b981e6a 100644
--- a/runtime/vm/isolate_reload.h
+++ b/runtime/vm/isolate_reload.h
@@ -63,6 +63,9 @@ class InstanceMorpher : public ZoneAllocated {
// Dump the state of the morpher.
void Dump() const;
+ // Append the morper info to JSON array.
+ void AppendTo(JSONArray* array);
+
// Returns the list of objects that need to be morphed.
ZoneGrowableArray<const Instance*>* before() const { return before_; }
// Returns the list of morphed objects (matches order in before()).
@@ -100,6 +103,9 @@ class ReasonForCancelling : public ZoneAllocated {
// Default implementation calls ToError.
virtual RawString* ToString();
+ // Append the reason to JSON array.
+ virtual void AppendTo(JSONArray* array);
+
// Concrete subclasses must override either ToError or ToString.
};
@@ -110,6 +116,8 @@ class ClassReasonForCancelling : public ReasonForCancelling {
ClassReasonForCancelling(const Class& from, const Class& to)
: from_(from), to_(to) { }
+ void AppendTo(JSONArray* array);
+
protected:
const Class& from_;
const Class& to_;
@@ -163,9 +171,12 @@ class IsolateReloadContext {
// Record problem for this reload.
void AddReasonForCancelling(ReasonForCancelling* reason);
- // Report all reasons for cancelling reload.
+ // Reports all reasons for cancelling reload.
void ReportReasonsForCancelling();
+ // Reports the deails of a reload operation.
+ void ReportOnJSON(JSONStream* stream);
+
// Store morphing operation.
void AddInstanceMorpher(InstanceMorpher* morpher);
« no previous file with comments | « no previous file | runtime/vm/isolate_reload.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698