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

Unified Diff: base/trace_event/tracing_agent.h

Issue 1614063005: Adds a callback to TracingAgent::StartAgentTracing() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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 | chromeos/dbus/debug_daemon_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/tracing_agent.h
diff --git a/base/trace_event/tracing_agent.h b/base/trace_event/tracing_agent.h
index 259ff0773dfeb2f47be6ed719df91fc0af42b410..77183b0d123c46dba163daf239fcb5ea033a12a1 100644
--- a/base/trace_event/tracing_agent.h
+++ b/base/trace_event/tracing_agent.h
@@ -26,6 +26,8 @@ class TraceConfig;
// system trace and PowerTracingAgent for BattOr power trace.
class BASE_EXPORT TracingAgent {
public:
+ using StartAgentTracingCallback =
+ base::Callback<void(const std::string& agent_name, bool success)>;
// Passing a null or empty events_str_ptr indicates that no trace data is
// available for the specified agent.
using StopAgentTracingCallback = base::Callback<void(
@@ -53,7 +55,8 @@ class BASE_EXPORT TracingAgent {
virtual std::string GetTraceEventLabel() = 0;
// Starts tracing on the tracing agent with the trace configuration.
- virtual bool StartAgentTracing(const TraceConfig& trace_config) = 0;
+ virtual void StartAgentTracing(const TraceConfig& trace_config,
+ const StartAgentTracingCallback& callback) = 0;
// Stops tracing on the tracing agent. The trace data will be passed back to
// the TracingController via the callback.
« no previous file with comments | « no previous file | chromeos/dbus/debug_daemon_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698