getHealthMeasure static method
Returns a health measure for the specified list of health data types
.
Data will be collected days
days back in time. If not specified,
data will be collected for the last 30 days, which is the maximum
that Google Health Connect allow.
Implementation
static Measure getHealthMeasure(List<HealthDataType> types,
[int days = 30]) =>
Measure(type: HealthSamplingPackage.HEALTH)
..overrideSamplingConfiguration = HealthSamplingConfiguration(
past: Duration(days: days), healthDataTypes: types);