Python: module telemetry.internal.results.json_output_formatter

telemetry.internal.results.json_output_formatter | index telemetry/internal/results/json_output_formatter.py

`# 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.`

Modules
`` |  |
json | telemetry.internal.results.output_formatter |  |

Classes
`` |  | telemetry.internal.results.output_formatter.OutputFormatter(__builtin__.object) JsonOutputFormatter
class JsonOutputFormatter(telemetry.internal.results.output_formatter.OutputFormatter)
`` |  | Method resolution order: JsonOutputFormatter telemetry.internal.results.output_formatter.OutputFormatter __builtin__.object Methods defined here: Format(self, page_test_results) __init__(self, output_stream, benchmark_metadata) Data descriptors defined here: benchmark_metadata Data descriptors inherited from telemetry.internal.results.output_formatter.OutputFormatter: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)` output_stream

Functions
`` |  | ResultsAsDict(page_test_results, benchmark_metadata) `Takes PageTestResults to a dict serializable to JSON. To serialize results as JSON we first convert them to a dict that can be serialized by the json module. It also requires a benchmark_metadat object for metadata to be integrated into the results (currently the benchmark name). This function will also output trace files if they exist. Args: page_test_results: a PageTestResults object benchmark_metadata: a benchmark.BenchmarkMetadata object`