예제 #1
0
        public static bool doConfiguration()
        {
            Console.WriteLine("In server mode");
            string dllPath = PropertyUtil.getSelectedDllFile();
            Console.WriteLine("DLL File is : " + dllPath);
            DLLModel dLLAtHand = null;
            if (dllPath != null && dllPath.EndsWith(".dll"))
            {
                dLLAtHand = new DLLModel(dllPath);
                dLLAtHand = dLLAtHand.processDll(dLLAtHand);
            }
            else
            {
                Console.WriteLine("DLL Path information is not properly configured.");
                Environment.Exit(0);
            }

            dLLAtHand = DLLProcessor.populateComplexTypes(dLLAtHand);
            dLLAtHand = DLLProcessor.populateUserSelectedClassesAndMethods(dLLAtHand);

            Assembly assemblyAtHand = new ControllerGenerator().generateControllersAndDll(dLLAtHand);
            if (assemblyAtHand != null)
            {
                generatedAssemblyAtHand = assemblyAtHand;
                dLLAtHand.generateXml();
                return true;
            }

            return false;
        }
예제 #2
0
 public static void doUserInteraction()
 {
     Console.WriteLine("In User input mode");
     string dllPath = ConfigurationManager.AppSettings["dllFilePath"];
     Console.WriteLine("DLL File is : " + dllPath);
     if (dllPath != null && dllPath.EndsWith(".dll"))
     {
         DLLModel dLLAtHand = new DLLModel(dllPath);
         dLLAtHand = dLLAtHand.processDll(dLLAtHand);
         printOutClassesAndMethods(dLLAtHand);
     }
     else
     {
         Console.WriteLine("DLL Path information is not properly configured.");
     }
 }