private void setAdapter(XmlDocument xDoc) { if (xDoc == null) { return; } if (_adapter != null) { return; } var xNodeConnection = xDoc.SelectSingleNode("//appConfig/defaultConnectionString"); if (xNodeConnection == null) { return; } string sConnectionString = xNodeConnection.InnerText; string sConnectionType = xNodeConnection.getXmlAttributeValue("type"); _adapter = adapter.utility.createAdapter(sConnectionType, sConnectionString); /* * oAssembly.appServerRootPath = appServerInfo.appServerRootPath; * oAssembly.appName = appServerInfo.appName; * oAssembly.loadDll(xDoc); */ }
public clsBussinessTierFromXmlBase(clsAppServerBase appServerInfo) { _appServerInfo = appServerInfo; //_AppConfigFolderPath = appServerInfo.getAppConfigFolder(); xDoc = getXmlDoc(appServerInfo.getAppConfigFilePath()); var xNodeConnection = xDoc.SelectSingleNode("//appConfig/defaultConnectionString"); string sConnectionString = xNodeConnection.InnerText; string sConnectionType = xNodeConnection.Attributes["type"].Value; _adapter = adapter.utility.createAdapter(sConnectionType, sConnectionString); oAssembly.appServerRootPath = appServerInfo.appServerRootPath; oAssembly.appName = appServerInfo.appName; oAssembly.loadDll(xDoc); }