コード例 #1
0
        public AddCategoryController(IAimCategoryService categoryService, IMapperAdapter mapper)
        {
            if (categoryService == null)
            {
                throw new ArgumentNullException("Category Service cannot be null");
            }

            if (mapper == null)
            {
                throw new ArgumentNullException("Mapper cannot be null");
            }

            this.categoryService = categoryService;
            this.mapper          = mapper;
        }
コード例 #2
0
        public ExploreController(IAimService aimService, IAimCategoryService categoryService, IMapperAdapter mapper)
        {
            if (aimService == null)
            {
                throw new ArgumentNullException("Aim Service cannot be null");
            }

            if (categoryService == null)
            {
                throw new ArgumentNullException("Category Service cannot be null");
            }

            if (mapper == null)
            {
                throw new ArgumentNullException("Mapper cannot be null");
            }

            this.aimService         = aimService;
            this.mapper             = mapper;
            this.aimCategoryService = categoryService;
        }
コード例 #3
0
        public AimController(
            IAimService aimService,
            ICountryService countryService,
            ICityService cityService,
            IAimCategoryService aimCategoryService,
            IMapperAdapter mapper)
        {
            if (aimService == null)
            {
                throw new ArgumentNullException("Aim Service cannot be null");
            }

            if (countryService == null)
            {
                throw new ArgumentNullException("Country Service cannot be null");
            }

            if (cityService == null)
            {
                throw new ArgumentNullException("City Service cannot be null");
            }

            if (aimCategoryService == null)
            {
                throw new ArgumentNullException("Category Service cannot be null");
            }

            if (mapper == null)
            {
                throw new ArgumentNullException("Mapper cannot be null");
            }

            this.aimService         = aimService;
            this.cityService        = cityService;
            this.countryService     = countryService;
            this.aimCategoryService = aimCategoryService;
            this.mapper             = mapper;
        }