Exemple #1
0
        public QuestionService(IDatabaseSettings settings, ILogger <QuestionService> logger,
                               RecommendationService recommendationService)
        {
            var client   = new MongoClient(settings.ConnectionString);
            var database = client.GetDatabase(settings.DatabaseName);

            _questions             = database.GetCollection <Question>(settings.QuestionsCollectionName);
            _recommendationService = recommendationService;
            _logger = logger;
        }
 public QuestionRecommendation(UserService userService, RecommendationService recommendationService, ILogger <QuestionSimilarity> logger)
 {
     _userService           = userService;
     _recommendationService = recommendationService;
     _logger = logger;
 }