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

Side by Side Diff: content/browser/tracing/tracing_controller_impl.h

Issue 892213004: Mechanical rename of base::debug -> base::trace_event for /content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_trace_part3_1
Patch Set: Rebase. Created 5 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_ 5 #ifndef CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_
6 #define CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_ 6 #define CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 10 matching lines...) Expand all
21 21
22 class TraceMessageFilter; 22 class TraceMessageFilter;
23 class TracingUI; 23 class TracingUI;
24 24
25 class TracingControllerImpl : public TracingController { 25 class TracingControllerImpl : public TracingController {
26 public: 26 public:
27 static TracingControllerImpl* GetInstance(); 27 static TracingControllerImpl* GetInstance();
28 28
29 // TracingController implementation. 29 // TracingController implementation.
30 bool GetCategories(const GetCategoriesDoneCallback& callback) override; 30 bool GetCategories(const GetCategoriesDoneCallback& callback) override;
31 bool EnableRecording(const base::debug::CategoryFilter& category_filter, 31 bool EnableRecording(const base::trace_event::CategoryFilter& category_filter,
32 const base::debug::TraceOptions& trace_options, 32 const base::trace_event::TraceOptions& trace_options,
33 const EnableRecordingDoneCallback& callback) override; 33 const EnableRecordingDoneCallback& callback) override;
34 bool DisableRecording(const scoped_refptr<TraceDataSink>& sink) override; 34 bool DisableRecording(const scoped_refptr<TraceDataSink>& sink) override;
35 bool EnableMonitoring(const base::debug::CategoryFilter& category_filter, 35 bool EnableMonitoring(
36 const base::debug::TraceOptions& trace_options, 36 const base::trace_event::CategoryFilter& category_filter,
37 const EnableMonitoringDoneCallback& callback) override; 37 const base::trace_event::TraceOptions& trace_options,
38 const EnableMonitoringDoneCallback& callback) override;
38 bool DisableMonitoring( 39 bool DisableMonitoring(
39 const DisableMonitoringDoneCallback& callback) override; 40 const DisableMonitoringDoneCallback& callback) override;
40 void GetMonitoringStatus( 41 void GetMonitoringStatus(
41 bool* out_enabled, 42 bool* out_enabled,
42 base::debug::CategoryFilter* out_category_filter, 43 base::trace_event::CategoryFilter* out_category_filter,
43 base::debug::TraceOptions* out_trace_options) override; 44 base::trace_event::TraceOptions* out_trace_options) override;
44 bool CaptureMonitoringSnapshot( 45 bool CaptureMonitoringSnapshot(
45 const scoped_refptr<TraceDataSink>& sink) override; 46 const scoped_refptr<TraceDataSink>& sink) override;
46 bool GetTraceBufferUsage( 47 bool GetTraceBufferUsage(
47 const GetTraceBufferUsageCallback& callback) override; 48 const GetTraceBufferUsageCallback& callback) override;
48 bool SetWatchEvent(const std::string& category_name, 49 bool SetWatchEvent(const std::string& category_name,
49 const std::string& event_name, 50 const std::string& event_name,
50 const WatchEventCallback& callback) override; 51 const WatchEventCallback& callback) override;
51 bool CancelWatchEvent() override; 52 bool CancelWatchEvent() override;
52 53
53 void RegisterTracingUI(TracingUI* tracing_ui); 54 void RegisterTracingUI(TracingUI* tracing_ui);
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 111
111 #if defined(OS_CHROMEOS) || defined(OS_WIN) 112 #if defined(OS_CHROMEOS) || defined(OS_WIN)
112 void OnEndSystemTracingAcked( 113 void OnEndSystemTracingAcked(
113 const scoped_refptr<base::RefCountedString>& events_str_ptr); 114 const scoped_refptr<base::RefCountedString>& events_str_ptr);
114 #endif 115 #endif
115 116
116 void OnCaptureMonitoringSnapshotAcked( 117 void OnCaptureMonitoringSnapshotAcked(
117 TraceMessageFilter* trace_message_filter); 118 TraceMessageFilter* trace_message_filter);
118 119
119 void OnTraceLogStatusReply(TraceMessageFilter* trace_message_filter, 120 void OnTraceLogStatusReply(TraceMessageFilter* trace_message_filter,
120 const base::debug::TraceLogStatus& status); 121 const base::trace_event::TraceLogStatus& status);
121 122
122 void OnWatchEventMatched(); 123 void OnWatchEventMatched();
123 124
124 void SetEnabledOnFileThread( 125 void SetEnabledOnFileThread(
125 const base::debug::CategoryFilter& category_filter, 126 const base::trace_event::CategoryFilter& category_filter,
126 int mode, 127 int mode,
127 const base::debug::TraceOptions& trace_options, 128 const base::trace_event::TraceOptions& trace_options,
128 const base::Closure& callback); 129 const base::Closure& callback);
129 void SetDisabledOnFileThread(const base::Closure& callback); 130 void SetDisabledOnFileThread(const base::Closure& callback);
130 void OnEnableRecordingDone(const base::debug::CategoryFilter& category_filter, 131 void OnEnableRecordingDone(
131 const base::debug::TraceOptions& trace_options, 132 const base::trace_event::CategoryFilter& category_filter,
132 const EnableRecordingDoneCallback& callback); 133 const base::trace_event::TraceOptions& trace_options,
134 const EnableRecordingDoneCallback& callback);
133 void OnDisableRecordingDone(); 135 void OnDisableRecordingDone();
134 void OnEnableMonitoringDone( 136 void OnEnableMonitoringDone(
135 const base::debug::CategoryFilter& category_filter, 137 const base::trace_event::CategoryFilter& category_filter,
136 const base::debug::TraceOptions& trace_options, 138 const base::trace_event::TraceOptions& trace_options,
137 const EnableMonitoringDoneCallback& callback); 139 const EnableMonitoringDoneCallback& callback);
138 void OnDisableMonitoringDone(const DisableMonitoringDoneCallback& callback); 140 void OnDisableMonitoringDone(const DisableMonitoringDoneCallback& callback);
139 141
140 void OnMonitoringStateChanged(bool is_monitoring); 142 void OnMonitoringStateChanged(bool is_monitoring);
141 143
142 TraceMessageFilterSet trace_message_filters_; 144 TraceMessageFilterSet trace_message_filters_;
143 145
144 // Pending acks for DisableRecording. 146 // Pending acks for DisableRecording.
145 int pending_disable_recording_ack_count_; 147 int pending_disable_recording_ack_count_;
146 TraceMessageFilterSet pending_disable_recording_filters_; 148 TraceMessageFilterSet pending_disable_recording_filters_;
147 // Pending acks for CaptureMonitoringSnapshot. 149 // Pending acks for CaptureMonitoringSnapshot.
148 int pending_capture_monitoring_snapshot_ack_count_; 150 int pending_capture_monitoring_snapshot_ack_count_;
149 TraceMessageFilterSet pending_capture_monitoring_filters_; 151 TraceMessageFilterSet pending_capture_monitoring_filters_;
150 // Pending acks for GetTraceLogStatus. 152 // Pending acks for GetTraceLogStatus.
151 int pending_trace_log_status_ack_count_; 153 int pending_trace_log_status_ack_count_;
152 TraceMessageFilterSet pending_trace_log_status_filters_; 154 TraceMessageFilterSet pending_trace_log_status_filters_;
153 float maximum_trace_buffer_usage_; 155 float maximum_trace_buffer_usage_;
154 size_t approximate_event_count_; 156 size_t approximate_event_count_;
155 157
156 #if defined(OS_CHROMEOS) || defined(OS_WIN) 158 #if defined(OS_CHROMEOS) || defined(OS_WIN)
157 bool is_system_tracing_; 159 bool is_system_tracing_;
158 #endif 160 #endif
159 bool is_recording_; 161 bool is_recording_;
160 bool is_monitoring_; 162 bool is_monitoring_;
161 base::debug::TraceOptions trace_options_; 163 base::trace_event::TraceOptions trace_options_;
162 164
163 GetCategoriesDoneCallback pending_get_categories_done_callback_; 165 GetCategoriesDoneCallback pending_get_categories_done_callback_;
164 GetTraceBufferUsageCallback pending_trace_buffer_usage_callback_; 166 GetTraceBufferUsageCallback pending_trace_buffer_usage_callback_;
165 167
166 std::string watch_category_name_; 168 std::string watch_category_name_;
167 std::string watch_event_name_; 169 std::string watch_event_name_;
168 WatchEventCallback watch_event_callback_; 170 WatchEventCallback watch_event_callback_;
169 171
170 std::set<std::string> known_category_groups_; 172 std::set<std::string> known_category_groups_;
171 std::set<TracingUI*> tracing_uis_; 173 std::set<TracingUI*> tracing_uis_;
172 scoped_refptr<TraceDataSink> trace_data_sink_; 174 scoped_refptr<TraceDataSink> trace_data_sink_;
173 scoped_refptr<TraceDataSink> monitoring_data_sink_; 175 scoped_refptr<TraceDataSink> monitoring_data_sink_;
174 DISALLOW_COPY_AND_ASSIGN(TracingControllerImpl); 176 DISALLOW_COPY_AND_ASSIGN(TracingControllerImpl);
175 }; 177 };
176 178
177 } // namespace content 179 } // namespace content
178 180
179 #endif // CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_ 181 #endif // CONTENT_BROWSER_TRACING_TRACING_CONTROLLER_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/tracing/tracing_controller_browsertest.cc ('k') | content/browser/tracing/tracing_controller_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698