コード例 #1
0
 public TagsController(ITagLibraryRepository tagLibraryRepository, IMapper mapper)
 {
     _tagLibraryRepository = tagLibraryRepository ??
                             throw new ArgumentNullException(nameof(tagLibraryRepository));
     _mapper = mapper ??
               throw new ArgumentNullException(nameof(mapper));
 }
コード例 #2
0
 public ArticlesController(IArticleLibraryRepository articleLibraryRepository, IMapper mapper, ITagLibraryRepository tagLibraryRepository)
 {
     _articleLibraryRepository = articleLibraryRepository ??
                                 throw new ArgumentNullException(nameof(articleLibraryRepository));
     _tagLibraryRepository = tagLibraryRepository ??
                             throw new ArgumentNullException(nameof(tagLibraryRepository));
     _mapper = mapper ??
               throw new ArgumentNullException(nameof(mapper));
 }