RecurrenceValues GetRecurrenceValues() { RecurrenceValues values = null; switch (RegenType) { case DailyRegenType.OnEveryXDays: values = GetEveryXDaysValues(); break; case DailyRegenType.OnEveryWeekday: values = GetEveryWeekday(); break; } // Values will be null if just getting next date in series. No need // to fill the RecurrenceValues collection if all we need is the last date. if (values != null) { if (values.Values.Count > 0) { values.SetStartDate(values.Values[0]); // Get the end date if not open-ended if (base.TypeOfEndDate != EndDateType.NoEndDate) { values.SetEndDate(values.Values[values.Values.Count - 1]); } } // Set the Series information that's used to get the next date // values for no ending dates. values.SetSeriesInfo(GetSeriesInfo()); } return(values); }
RecurrenceValues GetRecurrenceValues() { RecurrenceValues values = null; switch (RegenType) { case MonthlyRegenType.OnSpecificDayOfMonth: values = GetSpecificDayOfMonthDates(); break; case MonthlyRegenType.OnCustomDateFormat: values = GetCustomDayOfMonthDates(); break; case MonthlyRegenType.AfterOccurrenceCompleted: break; } if (values.Values.Count > 0) { values.SetStartDate(values.Values[0]); // Get the end date if not open-ended if (base.TypeOfEndDate != EndDateType.NoEndDate) { values.SetEndDate(values.Values[values.Values.Count - 1]); } } // Set the Series information that's used to get the next date // values for no ending dates. values.SetSeriesInfo(GetSeriesInfo()); return(values); }
RecurrenceValues GetRecurrenceValues() { RecurrenceValues values = null; switch (RegenType) { case WeeklyRegenType.OnEveryXWeeks: values = GetEveryXWeeksValues(); break; } if (values.Values.Count > 0) { values.SetStartDate(values.Values[0]); // Get the end date if not open-ended if (base.TypeOfEndDate != EndDateType.NoEndDate) { values.SetEndDate(values.Values[values.Values.Count - 1]); } } // Set the Series information that's used to get the next date // values for no ending dates. values.SetSeriesInfo(GetSeriesInfo()); return(values); }