public BaseRepository(SocialMediaContext context) { _context = context; _entities = context.Set <T>(); }
public virtual async Task AddAsync(T t) { context.Set <T>().Add(t); await context.SaveChangesAsync(); }
public BaseRepository(SocialMediaContext _db) { db = _db; entities = db.Set <T>(); }
public BaseRepository(SocialMediaContext socialMediaContext) { this.socialMediaContext = socialMediaContext; entities = socialMediaContext.Set <T>(); }
public BaseRepository(SocialMediaContext socialMediaContext) { _socialMediaContext = socialMediaContext; _entities = _socialMediaContext.Set <T>(); }
public BaseRepository(SocialMediaContext context) { _context = context; _entities = context.Set <T>();//se genera un dbSet }