OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CONTENT_RENDERER_RENDERING_BENCHMARK_H_ |
| 6 #define CONTENT_RENDERER_RENDERING_BENCHMARK_H_ |
| 7 |
| 8 #include <string> |
| 9 |
| 10 #include "base/basictypes.h" |
| 11 |
| 12 namespace WebKit { |
| 13 class WebViewBenchmarkSupport; |
| 14 } |
| 15 |
| 16 namespace content { |
| 17 class RenderingBenchmarkResults; |
| 18 |
| 19 class RenderingBenchmark { |
| 20 public: |
| 21 explicit RenderingBenchmark(const std::string& name); |
| 22 virtual ~RenderingBenchmark(); |
| 23 |
| 24 virtual void SetUp(WebKit::WebViewBenchmarkSupport* benchmarkSupport) {} |
| 25 |
| 26 virtual void Run(RenderingBenchmarkResults* results, |
| 27 WebKit::WebViewBenchmarkSupport* benchmarkSupport) = 0; |
| 28 |
| 29 virtual void TearDown(WebKit::WebViewBenchmarkSupport* benchmarkSupport) {} |
| 30 |
| 31 const std::string& name() { return name_; } |
| 32 |
| 33 private: |
| 34 const std::string name_; |
| 35 |
| 36 DISALLOW_COPY_AND_ASSIGN(RenderingBenchmark); |
| 37 }; |
| 38 } // namespace content |
| 39 #endif // CONTENT_RENDERER_RENDERING_BENCHMARK_H_ |
OLD | NEW |