Exemplo n.º 1
0
        public override string NHConfigParagraph()
        {
            string cfg = string.Empty;

            if (nhConfigSection == null)
            {
                LoadConfig();
            }
            ConfigurationSection_SQLSever cfgSec = nhConfigSection as ConfigurationSection_SQLSever;

            if (cfgSec != null)
            {
                byte[] pwd      = Convert.FromBase64String(cfgSec.Password);
                string password = Encoding.Unicode.GetString(pwd);
                cfg = string.Format(NHibernateConfigTemplate, cfgSec.Server, cfgSec.Database, string.Format(serverAuthenticationString, cfgSec.User, password) + string.Format("; Trusted_Connection={0}", cfgSec.TrustedConnection));
            }
            return(cfg);
        }
Exemplo n.º 2
0
        protected override DBConfigurationSection GetPlatformInstance()
        {
            ConfigurationSection_SQLSever instance = new ConfigurationSection_SQLSever();

            return(instance);
        }