enum EnergyCost { Low, Medium, High }

EnergyCost getEnergyCost(String? name) {
  for (EnergyCost value in EnergyCost.values) {
    if (value.name == name) {
      return value;
    }
  }
  return EnergyCost.Medium;
}
