writeMeal method

Future<bool> writeMeal({
  1. double? caloriesConsumed,
  2. double? carbohydrates,
  3. double? protein,
  4. double? fatTotal,
  5. String? name,
  6. required MealType mealType,
  7. required DateTime start,
  8. required DateTime end,
})

Implementation

Future<bool> writeMeal({
  double? caloriesConsumed,
  double? carbohydrates,
  double? protein,
  double? fatTotal,
  String? name,
  required meal_types.MealType mealType,
  required DateTime start,
  required DateTime end,
}) {
  return health.writeMeal(
    startTime: start,
    endTime: end,
    caloriesConsumed: caloriesConsumed,
    carbohydrates: carbohydrates,
    protein: protein,
    fatTotal: fatTotal,
    name: name,
    mealType: mealType.toHealthMealType(),
  );
}