示例#1
0
 public virtual void SaveConfig(FXmlNode config)
 {
     // Type
     config[PTY_TYPE] = _type.ToString();
     config.Set(PTY_VALID, _valid);
     // Day config
     config.Set(PTY_DAY_INTERVAL, _dayInterval);
     // Week config
     config.Set(PTY_WEEK_INTERVAL, _weekInterval);
     config[PTY_WEEKDAYS] = ((int)_weekDays).ToString();
     // Month config
     config[PTY_MONTH_TYPE] = ((int)_monthType).ToString();
     config.Set(PTY_MONTH_INTERVAL, _monthInterval);
     config.Set(PTY_MONTH_DAY, _monthDay);
     config[PTY_MONTH_WEEK] = ((int)_monthWeek).ToString();
     config.Set(PTY_MONTH_WEEK_DAY, _monthWeekDay);
     config[PTY_MONTHS] = ((int)_months).ToString();
     // Once config
     config[PTY_ONCE_DATE] = RDate.Format(_onceDate, FMT_DATE);
     // Public config
     config[PTY_BEGIN_DATE] = RDate.Format(_beginDate, FMT_DATE);
     config.Set(PTY_END_VALID, _endValid);
     config[PTY_END_DATE] = RDate.Format(_endDate, FMT_DATE);
     config[PTY_TIME]     = RDate.Format(_time, FMT_TIME);
 }
示例#2
0
 public FScheduleTask CreateTask(EScheduleTaskType taskType)
 {
     return(CreateInstance <FScheduleTask>(FScheduleTask.NAME, taskType.ToString()));
 }