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

Unified Diff: runtime/vm/timeline.h

Issue 1297443002: Improve timeline iterators and tests (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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/timeline.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/timeline.h
diff --git a/runtime/vm/timeline.h b/runtime/vm/timeline.h
index 191c1f84782f2c9618bd727495c8d48b65184626..3cda6c92337ec8ffb7081a83bc74852a510ae0f1 100644
--- a/runtime/vm/timeline.h
+++ b/runtime/vm/timeline.h
@@ -91,6 +91,10 @@ class TimelineEvent {
return thread_;
}
+ const char* label() const {
+ return label_;
+ }
+
private:
struct TimelineEventArgument {
const char* name;
@@ -475,12 +479,13 @@ class TimelineEventBlockIterator {
explicit TimelineEventBlockIterator(TimelineEventRecorder* recorder);
~TimelineEventBlockIterator();
- void Reset();
- bool Next();
+ void Reset(TimelineEventRecorder* recorder);
- TimelineEventBlock* current() const {
- return current_;
- }
+ // Returns false when there are no more blocks.
+ bool HasNext() const;
+
+ // Returns the next block and moves forward.
+ TimelineEventBlock* Next();
private:
TimelineEventBlock* current_;
« no previous file with comments | « no previous file | runtime/vm/timeline.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698