//Receive the messege from other components and perform required actions public void getMessege() { while (true) { CommMessage csndMsg1 = c.getMessage(); Console.WriteLine("Messege received"); csndMsg1.show(); if (csndMsg1.type.ToString() == "request") { csndMsg1.show(); string testRequest = csndMsg1.body; Console.WriteLine("Body is::" + testRequest); XMLHandler x = new XMLHandler(); string testRequestContent = File.ReadAllText("../../../THStorage/" + testRequest); x.loadXml(testRequestContent); List <string> testDrivers = x.parseList("tested"); foreach (string temp in testDrivers) { Console.WriteLine("TEMP:" + temp); requestFile(temp); } Thread.Sleep(2000); DllLoader d = new DllLoader(log.getFileName()); d.loadDlls(testDrivers); sendFile("../../../RepoStorage", "THLog.txt"); } } }
/*----< For test It will Load the dll file in THStorage/demo.dll>---------------------------*/ public static void Main(string[] args) { try { List <string> testList = new List <string>(); DllLoader d = new DllLoader("../../../RepoStorage/Test/TestFile.txt"); d.loadDll("../../../RepoStorage/Test/demo.dll"); } catch (Exception e) { Console.WriteLine("Exception Occured:" + e.Message); } }