예제 #1
0
 public bool AttachAddIn(string dllPath, string name = "", NativeApiEnums type = NativeApiEnums.OneScript)
 {
     if (type == NativeApiEnums.OneScript)
     {
         var assembly = System.Reflection.Assembly.LoadFrom(dllPath);
         EngineInstance.AttachExternalAssembly(assembly, EngineInstance.Environment);
         return(true);
     }
     else
     {
         if (!Utils.IsValidIdentifier(name))
         {
             throw RuntimeException.InvalidArgumentValue(name);
         }
         return(NativeApiFactory.Register(dllPath, name));
     }
 }
예제 #2
0
        public void AttachAddIn(string dllPath)
        {
            var assembly = System.Reflection.Assembly.LoadFrom(dllPath);

            EngineInstance.AttachExternalAssembly(assembly, EngineInstance.Environment);
        }