| Index: tools/perf/metrics/timeline_based_metric.py
|
| diff --git a/tools/perf/metrics/timeline_based_metric.py b/tools/perf/metrics/timeline_based_metric.py
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..d0d208b8dc11e75ad730c6166e5346112aaeb5bf
|
| --- /dev/null
|
| +++ b/tools/perf/metrics/timeline_based_metric.py
|
| @@ -0,0 +1,21 @@
|
| +# Copyright 2014 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.
|
| +
|
| +class TimelineBasedMetric(object):
|
| + def __init__(self):
|
| + """Computes metrics from a telemetry.core.timeline Model and a range
|
| +
|
| + """
|
| + super(TimelineBasedMetric, self).__init__()
|
| +
|
| + def AddResults(self, model, renderer_thread,
|
| + metric_request, results):
|
| + """ Override to actually add metrics to the results. Metric that overrides
|
| + this method should only compute metric on the data between time_bound.
|
| +
|
| + model is a model of timeline APIT. (TODO: make a shared timeline superclass)
|
| + meric_request is an instance of TimelineBasedMetricRequest
|
| + results is an instance of page.PageTestResults.
|
| + """
|
| + raise NotImplementedError()
|
|
|