예제 #1
0
 public static void PreLoadMainPlugins(IPluginContext mainPluginContext)
 {
     if (null != mainPluginContext)
     {
         PluginConfig pluginConfig = new PluginConfig(mainPluginContext);
         pluginConfig.PreLoadPlugins();
     }
 }
예제 #2
0
        public static IList<PluginConfigItem> LoadPlugin(IPluginContext parentProgram)
        {
            PluginConfig pluginConfig = new PluginConfig(parentProgram);

            if (configs.ContainsKey(parentProgram))
                pluginConfig = configs[parentProgram];
            else
                configs[parentProgram] = pluginConfig;

            return pluginConfig.LoadPlugIn();
        }
예제 #3
0
 public static IDictionary<string, string> GetCategoryUrlList(IPluginContext context, string category)
 {
     if (null != context)
     {
         PluginConfig pluginConfig = new PluginConfig(context);
         bool inited = pluginConfig.InitPluginParser();
         if (inited)
         {
             return PluginConfigParser.GetCategoryUrlList(category);
         }
         throw new ArgumentException("Please check PluginConfig.xml.");
     }
     throw new ArgumentException("context != null");
 }