#include "stdafx.h" #include "ConsoleThread.h" #include #include #include #include #include #include "CDI.h" #include "cdi.h" #include "LocalConfig.h" #include "PacketAnalizer.h" ConsoleThread::ConsoleThread() { counter = 0; DoMLoop = false; } void ConsoleThread::RunCmdInput() { int ch = 0; string inputstr; if (cin.peek() == EOF) { return; } getline(cin, inputstr); GetCommandDispathIF()->CommandInput(inputstr.c_str()); return; } ConsoleThread::~ConsoleThread() { } bool ConsoleThread::Exec() { //Sleep(3000); if (DoMLoop == false && WaitTheThreadEndSign(100) == false) { RunCmdInput(); return true; } if (WaitTheThreadEndSign(100) == false) { RunCmdInput(); return true; } return false; } bool ConsoleThread::OnEndThread() { return true; } bool ConsoleThread::OnStartThread() { return true; }