/// <summary> /// Adds a job to the timer to operate asyncronously. /// </summary> /// <param name="Schedule">The schedule that this delegate is to be run on.</param> /// <param name="f">The delegate to run</param> /// <param name="Params">The method parameters to pass if you leave any DateTime parameters unbound, then they will be set with the scheduled run time of the /// method. Any unbound object parameters will get this Job object passed in.</param> public void AddAsyncJob(IScheduledItem Schedule, string profileName, Delegate f, params object[] Params) { TimerJob Event = new TimerJob(Schedule, new DelegateMethodCall(f, Params), profileName); Event.SyncronizedEvent = false; _Jobs.Add(Event); }
public void AddAsyncReportEvent(IScheduledItem Schedule, int reportNo) { if (Elapsed == null) throw new Exception("You must set elapsed before adding Events"); TimerJob Event = new TimerJob(Schedule, new DelegateMethodCall(Handler, Elapsed, reportNo),ProfileName); Event.SyncronizedEvent = false; AddJob(Event); }
private void OnError(DateTime eventTime, TimerJob job, Exception e) { if (Error == null) { return; } try { Error(this, new ExceptionEventArgs(eventTime, e)); } catch (Exception) {} }
public void AddAsyncReportEvent(IScheduledItem Schedule, int reportNo) { if (Elapsed == null) { throw new Exception("You must set elapsed before adding Events"); } TimerJob Event = new TimerJob(Schedule, new DelegateMethodCall(Handler, Elapsed, reportNo), ProfileName); Event.SyncronizedEvent = false; AddJob(Event); }
public void Remove(TimerJob obj) { _List.Remove(obj); }
public void Add(TimerJob Event) { _List.Add(Event); }
/// <summary> /// Adds a job to the timer. /// </summary> /// <param name="Event"></param> public void AddJob(TimerJob Event) { _Jobs.Add(Event); }
private void OnError(DateTime eventTime, TimerJob job, Exception e) { if (Error == null) return; try { Error(this, new ExceptionEventArgs(eventTime, e)); } catch (Exception) {} }
/// <summary> /// Adds a job to the timer. /// </summary> /// <param name="Event"></param> public void AddJob(TimerJob Event) { _Jobs.Add(Event); }
/// <summary> /// Adds a job to the timer to operate asyncronously. /// </summary> /// <param name="Schedule">The schedule that this delegate is to be run on.</param> /// <param name="f">The delegate to run</param> /// <param name="Params">The method parameters to pass if you leave any DateTime parameters unbound, then they will be set with the scheduled run time of the /// method. Any unbound object parameters will get this Job object passed in.</param> public void AddAsyncJob(IScheduledItem Schedule,string profileName, Delegate f, params object[] Params) { TimerJob Event = new TimerJob(Schedule, new DelegateMethodCall(f, Params),profileName); Event.SyncronizedEvent = false; _Jobs.Add(Event); }
public void Remove(TimerJob obj) { _List.Remove(obj); }
public void Add(TimerJob Event) { _List.Add(Event); }