Chromium Code Reviews| Index: components/scheduler/renderer/renderer_task_duration.h |
| diff --git a/components/scheduler/renderer/renderer_task_duration.h b/components/scheduler/renderer/renderer_task_duration.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..0fae8700de35c236796eea917af18e6f431f0383 |
| --- /dev/null |
| +++ b/components/scheduler/renderer/renderer_task_duration.h |
| @@ -0,0 +1,22 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef COMPONENTS_SCHEDULER_RENDERER_RENDERER_TASK_DURATION_H_ |
| +#define COMPONENTS_SCHEDULER_RENDERER_RENDERER_TASK_DURATION_H_ |
| + |
| +#include "base/time/time.h" |
| + |
| +namespace scheduler { |
| +class RendererTaskDuration { |
|
majidvp
2016/07/27 13:50:59
I think the convention is to have a blank line bef
majidvp
2016/07/27 13:50:59
I think a better name may be a TaskDurationReporte
sunyunjia
2016/07/27 17:28:42
Done.
sunyunjia
2016/07/27 17:28:42
Done.
|
| + public: |
| + RendererTaskDuration(); |
| + ~RendererTaskDuration(); |
| + void ReportSampleDuration(base::TimeDelta duration); |
| + static const int kSampleInterval = 100; |
|
majidvp
2016/07/27 13:50:59
This constant does not need to be public. Please m
sunyunjia
2016/07/27 17:28:43
Done.
|
| + private: |
| + int sample_count_; |
| +}; |
|
majidvp
2016/07/27 13:50:59
This class is not meant to be copies/moved so plea
sunyunjia
2016/07/27 17:28:42
Done.
|
| +} |
| + |
| +#endif // COMPONENTS_SCHEDULER_RENDERER_RENDERER_TASK_DURATION_H_ |