示例#1
0
 public static void Handler(String[] Data)
 {
     if (Data.Length == 0)
     {
         return;
     }
     if (Data[0] == "Bounds")
     {
         foreach (Char C in Data[1])
         {
             LBound.Add(C.ToString());
         }
         foreach (Char C in Data[2])
         {
             UBound.Add(C.ToString());
         }
         FinderHandler.StartAt = LBound;
         FinderHandler.EndAt   = UBound;
         LBound = new List <string> {
         };
         UBound = new List <string> {
         };
         NetworkHandler.SendMessage(new List <string> {
             "Hello"
         });
     }
     if (Data[0] == "ResetBounds")
     {
         FinderHandler.IsRunning = false;
         while (FinderHandler.T.IsAlive)
         {
         }
         foreach (Char C in Data[1])
         {
             LBound.Add(C.ToString());
         }
         foreach (Char C in Data[2])
         {
             UBound.Add(C.ToString());
         }
         FinderHandler.StartAt = LBound;
         FinderHandler.EndAt   = UBound;
         LBound = new List <string> {
         };
         UBound = new List <string> {
         };
         FinderHandler.Start();
     }
     if (Data[0] == "Restart" || Data[0] == "Start")
     {
         FinderHandler.IsRunning = false;
         FinderHandler.Start();
     }
 }
示例#2
0
 public static void OnControlEvent(ConsoleEvent consoleEvent)
 {
     FinderHandler.Terminate(null, null);
 }