public PostersController(IPostersRepository repository) { _repository = repository; }
public PostersController(IPostersRepository postersRepository, IMapper mapper) { _postersRepository = postersRepository ?? throw new ArgumentNullException(nameof(postersRepository)); _mapper = mapper ?? throw new ArgumentNullException(nameof(mapper)); }
/// <summary> /// Initializes a new instance of the <see cref="PostersController"/> class. /// </summary> /// <param name="iPostersRepository">The postersRepository<see cref="IPostersRepository"/></param> /// <param name="iMapper">The mapper<see cref="IMapper"/></param> public PostersController(IPostersRepository iPostersRepository, IMapper iMapper) { this.postersRepository = iPostersRepository ?? throw new ArgumentNullException(nameof(iPostersRepository)); this.mapper = iMapper ?? throw new ArgumentNullException(nameof(iMapper)); }
public EventsController(IMapper mapper, IEventsRepository eventsRepo, IPostersRepository postersRepo) { _mapper = mapper; _eventsRepo = eventsRepo; _postersRepo = postersRepo; }