示例#1
0
		public static CarrotCMSDataContext Create(IDbConnection connection) {
#if DEBUG
			CarrotCMSDataContext _db = new CarrotCMSDataContext(connection);
			DataDiagnostic dd = new DataDiagnostic(_db, iDBConnCounter);
			iDBConnCounter++;
			if (iDBConnCounter > 4096) {
				iDBConnCounter = 0;
			}
			return _db;
#endif
			return new CarrotCMSDataContext(connection);
		}
示例#2
0
        public static CarrotCMSDataContext Create(IDbConnection connection)
        {
#if DEBUG
            CarrotCMSDataContext _db = new CarrotCMSDataContext(connection);
            DataDiagnostic       dd  = new DataDiagnostic(_db, iDBConnCounter);
            iDBConnCounter++;
            if (iDBConnCounter > 4096)
            {
                iDBConnCounter = 0;
            }
            return(_db);
#endif
            return(new CarrotCMSDataContext(connection));
        }