public void createTimer() { CustomTimer timer = new CustomTimer(miliseconds); timer.Start(); timer.Elapsed += new ElapsedEventHandler(_timer_Elapsed_With_Result); timers.Add(timer); }
public void createTimer(CommandO command) { CustomTimer timer = new CustomTimer(command.timer, command.message); timer.Start(); timer.Elapsed += new ElapsedEventHandler(_timer_Elapsed); timers.Add(timer); }
public static UserO PermitUser(Dictionary <string, dynamic> parameters) { UserO user = (UserO)parameters["_user"]; user.isPermit = true; CustomTimer timer = new CustomTimer(120000, user); timer.Start(); timer.Elapsed += new ElapsedEventHandler(_timer_Elapsed); return(user); }