measurementsByType method

Stream<Measurement> measurementsByType(
  1. String type
)

A stream of all measurements of a specific data type.

Implementation

Stream<Measurement> measurementsByType(String type) => measurements.where(
  (measurement) => measurement.data.dataType.toString() == type,
);