public PluginInfo(PluginController controller, AppDomain domain, PluginManifest manifest, string path) { this.controller = controller; this.domain = domain; this.manifest = manifest; this.path = path; }
private static void RegisterPlugin(string PluginFolder) { try { // load up the plugin manifest Log.Debug("Registering plugin at: " + PluginFolder); PluginManifest manifest = new PluginManifest(PluginFolder + "/manifest.xml"); // make sure the plugin id is unique if (plugins.ContainsKey(manifest.Id)) { Log.Warning("Plugin id '" + manifest.Id + "' already exists. Plugin at " + PluginFolder + "' will not be loaded."); return; } plugins[manifest.Id] = new PluginInfo(); plugins[manifest.Id].path = PluginFolder; plugins[manifest.Id].manifest = manifest; if (manifest.IsAutoStart) StartPlugin(manifest.Id); } catch (Exception e) { Log.Error(e); } }