public override bool ShutDownLogicSystem() { IsLogicEnd = true; LogicHandler.DestroyLogic(); return(true); }
public override bool CreateLogicSystem(LogicEntry logicEntry) { if (LogicHandler.Initialize(logicEntry) == false) { return(false); } IsLogicEnd = false; Task.Factory.StartNew(new Action(LogicThreadProcess)); Task.Factory.StartNew(new Action(RPCThreadProcess)); return(true); }
public void LogicThreadProcess() { while (IsLogicEnd == false) { LogicWait.WaitOne(); BasePacket packet; do { packet = LogicGateWay.PopPacket(); if (packet != null) { LogicHandler.ProcessPacket(packet); } } while (LogicGateWay.Count() != 0); } }