Daily Measurements

@Serializable
data class DailyMeasurements(val id: String, val breakfast: Meal, val morningSnack: Meal, val lunch: Meal, val afternoonSnack: Meal, val dinner: Meal, val basalInsulin: BasalInsulin, var dailyNotes: String = "")

The DailyMeasurements data class represents the container of the daily measurements inserted by the user

Author

N7ghtm4r3 - Tecknobit

Parameters

id

The identifier of the measurements

breakfast

The breakfast measurement

morningSnack

The morning snack measurement

lunch

The lunch measurement

afternoonSnack

The afternoon snack measurement

dinner

The dinner measurement

basalInsulin

The basal insulin measurement

dailyNotes

The notes about the daily measurements

Constructors

Link copied to clipboard
constructor(id: String, breakfast: Meal, morningSnack: Meal, lunch: Meal, afternoonSnack: Meal, dinner: Meal, basalInsulin: BasalInsulin, dailyNotes: String = "")

Properties

Link copied to clipboard
@SerialName(value = "afternoon_snack" )
val afternoonSnack: Meal
Link copied to clipboard
@SerialName(value = "basal_insulin" )
val basalInsulin: BasalInsulin
Link copied to clipboard
Link copied to clipboard
@SerialName(value = "daily_notes" )
var dailyNotes: String
Link copied to clipboard
val dinner: Meal
Link copied to clipboard
val id: String
Link copied to clipboard
val lunch: Meal
Link copied to clipboard
@SerialName(value = "morning_snack" )
val morningSnack: Meal

Functions

Link copied to clipboard
fun getMealByType(type: MeasurementType): Meal

Method used to obtain the specific meal based on the type passed