Beispiel #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="name"></param>
        /// <param name="callType"></param>
        /// <param name="delay">延时</param>
        /// <param name="callback"></param>
        public static void Add(string name, TimerCallType callType, int delay, Action <TimerCallItem> callback)
        {
            TimerCallItem item = new TimerCallItem {
                Name = name, CallType = callType, Timestamp = DateTime.Now, Delay = delay, Callback = callback
            };

            Add(item);
        }
Beispiel #2
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="name"></param>
 /// <param name="callType"></param>
 /// <param name="delay">延时</param>
 /// <param name="callback"></param>
 public static void Add(string name, TimerCallType callType, int delay, Action<TimerCallItem> callback)
 {
     TimerCallItem item = new TimerCallItem { Name = name, CallType = callType, Timestamp = DateTime.Now, Delay = delay, Callback = callback };
     Add(item);
 }