Exemple #1
0
 public SqlSugarClient(ConnectionConfig config)
 {
     Check.Exception(config == null, "ConnectionConfig config is null");
     InitContext(config);
 }
Exemple #2
0
        public static ISugarQueryable <T, T2, T3, T4, T5, T6, T7> GetQueryable <T, T2, T3, T4, T5, T6, T7>(ConnectionConfig currentConnectionConfig)
        {
            string className = "Queryable";

            className = GetClassName(currentConnectionConfig.DbType.ToString(), className);
            ISugarQueryable <T, T2, T3, T4, T5, T6, T7> result = CreateInstance <T, T2, T3, T4, T5, T6, T7, ISugarQueryable <T, T2, T3, T4, T5, T6, T7> >(className);

            return(result);
        }
Exemple #3
0
        public static ICodeFirst GetCodeFirst(ConnectionConfig currentConnectionConfig)
        {
            ICodeFirst result = CreateInstance <ICodeFirst>(GetClassName(currentConnectionConfig.DbType.ToString(), "CodeFirst"));

            return(result);
        }
Exemple #4
0
        public static IDbMaintenance GetDbMaintenance(ConnectionConfig currentConnectionConfig)
        {
            IDbMaintenance result = CreateInstance <IDbMaintenance>(GetClassName(currentConnectionConfig.DbType.ToString(), "DbMaintenance"));

            return(result);
        }
Exemple #5
0
        public static DeleteBuilder GetDeleteBuilder(ConnectionConfig currentConnectionConfig)
        {
            DeleteBuilder result = CreateInstance <DeleteBuilder>(GetClassName(currentConnectionConfig.DbType.ToString(), "DeleteBuilder"));

            return(result);
        }
Exemple #6
0
        public static InsertBuilder GetInsertBuilder(ConnectionConfig currentConnectionConfig)
        {
            InsertBuilder result = CreateInstance <InsertBuilder>(GetClassName(currentConnectionConfig.DbType.ToString(), "InsertBuilder"));

            return(result);
        }