public static int Register(Action value, TimeSpan period) { var timer = new System.Threading.Timer((e) => value.Invoke(), null, TimeSpan.Zero, period); RegisteredTimers.Add(timer.GetHashCode(), timer); return(timer.GetHashCode()); }
public static int Register(Action value, TimeSpan period) { var timer = new System.Threading.Timer((e) => value.Invoke(), null, TimeSpan.Zero, period); RegisteredTimers.Add(timer.GetHashCode(), timer); return(timer.GetHashCode()); }