Example #1
0
 public UnitOfWork(GoodNewsContext goodNewsContext,
                   IRepository <News> newsRepository,
                   IRepository <Magazine> magazineRepository)
 {
     _goodNewsContext   = goodNewsContext;
     NewsRepository     = newsRepository;
     MagazineRepository = magazineRepository;
 }
 public UnitOfWork(GoodNewsContext context,
                   IRepository <Article> news,
                   IRepository <Source> sources,
                   IRepository <Comment> comments,
                   IRepository <Category> categories)
 {
     _context              = context;
     _newsRepository       = news;
     _categoriesRepository = categories;
     _sourcesRepository    = sources;
     _commentsRepository   = comments;
 }
Example #3
0
 public NewsController(GoodNewsContext gNC)
 {
     goodNewsContext = gNC;
     allnews         = new List <News>()
     {
         new News()
         {
         },
         new News()
         {
         },
         new News()
         {
         },
         new News()
         {
         }
     };
 }
Example #4
0
 public AddRangeNewsHandler(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
Example #5
0
 public Repository(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
     _dbset           = _goodNewsContext.Set <T>();
 }
 public UpdateSourceHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #7
0
 public ArticleRepository(GoodNewsContext _context) : base(_context)
 {
 }
Example #8
0
 public GetSourceByIdHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #9
0
 public Storage(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
Example #10
0
 public AddSourceHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #11
0
 public CategoryRepository(GoodNewsContext _context) : base(_context)
 {
 }
Example #12
0
 public UpdateNewsHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #13
0
 public SourceRepository(GoodNewsContext _context) : base(_context)
 {
 }
Example #14
0
 public GetCommentByIdHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #15
0
 public MagazineRepository(GoodNewsContext goodNewsContext) : base(goodNewsContext)
 {
 }
 public AddNewsAsyncHandler(GoodNewsContext context)
 {
     _context = context;
 }
 public GetArticleByIdHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #18
0
 public WorksController(GoodNewsContext context, IMapper mapper)
 {
     this.context = context;
     this.mapper  = mapper;
 }
Example #19
0
 public GetNewsByIdHandler(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
Example #20
0
 public GetCommentsByArticleIdHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #21
0
 public GetAllNewsHandler(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
 public AddCommentHandler(GoodNewsContext context)
 {
     _context = context;
 }
 public CommentRepository(GoodNewsContext context) : base(context)
 {
 }
 public CitiesController(GoodNewsContext context, IMapper mapper)
 {
     _context    = context;
     this.mapper = mapper;
 }
Example #25
0
 public ArticleExistsHandler(GoodNewsContext context)
 {
     _context = context;
 }
 public DeleteSourceHandler(GoodNewsContext context)
 {
     _context = context;
 }
 public UpDateRefreshTokenHandler(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
Example #28
0
 public DBInitializer(GoodNewsContext goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }
 public AddNewsAndCategoriesHandler(GoodNewsContext context)
 {
     _context = context;
 }
Example #30
0
 public NewsRepository(GoodNewsContext goodNewsContext) : base(goodNewsContext)
 {
     _goodNewsContext = goodNewsContext;
 }