toFrequency method

Frequency toFrequency()

Implementation

Frequency toFrequency() {
  switch (this) {
    case 'ONCE':
      return Frequency.once;
    case 'HOURLY':
      return Frequency.hourly;
    case 'DAILY':
      return Frequency.daily;
    case 'WEEKLY':
      return Frequency.weekly;
    case 'MONTHLY':
      return Frequency.monthly;
    case 'EVENT':
      return Frequency.event;
  }
  throw Exception('$this is not known in enum Frequency');
}