public static void ServiceStart() { ReplicatorThread.Start(); if (Environment.UserInteractive) { Console.WriteLine("send \"exit\" to quit:"); while (true) { var texto = Console.ReadLine(); if (texto == "exit") { ReplicatorThread.Stop(); break; } } } }
public static void ServiceStop() { ReplicatorThread.Stop(); }