Index: include/v8-platform.h |
diff --git a/include/v8-platform.h b/include/v8-platform.h |
index 4023a5b234fd4bb3b084299f6b9a3c2b1a8ffd65..d0b7aed8fc5a333bbef5281f8969db521e91c7af 100644 |
--- a/include/v8-platform.h |
+++ b/include/v8-platform.h |
@@ -164,6 +164,19 @@ class Platform { |
**/ |
virtual void UpdateTraceEventDuration(const uint8_t* category_enabled_flag, |
const char* name, uint64_t handle) {} |
+ |
+ class TraceStateObserver { |
+ public: |
+ virtual ~TraceStateObserver() = default; |
+ virtual void OnTraceEnabled() = 0; |
+ virtual void OnTraceDisabled() = 0; |
+ }; |
+ |
+ /** Adds tracing state change observer. */ |
+ virtual void AddTraceStateObserver(TraceStateObserver*) {} |
+ |
+ /** Removes tracing state change observer. */ |
+ virtual void RemoveTraceStateObserver(TraceStateObserver*) {} |
}; |
} // namespace v8 |