Beispiel #1
0
 private static void LoadAssembly(string[] fileArray, List <Assembly> assemblyList, List <string> cppdllList)
 {
     foreach (string file in fileArray)
     {
         try
         {
             if (PluginEngine.IsManagedAssembly(file))
             {
                 Assembly assembly = Assembly.LoadFrom(file);
                 assemblyList.Add(assembly);
             }
             else
             {
                 DllAPIWrap.LoadLibrary(file);
                 cppdllList.Add(file);
             }
         }
         catch (Exception ex)
         {
             LogConfig.Output.Error((object)("load managed dll failed. The file is " + file), ex);
         }
     }
 }
Beispiel #2
0
 private static void LoadAssembly(string[] fileArray, List <Assembly> assemblyList, List <string> cppdllList)
 {
     for (int i = 0; i < fileArray.Length; i++)
     {
         string text = fileArray[i];
         try
         {
             if (PluginEngine.IsManagedAssembly(text))
             {
                 Assembly item = Assembly.LoadFrom(text);
                 assemblyList.Add(item);
             }
             else
             {
                 DllAPIWrap.LoadLibrary(text);
                 cppdllList.Add(text);
             }
         }
         catch (Exception exception)
         {
             LogConfig.Output.Error("load managed dll failed. The file is " + text, exception);
         }
     }
 }