Exemple #1
0
        public override async Task <GetKeywordSuggestionsReply> GetKeywordSuggestions(
            GetKeywordSuggestionsRequest request, ServerCallContext context)
        {
            var list = await _driver.GetKeywordSuggestions(_mapper.Map <KeywordCondition.KeywordField>(request.Field),
                                                           request.Input, request.Skip, request.Order);

            GetKeywordSuggestionsReply reply = new();

            reply.Results.AddRange(_mapper.Map <IEnumerable <Suggestion> >(list));
            return(reply);
        }