public static OrmAccessor GetDbAcessor()
        {
            if(_accessor == null)
                _accessor = new OrmAccessor();
            
            return _accessor;

        }
Пример #2
0
        public static OrmAccessor GetDbAcessor()
        {
            if (_accessor == null)
            {
                _accessor = new OrmAccessor();
            }

            return(_accessor);
        }
Пример #3
0
 public static IDbProvider <T> GetDbProvider()
 {
     if (OrmAccessor.GetDbAcessor().DbType == OrmTypeConst.MSSQLSERVER)
     {
         return(new SQLServerProvider <T>());
     }
     if (OrmAccessor.GetDbAcessor().DbType == OrmTypeConst.ORACLE)
     {
         return(new OracleProvider <T>());
     }
     if (OrmAccessor.GetDbAcessor().DbType == OrmTypeConst.MSACCESS)
     {
         return(new AccessProvider <T>());
     }
     return(new SQLServerProvider <T>());
 }