Abstract
Readonly
Abstract
idThe unique id of this MetricDataProvider (e.g. "main-metrics-csv" or "city-data-api"). This ID can be used from a MetricDataReference to indicate what provider should be used to fetch the data for a metric.
Fetches all of the data for the specified regions and metrics, optionally including timeseries metric data if available.
The fetched data for the specified regions and metrics.
One or more regions to fetch data for.
One or more metrics to fetch data for.
Whether to fetch timeseries data.
The metric catalog using this data provider. The data provider can call back into the catalog if it needs to fetch dependent data.
Abstract
transformTransforms sourceData
from the source metric to create the data for
newMetric
.
The transformed data.
The source data from the metric specified in the
sourceMetric
field of the metric's dataReference
.
The metric to generate transformed data for.
The region to generate data for.
Generated using TypeDoc
Base class to help implement a MetricDataProvider that provides data by transforming data from another existing metric. Implementers just need to set the
id
of the data provider and implement thetransformData()
method.Metrics that use the data provider should specify the source metric to be transformed via the
sourceMetric
field of thedataReference
field of the metric.Example