Class ElasticsearchResultConverter


  • public class ElasticsearchResultConverter
    extends java.lang.Object
    • Field Detail

      • RESULT_NODE_NAME

        public static final java.lang.String RESULT_NODE_NAME
        See Also:
        Constant Field Values
      • RESULT_CONTENT_NODE_NAME

        public static final java.lang.String RESULT_CONTENT_NODE_NAME
        See Also:
        Constant Field Values
      • RESULT_CONTENT_SOURCE_NODE_NAME

        public static final java.lang.String RESULT_CONTENT_SOURCE_NODE_NAME
        See Also:
        Constant Field Values
      • RESULT_CONTENT_SCORE_NODE_NAME

        public static final java.lang.String RESULT_CONTENT_SCORE_NODE_NAME
        See Also:
        Constant Field Values
      • TOTAL_COUNT_NODE_NAME

        public static final java.lang.String TOTAL_COUNT_NODE_NAME
        See Also:
        Constant Field Values
      • NESTED_RESULT_NODE_NAME

        public static final java.lang.String NESTED_RESULT_NODE_NAME
        See Also:
        Constant Field Values
    • Method Detail

      • convertSearchResultToList

        public static <T> java.util.List<T> convertSearchResultToList​(com.fasterxml.jackson.databind.JsonNode searchResult,
                                                                      ElasticsearchResultConverter.ResultMapper<T> resultMapper)
      • extractHits

        public static java.util.Optional<com.fasterxml.jackson.databind.node.ArrayNode> extractHits​(com.fasterxml.jackson.databind.JsonNode resultNode)
      • extractFirstContentSourceFromHits

        public static java.util.Optional<com.fasterxml.jackson.databind.JsonNode> extractFirstContentSourceFromHits​(com.fasterxml.jackson.databind.JsonNode resultNode)
      • getHitsTotalCount

        public static long getHitsTotalCount​(com.fasterxml.jackson.databind.JsonNode hitsRoot)