/// <summary> /// Initializes a new instance of the <see cref="KnowledgeBasesController"/> class. /// </summary> /// <param name="kbReader">The knowledge base reader.</param> /// <param name="kbWriter">The knowledge base writer.</param> /// <param name="authorizationService">AuthZ service.</param> public KnowledgeBasesController( IKnowledgeBaseReader kbReader, IKnowledgeBaseWriter kbWriter, IAuthorizationService authorizationService) { this.kbReader = kbReader ?? throw new ArgumentNullException(nameof(kbReader)); this.kbWriter = kbWriter ?? throw new ArgumentNullException(nameof(kbWriter)); this.authorizationService = authorizationService ?? throw new ArgumentNullException(nameof(authorizationService)); }
/// <summary> /// Initializes a new instance of the <see cref="UsersController"/> class. /// </summary> /// <param name="courseReader">Course Reader.</param> /// <param name="questionReader">Question reader.</param> /// <param name="userProfileService">User profile service.</param> /// <param name="authorizationService">AuthZ service.</param> /// <param name="authorizationSettings">Auth settings.</param> /// <param name="kbReader">The knowledge base reader.</param> /// <param name="logger">Logger.</param> public UsersController( ICourseReader courseReader, IQuestionReader questionReader, IUserReaderService userProfileService, IAuthorizationService authorizationService, AuthorizationSettings authorizationSettings, IKnowledgeBaseReader kbReader, ILogger <UsersController> logger) { this.courseReader = courseReader ?? throw new ArgumentNullException(nameof(courseReader)); this.questionReader = questionReader ?? throw new ArgumentNullException(nameof(questionReader)); this.userReaderService = userProfileService ?? throw new ArgumentNullException(nameof(userProfileService)); this.authorizationService = authorizationService ?? throw new ArgumentNullException(nameof(authorizationService)); this.authorizationSettings = authorizationSettings ?? throw new ArgumentNullException(nameof(authorizationSettings)); this.kbReader = kbReader ?? throw new ArgumentNullException(nameof(kbReader)); this.logger = logger ?? throw new ArgumentNullException(nameof(logger)); }