Inheritance: NFBehaviour
Beispiel #1
0
        public override void Init()
        {
            string strLibName = "NFKernelPlugin.dll";
            NFCDynLib xPlugin = new NFCDynLib(strLibName);

            mxPluginDic.TryAdd(strLibName, xPlugin);

            foreach(var x in mxPluginDic)
            {
                x.Value.Init();
            }
        }
Beispiel #2
0
        public override void Install()
        {
            XmlDocument xmldoc = new XmlDocument();

            xmldoc.Load("Plugin.xml");
            XmlNode xRoot = xmldoc.SelectSingleNode("XML");

            XmlNodeList xPluginNodeList = xRoot.SelectNodes("Plugin");

            for (int i = 0; i < xPluginNodeList.Count; ++i)
            {
                XmlNode      xNodeClass = xPluginNodeList.Item(i);
                XmlAttribute strID      = xNodeClass.Attributes["Name"];
                string       strLibName = strID.Value;

                NFCDynLib xDynLib = new NFCDynLib(strLibName, this);
                mxDynLibDic.TryAdd(strLibName, xDynLib);
            }

            ///////////////////////////////////////////////////////////

            XmlNode      xAPPIDNode = xRoot.SelectSingleNode("APPID");
            XmlAttribute strAppID   = xAPPIDNode.Attributes["Name"];

            mnAPPID = int.Parse(strAppID.Value);
            SetSelf(new NFGUID(mnAPPID, 0));

            XmlNode      xClassPathNode = xRoot.SelectSingleNode("ClassPath");
            XmlAttribute strClassPathID = xClassPathNode.Attributes["Name"];

            mstrClassPath = strClassPathID.Value;

            XmlNode      xAPPTypeNode = xRoot.SelectSingleNode("APPType");
            XmlAttribute strAPPType   = xAPPTypeNode.Attributes["Name"];

            mnAPPType = int.Parse(strAPPType.Value);
        }
Beispiel #3
0
        public override void Install()
        {
            XmlDocument xmldoc = new XmlDocument();
            xmldoc.Load("Plugin.xml");
            XmlNode xRoot = xmldoc.SelectSingleNode("XML");

            XmlNodeList xPluginNodeList = xRoot.SelectNodes("Plugin");
            for (int i = 0; i < xPluginNodeList.Count; ++i)
            {
                XmlNode xNodeClass = xPluginNodeList.Item(i);
                XmlAttribute strID = xNodeClass.Attributes["Name"];
                string strLibName = strID.Value;

                NFCDynLib xDynLib = new NFCDynLib(strLibName, this);
                mxDynLibDic.TryAdd(strLibName, xDynLib);
            }

            ///////////////////////////////////////////////////////////

            XmlNode xAPPIDNode = xRoot.SelectSingleNode("APPID");
            XmlAttribute strAppID = xAPPIDNode.Attributes["Name"];
            mnAPPID = int.Parse(strAppID.Value);
            SetSelf(new NFGUID(mnAPPID, 0));

            XmlNode xClassPathNode = xRoot.SelectSingleNode("ClassPath");
            XmlAttribute strClassPathID = xClassPathNode.Attributes["Name"];
            mstrClassPath = strClassPathID.Value;

            XmlNode xAPPTypeNode = xRoot.SelectSingleNode("APPType");
            XmlAttribute strAPPType = xAPPTypeNode.Attributes["Name"];
            mnAPPType = int.Parse(strAPPType.Value);
        }