Beispiel #1
0
 public ActionManager(IKeywordService keywordService, IActionCollection actions, IActionContext context)
 {
     _context        = context;
     _actions        = actions;
     _logger         = _context.Log;
     _keywordService = keywordService;
 }
Beispiel #2
0
 public AnswerService(triagingDBContext db, IQuestionService quesServ, IAlogrithmService algoServ, IKeywordService keywordServ)
 {
     _db          = db;
     _quesServ    = quesServ;
     _algoServ    = algoServ;
     _keywordServ = keywordServ;
 }
Beispiel #3
0
 public KeywordController(IKeywordService keywordService, IMapper mapper, INewsService newsService, ISourceService sourceService)
 {
     _mapper             = mapper;
     this.keywordService = keywordService;
     this.newsService    = newsService;
     this.sourceService  = sourceService;
 }
Beispiel #4
0
        public KeywordPresenter(IMainView main, IKeywordService service, IKeywordView view)
        {
            this._main    = main;
            this._service = service;
            this._view    = view;

            _view.RakeClick     += _view_RakeClick;
            _view.StanfordClick += _view_StanfordClick;
        }
 public CollectNewsByKeywordHelper(ILogger <CollectNewsByKeywordHelper> logger, ISourceService sourceService, IKeywordService keywordService, INewsService newsService, INewsKeywordService newsKeywordService, IHttpClientFactory httpClientFactory)
 {
     _logger             = logger;
     _sourceService      = sourceService;
     _keywordService     = keywordService;
     _newsService        = newsService;
     _newsKeywordService = newsKeywordService;
     _httpClientFactory  = httpClientFactory;
 }
 public KeywordsController(IKeywordService keywordService,
                           IEnumMappingService enumMappingService,
                           IAuthorizationService authorizationService)
     : base(authorizationService, enumMappingService)
 {
     _keywordService       = keywordService;
     _enumMappingService   = enumMappingService;
     _authorizationService = authorizationService;
 }
 public NewsController(INewsService newsService, IMapper mapper, ISourceService sourceService, IKeywordService keywordService, IHttpClientFactory httpClientFactory, IUriService uriService)
 {
     this._mapper         = mapper;
     this._newsService    = newsService;
     this._sourceService  = sourceService;
     this._keywordService = keywordService;
     _httpClientFactory   = httpClientFactory;
     _uriService          = uriService;
 }
Beispiel #8
0
        public void TestAll()
        {
            IKeywordService service = UnitOfWork.GetService <IKeywordService>();
            IServiceQueryResultList <KeywordData> result = service.GetAll();
            List <KeywordData> list = result.DataList.ToList();

            if (list != null)
            {
            }
        }
        public static Task <Keyword?[]> GetKeywords(this IKeywordService service, IEnumerable <string> ids)
        {
            List <Task <Keyword?> > posts = new List <Task <Keyword?> >();

            foreach (var id in ids)
            {
                posts.Add(service.Get(id));
            }
            return(Task.WhenAll(posts.ToArray()));
        }
 public PimBotServiceProvider(
     IItemService itemservice,
     IKeywordService keywordService,
     IFeatureService featureService,
     ICategoryService categoryService)
 {
     ItemService     = itemservice;
     FeatureService  = featureService;
     IKeywordService = keywordService;
     CategoryService = categoryService;
 }
        public KeywordServiceTests()
        {
            _dbContextMock          = new Mock <SearchAggregatorContext>();
            _keywordRepositoryMock  = new Mock <IKeywordRepository>();
            _resourceRepositoryMock = new Mock <IResourceRepository>();

            Profile myProfile = new AutoMapperProfile();
            var     mapper    = new Mapper(new MapperConfiguration(cfg => cfg.AddProfile(myProfile)));

            _service = new KeywordService(_keywordRepositoryMock.Object, _resourceRepositoryMock.Object, _dbContextMock.Object, mapper);
        }
Beispiel #12
0
 public BlogController(
     IUserService usersService,
     IArticleService articlesService,
     IKeywordService keywordsService,
     IMemoryCache cache,
     IMapper mapper)
 {
     this.usersService    = usersService;
     this.articlesService = articlesService;
     this.keywordsService = keywordsService;
     this.cache           = cache;
     this.mapper          = mapper;
 }
Beispiel #13
0
 public ItemService(
     IItemRepository itemRepository,
     IFeatureService featureService,
     IKeywordService keywordService,
     ICategoryService categoryService,
     IPictureRepository pictureRepository)
 {
     _itemRepository    = itemRepository;
     _featuresService   = featureService;
     _keywordService    = keywordService;
     _categoryService   = categoryService;
     _pictureRepository = pictureRepository;
 }
 public SQLiteDatabaseService(IKeywordService keywordService,
                              ILogService log,
                              IKeywordService reservedKeywordService,
                              IPluginManager pluginManager,
                              IConnectionStringManager csm
                              )
 {
     _pluginManager          = pluginManager;
     _reservedKeywordService = reservedKeywordService;
     _log = log;
     _connectionString = csm.Get();
     _keywordService   = keywordService;
 }
Beispiel #15
0
        internal List <TDto> RetrieveAll <TDto>(IDataConverter <KeywordData, TDto> converter)
            where TDto : class
        {
            ArgumentValidator.IsNotNull("converter", converter);
            IKeywordService service = UnitOfWork.GetService <IKeywordService>();

            var query = service.GetAll();

            if (query.HasResult)
            {
                return(query.DataToDtoList(converter).ToList());
            }

            return(null);
        }
Beispiel #16
0
        public static async Task <IEnumerable <Keyword> > GetData(this IKeywordService service, IEnumerable <string> ids)
        {
            List <Keyword> result = new List <Keyword>();

            foreach (var id in ids)
            {
                var item = await service.Get(id);

                if (item != null)
                {
                    result.Add(item);
                }
            }
            return(result);
        }
Beispiel #17
0
 public ValuesController(IMediator mediator,
                         IHttpContextAccessor accessor,
                         IValidator validator,
                         IMapper mapper,
                         IKeywordService keywordService,
                         ICacheService cacheService,
                         IRestApiCuaNha apiCuaNha)
 {
     this.mediator       = mediator;
     this.accessor       = accessor;
     this.validator      = validator;
     this.mapper         = mapper;
     this.keywordService = keywordService;
     this.cacheService   = cacheService;
     this.apiCuaNha      = apiCuaNha;
 }
Beispiel #18
0
        internal IEnumerable <BindingListItem> GetBindingList()
        {
            List <BindingListItem> dataSource = new List <BindingListItem>();
            IKeywordService        service    = UnitOfWork.GetService <IKeywordService>();
            var query = service.GetAll();

            if (query.HasResult)
            {
                foreach (KeywordData data in query.DataList)
                {
                    dataSource.Add(new BindingListItem(data.Id, data.Name));
                }
            }

            return(dataSource);
        }
Beispiel #19
0
 public GeneralInformationController(
     IGeneralInformationService generalInformationService,
     ISearchService searchService,
     ICatalogService catalogService,
     IAuthorizationService authorizationService,
     IEnumMappingService enumMappingService,
     IKeywordService keywordService,
     ICacheStorageService cacheStorageService)
     : base(authorizationService, enumMappingService)
 {
     _authorizationService      = AuthorizationServiceFactory.Current;
     _searchService             = searchService;
     _generalInformationService = generalInformationService;
     _catalogService            = catalogService;
     _enumMappingService        = enumMappingService;
     _keywordService            = keywordService;
     _cacheStorageService       = cacheStorageService;
 }
 public BrainRetrievalCommand(
     string commandSource,
     IUser user,
     IList <string> arguments,
     ILogger logger,
     IFlagService flagService,
     IConfigurationProvider configurationProvider,
     IIrcClient client,
     IKeywordService keywordService) : base(
         commandSource,
         user,
         arguments,
         logger,
         flagService,
         configurationProvider,
         client)
 {
     this.keywordService = keywordService;
 }
Beispiel #21
0
 public ForgetCommand(
     string commandSource,
     IUser user,
     IList <string> arguments,
     ILogger logger,
     IFlagService flagService,
     IConfigurationProvider configurationProvider,
     IIrcClient client,
     IKeywordService keywordService,
     IResponder responder) : base(
         commandSource,
         user,
         arguments,
         logger,
         flagService,
         configurationProvider,
         client)
 {
     this.keywordService = keywordService;
     this.responder      = responder;
 }
Beispiel #22
0
        public SearchController(SearchService customSearchService, IKeywordService keywordService, IConfiguration configuration)
        {
            _customSearchService = customSearchService;
            _keywordService      = keywordService;
            _configuration       = configuration;

            customSearchService.AddSearcher(new YandexCustomSeacher(
                                                _configuration["YandexSearch:SubscriptionKey"],
                                                _configuration["YandexSearch:UserName"],
                                                new HttpClientHandler()
                                                ));
            customSearchService.AddSearcher(new GoogleCustomSearcher(
                                                _configuration["GoogleSearch:SubscriptionKey"],
                                                _configuration["GoogleSearch:ConfigID"],
                                                new GoogleCustomsearchServiceHandler()
                                                ));
            customSearchService.AddSearcher(new BingCustomSeacher(
                                                _configuration["BingSearch:SubscriptionKey"],
                                                _configuration["BingSearch:ConfigID"],
                                                new HttpClientHandler()
                                                ));
        }
 public KeywordValidator(IKeywordService keywordService)
 {
     _keywordService = keywordService;
 }
Beispiel #24
0
 /// <summary>
 /// Initialises a new instance of the <see cref="Forget"/> class.
 /// </summary>
 /// <param name="source">
 /// The source.
 /// </param>
 /// <param name="channel">
 /// The channel.
 /// </param>
 /// <param name="args">
 /// The args.
 /// </param>
 /// <param name="commandServiceHelper">
 /// The message Service.
 /// </param>
 public Forget(LegacyUser source, string channel, string[] args, ICommandServiceHelper commandServiceHelper)
     : base(source, channel, args, commandServiceHelper)
 {
     // FIXME: ServiceLocator - keywordservice
     this.keywordService = ServiceLocator.Current.GetInstance<IKeywordService>();
 }
Beispiel #25
0
 public SharedController(IUserService userService, IKeywordService keywordService)
 {
     this.userService    = userService;
     this.keywordService = keywordService;
 }
Beispiel #26
0
 public TestController(IDynamicQuestionnaireService dynamicQuestionnaireService, IKeywordService keywordService, ITrackingDifferenceService trackingDifferenceService)
 {
     _dynamicQuestionnaireService = dynamicQuestionnaireService;
     _trackingDifferenceService   = trackingDifferenceService;
     _keywordService = keywordService;
 }
 public KeywordController(IKeywordService keywordService)
 {
     _keywordService = keywordService;
 }
Beispiel #28
0
 public Summarizer(string language, IKeywordService keywordService)
 {
     this.parser = new Parser(StopWords.GetStopWords(language));
     this.keywordService = keywordService;
 }
Beispiel #29
0
 public static async Task <IEnumerable <Keyword> > GetAllData(this IKeywordService service) => await service.GetData(await service.All());
Beispiel #30
0
 public CommandRunner(IKeywordService keywordService, IDataSourceService databaseService, ILogService logService)
 {
     _log             = logService;
     _databaseService = databaseService;
     _keywordService  = keywordService;
 }
 public KeywordController(ILogger <PhotographController> logger, IKeywordService keywordService)
 {
     this.logger         = logger;
     this.keywordService = keywordService;
 }
Beispiel #32
0
 public KeywordsAPIController(IKeywordService keywordService)
 {
     this.keywordService = keywordService;
 }