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

Unified Diff: content/public/browser/tracing_controller.h

Issue 66893003: Allow TracingController to output trace data to specified file (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Removed unnecessary include Created 7 years, 1 month 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 | « content/browser/tracing/tracing_controller_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/browser/tracing_controller.h
diff --git a/content/public/browser/tracing_controller.h b/content/public/browser/tracing_controller.h
index d3bc7bd9df9f2ec6dc5cbd6d305d6dacaec1e070..2434ad4967a2ec64f0ac2a54b763fe13efa20155 100644
--- a/content/public/browser/tracing_controller.h
+++ b/content/public/browser/tracing_controller.h
@@ -75,9 +75,16 @@ class TracingController {
// Once all child processes have acked to the DisableRecording request,
// TracingFileResultCallback will be called back with a file that contains
// the traced data.
- typedef base::Callback<void(scoped_ptr<base::FilePath>)>
- TracingFileResultCallback;
- virtual bool DisableRecording(const TracingFileResultCallback& callback) = 0;
+ //
+ // Trace data will be written into |result_file_path| if it is not empty, or
+ // into a temporary file. The actual file path will be passed to |callback| if
+ // it's not null.
+ //
+ // If |result_file_path| is empty and |callback| is null, trace data won't be
+ // written to any file.
+ typedef base::Callback<void(const base::FilePath&)> TracingFileResultCallback;
+ virtual bool DisableRecording(const base::FilePath& result_file_path,
+ const TracingFileResultCallback& callback) = 0;
// Start monitoring on all processes.
//
@@ -119,7 +126,14 @@ class TracingController {
// Once all child processes have acked to the CaptureMonitoringSnapshot
// request, TracingFileResultCallback will be called back with a file that
// contains the traced data.
+ //
+ // Trace data will be written into |result_file_path| if it is not empty, or
+ // into a temporary file. The actual file path will be passed to |callback|.
+ //
+ // If |result_file_path| is empty and |callback| is null, trace data won't be
+ // written to any file.
virtual void CaptureMonitoringSnapshot(
+ const base::FilePath& result_file_path,
const TracingFileResultCallback& callback) = 0;
protected:
« no previous file with comments | « content/browser/tracing/tracing_controller_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698