private static void LoadFolder(string folder) { try { if (!loadedPlugins.ContainsKey(folder)) { PluginFinder pf = new PluginFinder(); ISubscriptionHandler plugin = pf.Search <ISubscriptionHandler>(folder, CheckType, ignoreList); if (plugin != null) { Type type = plugin.GetType(); PluginInfo pi = new PluginInfo(folder, type); LoadPlugin(pi, plugin); } } } catch (Exception ex) { // suppress any per-plugin loading exceptions Utility.WriteDebugInfo(String.Format("Plugin failed to load: '{0}' - {1} - {2}", folder, ex.Message, ex.StackTrace)); } }
public SubscriptionInfo(Type pSubType, Type pUnSubType, Type pNotifyType, ISubscriptionHandler pHandler) { SubType = pSubType; UnSubType = pUnSubType; NotifyType = pNotifyType; HandlerType = pHandler.GetType(); Handler = pHandler; }