public bool Start() { #if DEBUG return(true); #endif if (http.Login()) { SQ.Base.ThreadWhile <object> th = new ThreadWhile <object>(); th.SleepMs = 1000; th.Start(run, null, "MyTask"); return(true); } return(false); }
public void Start() { Stop(); ByteHelper.RegisterGBKEncoding(); if (!ReadConfig()) { Config = new ConfigModel(); } var len = 3; schRedis = new SQ.Base.Queue.Scheduler <RedisHelper>(len); schRedis.Tags = new RedisHelper[len]; for (int i = 0; i < len; i++) { schRedis.Tags[i] = new RedisHelper(); } schRedis.Start(); jTServer = new GW.JTServer(this); jTServer.Start(); thCheck = new ThreadWhile <object>(); thCheck.SleepMs = Config.ChkSckTimerInterval; thCheck.StartIfNotRun(Check, null, "CheckTh"); }