| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ | 6 #define CONTENT_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include "base/debug/trace_event.h" | 8 #include "base/debug/trace_event.h" |
| 9 #include "content/common/content_export.h" | 9 #include "content/common/content_export.h" |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 // asynchronously ask all child processes to flush any pending trace data. | 55 // asynchronously ask all child processes to flush any pending trace data. |
| 56 // | 56 // |
| 57 // Once all child processes have acked the EndTracing request, | 57 // Once all child processes have acked the EndTracing request, |
| 58 // TraceSubscriber will be called with OnEndTracingComplete. | 58 // TraceSubscriber will be called with OnEndTracingComplete. |
| 59 // | 59 // |
| 60 // If a previous call to EndTracingAsync is already pending, | 60 // If a previous call to EndTracingAsync is already pending, |
| 61 // or if another subscriber is tracing, | 61 // or if another subscriber is tracing, |
| 62 // EndTracingAsync will return false meaning it failed. | 62 // EndTracingAsync will return false meaning it failed. |
| 63 virtual bool EndTracingAsync(TraceSubscriber* subscriber) = 0; | 63 virtual bool EndTracingAsync(TraceSubscriber* subscriber) = 0; |
| 64 | 64 |
| 65 virtual bool BeginContinuousSamplingTracing(TraceSubscriber* subscriber) = 0; |
| 66 virtual bool EndContinuousSamplingTracing(TraceSubscriber* subscriber) = 0; |
| 67 virtual bool ShowContinuousSamplingTracingAsync( |
| 68 TraceSubscriber* subscriber) = 0; |
| 69 |
| 65 // Get the maximum across processes of trace buffer percent full state. | 70 // Get the maximum across processes of trace buffer percent full state. |
| 66 // When the TraceBufferPercentFull value is determined, | 71 // When the TraceBufferPercentFull value is determined, |
| 67 // subscriber->OnTraceBufferPercentFullReply is called. | 72 // subscriber->OnTraceBufferPercentFullReply is called. |
| 68 // When any child process reaches 100% full, the TraceController will end | 73 // When any child process reaches 100% full, the TraceController will end |
| 69 // tracing, and call TraceSubscriber::OnEndTracingComplete. | 74 // tracing, and call TraceSubscriber::OnEndTracingComplete. |
| 70 // GetTraceBufferPercentFullAsync fails in the following conditions: | 75 // GetTraceBufferPercentFullAsync fails in the following conditions: |
| 71 // trace is ending or disabled; | 76 // trace is ending or disabled; |
| 72 // a previous call to GetTraceBufferPercentFullAsync is pending; or | 77 // a previous call to GetTraceBufferPercentFullAsync is pending; or |
| 73 // the caller is not the current subscriber. | 78 // the caller is not the current subscriber. |
| 74 virtual bool GetTraceBufferPercentFullAsync(TraceSubscriber* subscriber) = 0; | 79 virtual bool GetTraceBufferPercentFullAsync(TraceSubscriber* subscriber) = 0; |
| (...skipping 20 matching lines...) Expand all Loading... |
| 95 virtual bool GetKnownCategoryGroupsAsync(TraceSubscriber* subscriber) = 0; | 100 virtual bool GetKnownCategoryGroupsAsync(TraceSubscriber* subscriber) = 0; |
| 96 | 101 |
| 97 protected: | 102 protected: |
| 98 virtual ~TraceController() {} | 103 virtual ~TraceController() {} |
| 99 }; | 104 }; |
| 100 | 105 |
| 101 } // namespace content | 106 } // namespace content |
| 102 | 107 |
| 103 #endif // CONTENT_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ | 108 #endif // CONTENT_PUBLIC_BROWSER_TRACE_CONTROLLER_H_ |
| 104 | 109 |
| OLD | NEW |