예제 #1
0
        public bool Toggle(IPCAgentPlugin plugin)
        {
            bool newValue = !this.PluginAvailability[plugin];

            this.PluginAvailability[plugin] = newValue;
            return(newValue);
        }
예제 #2
0
        public bool IsActive(IPCAgentPlugin plugin)
        {
            bool    blnIsActive = false;
            XmlNode xPlugin     = this._xDoc.SelectSingleNode("//Plugin[@name='" + plugin.GetType().FullName + "']");

            if (xPlugin != null)
            {
                blnIsActive = Convert.ToBoolean(xPlugin.InnerText);
            }
            return(blnIsActive);
        }
예제 #3
0
        public bool IsPartOfInterface(IPCAgentPlugin plugin, Type interfaceType)
        {
            XmlNode xPlugin = this._xDoc.SelectSingleNode("//Interface[@name='" + interfaceType.FullName + "']/Plugin[@name='" + plugin.GetType().FullName + "']");

            return(xPlugin != null);
        }
예제 #4
0
        public bool Toggle(string pluginAssemblyName)
        {
            IPCAgentPlugin plugin = this.PluginAvailability.Keys.FirstOrDefault(o => o.GetType().FullName == pluginAssemblyName);

            return(this.Toggle(plugin));
        }