示例#1
0
        public EfDbSetWrapper(IEfDbContext efDbContext)
        {
            Guard.WhenArgument(efDbContext, "efDbContext").IsNull().Throw();

            this.efDbContext = efDbContext;

            this.dbSet = efDbContext.Set <T>();
        }
 internal EfRepositoryBase(IEfDbContext dbContext, ICachingStrategy <T, TKey> cachingStrategy = null) : base(cachingStrategy)
 {
     this.Context = dbContext;
     DbSet        = Context.Set <T>();
 }
 internal EfCompoundKeyRepositoryBase(IEfDbContext dbContext, ICompoundKeyCachingStrategy <T> cachingStrategy = null)
     : base(cachingStrategy)
 {
     Context = dbContext;
     DbSet   = Context.Set <T>();
 }