/// <summary> /// Returns a localized string conversion of a ScheduleRepeat value. /// </summary> /// <param name="repeatMode">Enum value to convert to string.</param> /// <returns>Localized version of enum value as a string.</returns> public static string ScheduleRepeatToString(ScheduleRepeat repeatMode) { switch (repeatMode) { case ScheduleRepeat.Second: return Gurux.DeviceSuite.Properties.Resources.SecondTxt; case ScheduleRepeat.Minute: return Gurux.DeviceSuite.Properties.Resources.MinuteTxt; case ScheduleRepeat.Hour: return Gurux.DeviceSuite.Properties.Resources.HourTxt; case ScheduleRepeat.Day: return Gurux.DeviceSuite.Properties.Resources.DailyTxt; case ScheduleRepeat.Month: return Gurux.DeviceSuite.Properties.Resources.MonthlyTxt; case ScheduleRepeat.Once: return Gurux.DeviceSuite.Properties.Resources.OnceTxt; case ScheduleRepeat.Week: return Gurux.DeviceSuite.Properties.Resources.WeeklyTxt; default: throw new Exception("ScheduleRepeatModeToString failed: Unknown ScheduleRepeat " + repeatMode.ToString()); } }
public Schedule(int id, ScheduleActions action, ScheduleDays day, TimeSpan time, ScheduleRepeat repeat, int status) { this.id = id; this.action = action; this.day = day; this.time = time; this.repeat = repeat; this.status = status; }
public Schedule(int id, ScheduleActions action, DateTime date, TimeSpan time, ScheduleRepeat repeat, int status) { this.id = id; this.action = action; this.date = date; this.time = time; this.repeat = repeat; this.status = status; }