public CocktailCommentsController(UserManager <User> userManager, IViewModelMapper <CocktailCommentDto, CocktailCommentViewModel> modelMapper, ICocktailCommentService cocktailCommentService, IToastNotification toastNotification) { this.userManager = userManager; this.modelMapper = modelMapper; this.cocktailCommentService = cocktailCommentService; this.toastNotification = toastNotification; }
public CocktailCommentController(ICocktailService cocktailService, IViewModelMapper <CocktailDto, CocktailViewModel> cocktailVmMapper, ICocktailCommentService cocktailCommentService, IViewModelMapper <CocktailCommentDto, CocktailCommentViewModel> cocktailCommentVmMapper, ICocktailRatingService cocktailRatingService) { this.cocktailService = cocktailService ?? throw new ArgumentNullException(nameof(cocktailService)); this.cocktailVmMapper = cocktailVmMapper ?? throw new ArgumentNullException(nameof(cocktailVmMapper)); this.cocktailCommentService = cocktailCommentService ?? throw new ArgumentNullException(nameof(cocktailCommentService)); this.cocktailCommentVmMapper = cocktailCommentVmMapper ?? throw new ArgumentNullException(nameof(cocktailCommentVmMapper)); this.cocktailRatingService = cocktailRatingService ?? throw new ArgumentNullException(nameof(cocktailRatingService)); }
public CocktailsController(ICocktailService cocktailService, IViewModelMapper <DetailsCocktailDto, DetailsCocktailViewModel> detailsCocktailVMMapper, IViewModelMapper <CocktailCommentDto, CocktailCommentViewModel> cocktailCommentVmMapper, IViewModelMapper <CocktailRatingDto, CocktailRatingViewModel> cocktailRatingVmMapper, IViewModelMapper <CocktailDto, CocktailViewModel> cocktailVmMapper, IViewModelMapper <BarDto, BarViewModel> barVmMapper, UserManager <User> userManager, ICocktailCommentService cocktailCommentService, ICocktailRatingService cocktailRatingService, IToastNotification toastNotification) { this.cocktailCommentVmMapper = cocktailCommentVmMapper ?? throw new ArgumentNullException(nameof(cocktailCommentVmMapper)); this.detailsCocktailVmMapper = detailsCocktailVMMapper ?? throw new ArgumentNullException(nameof(detailsCocktailVMMapper)); this.cocktailRatingVmMapper = cocktailRatingVmMapper ?? throw new ArgumentNullException(nameof(cocktailRatingVmMapper)); this.cocktailVMMapper = cocktailVmMapper ?? throw new ArgumentNullException(nameof(cocktailVmMapper)); this.barVmMapper = barVmMapper ?? throw new ArgumentNullException(nameof(barVmMapper)); this.userManager = userManager ?? throw new ArgumentNullException(nameof(userManager)); this.cocktailService = cocktailService ?? throw new ArgumentNullException(nameof(cocktailService)); this.cocktailCommentService = cocktailCommentService ?? throw new ArgumentNullException(nameof(cocktailCommentService)); this.cocktailRatingService = cocktailRatingService ?? throw new ArgumentNullException(nameof(cocktailRatingService)); this.toastNotification = toastNotification ?? throw new ArgumentNullException(nameof(toastNotification)); }