B2G/gecko/services/metrics/dataprovider.jsm
/**
   * Add a `MetricsMeasurement` to this result.
   */
Add a `MetricsMeasurement` to this result.
Add a ` MetricsMeasurement ` to this result .
function addMeasurement(data) {
    if (!(data instanceof MetricsMeasurement)) {
      throw new Error("addMeasurement expects a MetricsMeasurement instance.");
    }
    if (!this.expectedMeasurements.has(data.name)) {
      throw new Error("Not expecting this measurement: " + data.name);
    }
    if (this.measurements.has(data.name)) {
      throw new Error("Measurement of this name already present: " + data.name);
    }
    this.measurements.set(data.name, data);
  }
function addMeasurement ( data ) { if ( ! ( data instanceof MetricsMeasurement ) ) { throw new Error ( "addMeasurement expects a MetricsMeasurement instance." ) ; } if ( ! this . expectedMeasurements . has ( data . name ) ) { throw new Error ( "Not expecting this measurement: " + data . name ) ; } if ( this . measurements . has ( data . name ) ) { throw new Error ( "Measurement of this name already present: " + data . name ) ; } this . measurements . set ( data . name , data ) ; }
Add a `MetricsMeasurement` to this result.
Add a ` MetricsMeasurement ` to this result .