test_class.declarator: INDEX_SEARCH_RESULT_TYPE = "Index Search Result Type 1"
test_class.modifier: private static final
test_class.original_string: private static final String INDEX_SEARCH_RESULT_TYPE = "Index Search Result Type 1";
test_class.type: String
test_class.var_name: INDEX_SEARCH_RESULT_TYPE
test_class.declarator: TAG_TYPE_CODE = "Tag Type Code 1"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_CODE = "Tag Type Code 1";
test_class.type: String
test_class.var_name: TAG_TYPE_CODE
test_class.declarator: TAG_TYPE_CODE_2 = "Tag Type Code 2"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_CODE_2 = "Tag Type Code 2";
test_class.type: String
test_class.var_name: TAG_TYPE_CODE_2
test_class.declarator: TAG_TYPE_CODE_3 = "Tag Type Code 3"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_CODE_3 = "Tag Type Code 3";
test_class.type: String
test_class.var_name: TAG_TYPE_CODE_3
test_class.declarator: TAG_TYPE_DISPLAY_NAME = "Tag Type DisplayName"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_DISPLAY_NAME = "Tag Type DisplayName";
test_class.type: String
test_class.var_name: TAG_TYPE_DISPLAY_NAME
test_class.declarator: TAG_TYPE_DISPLAY_NAME_2 = "Tag Type DisplayName 2"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_DISPLAY_NAME_2 = "Tag Type DisplayName 2";
test_class.type: String
test_class.var_name: TAG_TYPE_DISPLAY_NAME_2
test_class.declarator: TAG_TYPE_DISPLAY_NAME_3 = "Tag Type DisplayName 3"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_TYPE_DISPLAY_NAME_3 = "Tag Type DisplayName 3";
test_class.type: String
test_class.var_name: TAG_TYPE_DISPLAY_NAME_3
test_class.declarator: TAG_CODE = "Tag Code 1"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_CODE = "Tag Code 1";
test_class.type: String
test_class.var_name: TAG_CODE
test_class.declarator: TAG_CODE_2 = "Tag Code 2"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_CODE_2 = "Tag Code 2";
test_class.type: String
test_class.var_name: TAG_CODE_2
test_class.declarator: TAG_CODE_COUNT = 1
test_class.modifier: private static final
test_class.original_string: private static final int TAG_CODE_COUNT = 1;
test_class.type: int
test_class.var_name: TAG_CODE_COUNT
test_class.declarator: TAG_CODE_DISPLAY_NAME = "Tag Code DisplayName"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_CODE_DISPLAY_NAME = "Tag Code DisplayName";
test_class.type: String
test_class.var_name: TAG_CODE_DISPLAY_NAME
test_class.declarator: TAG_CODE_DISPLAY_NAME_2 = "Tag Code DisplayName 2"
test_class.modifier: private static final
test_class.original_string: private static final String TAG_CODE_DISPLAY_NAME_2 = "Tag Code DisplayName 2";
test_class.type: String
test_class.var_name: TAG_CODE_DISPLAY_NAME_2
test_class.declarator: elasticsearchHelper
test_class.modifier: @InjectMocks
      private
test_class.original_string: @InjectMocks
      private ElasticsearchHelper elasticsearchHelper;
test_class.type: ElasticsearchHelper
test_class.var_name: elasticsearchHelper
test_class.declarator: jsonHelper
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private JsonHelper jsonHelper;
test_class.type: JsonHelper
test_class.var_name: jsonHelper
test_class.declarator: tagDaoHelper
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private TagDaoHelper tagDaoHelper;
test_class.type: TagDaoHelper
test_class.var_name: tagDaoHelper
test_class.file: herd-code/herd-dao/src/test/java/org/finra/herd/dao/helper/ElasticSearchHelperTest.java
test_class.identifier: ElasticSearchHelperTest
test_class.superclass: extends AbstractDaoTest
test_case.body: @Test
      public void testGetFacetsResponseIncludingTag()
      {
          ElasticsearchResponseDto elasticsearchResponseDto = new ElasticsearchResponseDto();
  
          List<TagTypeIndexSearchResponseDto> nestTagTypeIndexSearchResponseDtos = new ArrayList<>();
          TagTypeIndexSearchResponseDto tagType1 = new TagTypeIndexSearchResponseDto(TAG_TYPE_CODE, null, TAG_TYPE_DISPLAY_NAME);
          TagTypeIndexSearchResponseDto tagType2 =
              new TagTypeIndexSearchResponseDto(TAG_TYPE_CODE_2, Collections.singletonList(new TagIndexSearchResponseDto(TAG_CODE, 1, TAG_CODE_DISPLAY_NAME)),
                  TAG_TYPE_DISPLAY_NAME_2);
          nestTagTypeIndexSearchResponseDtos.add(tagType1);
          nestTagTypeIndexSearchResponseDtos.add(tagType2);
  
          elasticsearchResponseDto.setNestTagTypeIndexSearchResponseDtos(nestTagTypeIndexSearchResponseDtos);
          TagTypeIndexSearchResponseDto tagType3 =
              new TagTypeIndexSearchResponseDto(TAG_TYPE_CODE_2, Collections.singletonList(new TagIndexSearchResponseDto(TAG_CODE, 1, TAG_CODE_DISPLAY_NAME)),
                  TAG_TYPE_DISPLAY_NAME_2);
          List<TagTypeIndexSearchResponseDto> tagTypeIndexSearchResponseDtos = new ArrayList<>();
          tagTypeIndexSearchResponseDtos.add(tagType3);
          elasticsearchResponseDto.setTagTypeIndexSearchResponseDtos(tagTypeIndexSearchResponseDtos);
  
          List<Facet> facets =
              elasticsearchHelper.getFacetsResponse(elasticsearchResponseDto, BUSINESS_OBJECT_DEFINITION_SEARCH_INDEX_NAME, TAG_SEARCH_INDEX_NAME);
          List<Facet> expectedFacets = new ArrayList<>();
          expectedFacets.add(new Facet(TAG_TYPE_DISPLAY_NAME, null, FacetTypeEnum.TAG_TYPE.value(), TAG_TYPE_CODE, new ArrayList<>()));
  
          List<Facet> tagFacet = new ArrayList<>();
          tagFacet.add(new Facet(TAG_CODE_DISPLAY_NAME, 1L, FacetTypeEnum.TAG.value(), TAG_CODE, null));
  
          expectedFacets.add(new Facet(TAG_TYPE_DISPLAY_NAME_2, null, FacetTypeEnum.TAG_TYPE.value(), TAG_TYPE_CODE_2, tagFacet));
          assertEquals(expectedFacets, facets);
      }
test_case.class_method_signature: ElasticSearchHelperTest.testGetFacetsResponseIncludingTag()
test_case.full_signature: @Test public void testGetFacetsResponseIncludingTag()
test_case.identifier: testGetFacetsResponseIncludingTag
test_case.invocations: singletonList add add setNestTagTypeIndexSearchResponseDtos singletonList add setTagTypeIndexSearchResponseDtos getFacetsResponse add value add value add value assertEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testGetFacetsResponseIncludingTag()
focal_class.declarator: LOGGER = LoggerFactory.getLogger(ElasticsearchHelper.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(ElasticsearchHelper.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.declarator: jsonHelper
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private JsonHelper jsonHelper;
focal_class.type: JsonHelper
focal_class.var_name: jsonHelper
focal_class.declarator: tagDaoHelper
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private TagDaoHelper tagDaoHelper;
focal_class.type: TagDaoHelper
focal_class.var_name: tagDaoHelper
focal_class.declarator: DISPLAY_NAME_SOURCE = "displayName"
focal_class.modifier: public static final
focal_class.original_string: public static final String DISPLAY_NAME_SOURCE = "displayName";
focal_class.type: String
focal_class.var_name: DISPLAY_NAME_SOURCE
focal_class.declarator: NESTED_BDEFTAGS_PATH = "businessObjectDefinitionTags.tag"
focal_class.modifier: public static final
focal_class.original_string: public static final String NESTED_BDEFTAGS_PATH = "businessObjectDefinitionTags.tag";
focal_class.type: String
focal_class.var_name: NESTED_BDEFTAGS_PATH
focal_class.declarator: TAGTYPE_CODE_FIELD_TAG_INDEX = "tagType.code.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAGTYPE_CODE_FIELD_TAG_INDEX = "tagType.code.keyword";
focal_class.type: String
focal_class.var_name: TAGTYPE_CODE_FIELD_TAG_INDEX
focal_class.declarator: TAGTYPE_NAME_FIELD_TAG_INDEX = "tagType.displayName.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAGTYPE_NAME_FIELD_TAG_INDEX = "tagType.displayName.keyword";
focal_class.type: String
focal_class.var_name: TAGTYPE_NAME_FIELD_TAG_INDEX
focal_class.declarator: TAG_CODE_FIELD_TAG_INDEX = "tagCode.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_CODE_FIELD_TAG_INDEX = "tagCode.keyword";
focal_class.type: String
focal_class.var_name: TAG_CODE_FIELD_TAG_INDEX
focal_class.declarator: TAG_NAME_FIELD_TAG_INDEX = "displayName.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_NAME_FIELD_TAG_INDEX = "displayName.keyword";
focal_class.type: String
focal_class.var_name: TAG_NAME_FIELD_TAG_INDEX
focal_class.declarator: BDEF_TAGTYPE_CODE_FIELD = NESTED_BDEFTAGS_PATH + ".tagType.code.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String BDEF_TAGTYPE_CODE_FIELD = NESTED_BDEFTAGS_PATH + ".tagType.code.keyword";
focal_class.type: String
focal_class.var_name: BDEF_TAGTYPE_CODE_FIELD
focal_class.declarator: BDEF_TAGTYPE_NAME_FIELD = NESTED_BDEFTAGS_PATH + ".tagType.displayName.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String BDEF_TAGTYPE_NAME_FIELD = NESTED_BDEFTAGS_PATH + ".tagType.displayName.keyword";
focal_class.type: String
focal_class.var_name: BDEF_TAGTYPE_NAME_FIELD
focal_class.declarator: BDEF_TAG_CODE_FIELD = NESTED_BDEFTAGS_PATH + ".tagCode.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String BDEF_TAG_CODE_FIELD = NESTED_BDEFTAGS_PATH + ".tagCode.keyword";
focal_class.type: String
focal_class.var_name: BDEF_TAG_CODE_FIELD
focal_class.declarator: BDEF_TAG_NAME_FIELD = NESTED_BDEFTAGS_PATH + ".displayName.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String BDEF_TAG_NAME_FIELD = NESTED_BDEFTAGS_PATH + ".displayName.keyword";
focal_class.type: String
focal_class.var_name: BDEF_TAG_NAME_FIELD
focal_class.declarator: TAG_TAG_CODE_FIELD = "tagCode.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_TAG_CODE_FIELD = "tagCode.keyword";
focal_class.type: String
focal_class.var_name: TAG_TAG_CODE_FIELD
focal_class.declarator: TAG_TAGTYPE_CODE_FIELD = "tagType.code.keyword"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_TAGTYPE_CODE_FIELD = "tagType.code.keyword";
focal_class.type: String
focal_class.var_name: TAG_TAGTYPE_CODE_FIELD
focal_class.declarator: TAG_FACET_AGGS = "tagFacet"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_FACET_AGGS = "tagFacet";
focal_class.type: String
focal_class.var_name: TAG_FACET_AGGS
focal_class.declarator: TAGTYPE_CODE_AGGREGATION = "tagTypeCodes"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAGTYPE_CODE_AGGREGATION = "tagTypeCodes";
focal_class.type: String
focal_class.var_name: TAGTYPE_CODE_AGGREGATION
focal_class.declarator: TAGTYPE_NAME_AGGREGATION = "tagTypeDisplayNames"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAGTYPE_NAME_AGGREGATION = "tagTypeDisplayNames";
focal_class.type: String
focal_class.var_name: TAGTYPE_NAME_AGGREGATION
focal_class.declarator: TAG_CODE_AGGREGATION = "tagCodes"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_CODE_AGGREGATION = "tagCodes";
focal_class.type: String
focal_class.var_name: TAG_CODE_AGGREGATION
focal_class.declarator: TAG_NAME_AGGREGATION = "tagDisplayNames"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_NAME_AGGREGATION = "tagDisplayNames";
focal_class.type: String
focal_class.var_name: TAG_NAME_AGGREGATION
focal_class.declarator: TAG_FACET = "tag"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_FACET = "tag";
focal_class.type: String
focal_class.var_name: TAG_FACET
focal_class.declarator: RESULT_TYPE_FACET = "resulttype"
focal_class.modifier: public static final
focal_class.original_string: public static final String RESULT_TYPE_FACET = "resulttype";
focal_class.type: String
focal_class.var_name: RESULT_TYPE_FACET
focal_class.declarator: TAG_TYPE_FACET_AGGS = "tagTypeFacet"
focal_class.modifier: public static final
focal_class.original_string: public static final String TAG_TYPE_FACET_AGGS = "tagTypeFacet";
focal_class.type: String
focal_class.var_name: TAG_TYPE_FACET_AGGS
focal_class.declarator: RESULT_TYPE_AGGS = "resultType"
focal_class.modifier: public static final
focal_class.original_string: public static final String RESULT_TYPE_AGGS = "resultType";
focal_class.type: String
focal_class.var_name: RESULT_TYPE_AGGS
focal_class.declarator: RESULT_TYPE_FIELD = "_index"
focal_class.modifier: public static final
focal_class.original_string: public static final String RESULT_TYPE_FIELD = "_index";
focal_class.type: String
focal_class.var_name: RESULT_TYPE_FIELD
focal_class.file: herd-code/herd-dao/src/main/java/org/finra/herd/dao/helper/ElasticsearchHelper.java
focal_class.identifier: ElasticsearchHelper
focal_class.class_method_signature: ElasticsearchHelper.addFacetFieldAggregations(Set<String> facetFieldsList, SearchRequestBuilder searchRequestBuilder)
focal_class.full_signature: public SearchRequestBuilder addFacetFieldAggregations(Set<String> facetFieldsList, SearchRequestBuilder searchRequestBuilder)
focal_class.identifier: addFacetFieldAggregations
focal_class.modifiers: public
focal_class.parameters: (Set<String> facetFieldsList, SearchRequestBuilder searchRequestBuilder)
focal_class.return: SearchRequestBuilder
focal_class.signature: SearchRequestBuilder addFacetFieldAggregations(Set<String> facetFieldsList, SearchRequestBuilder searchRequestBuilder)
focal_class.class_method_signature: ElasticsearchHelper.addIndexSearchFilterBooleanClause(List<IndexSearchFilter> indexSearchFilters, String bdefActiveIndex, String tagActiveIndex)
focal_class.full_signature: public BoolQueryBuilder addIndexSearchFilterBooleanClause(List<IndexSearchFilter> indexSearchFilters, String bdefActiveIndex, String tagActiveIndex)
focal_class.identifier: addIndexSearchFilterBooleanClause
focal_class.modifiers: public
focal_class.parameters: (List<IndexSearchFilter> indexSearchFilters, String bdefActiveIndex, String tagActiveIndex)
focal_class.return: BoolQueryBuilder
focal_class.signature: BoolQueryBuilder addIndexSearchFilterBooleanClause(List<IndexSearchFilter> indexSearchFilters, String bdefActiveIndex, String tagActiveIndex)
focal_class.class_method_signature: ElasticsearchHelper.applySearchFilterClause(IndexSearchFilter indexSearchFilter, String bdefActiveIndex, String tagActiveIndex)
focal_class.full_signature: private BoolQueryBuilder applySearchFilterClause(IndexSearchFilter indexSearchFilter, String bdefActiveIndex, String tagActiveIndex)
focal_class.identifier: applySearchFilterClause
focal_class.modifiers: private
focal_class.parameters: (IndexSearchFilter indexSearchFilter, String bdefActiveIndex, String tagActiveIndex)
focal_class.return: BoolQueryBuilder
focal_class.signature: BoolQueryBuilder applySearchFilterClause(IndexSearchFilter indexSearchFilter, String bdefActiveIndex, String tagActiveIndex)
focal_class.class_method_signature: ElasticsearchHelper.getResultTypeIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.full_signature: public List<ResultTypeIndexSearchResponseDto> getResultTypeIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.identifier: getResultTypeIndexSearchResponseDto
focal_class.modifiers: public
focal_class.parameters: (SearchResponse searchResponse)
focal_class.return: List<ResultTypeIndexSearchResponseDto>
focal_class.signature: List<ResultTypeIndexSearchResponseDto> getResultTypeIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.class_method_signature: ElasticsearchHelper.getTagTypeIndexSearchResponseDtosFromTerms(Terms aggregation)
focal_class.full_signature: private List<TagTypeIndexSearchResponseDto> getTagTypeIndexSearchResponseDtosFromTerms(Terms aggregation)
focal_class.identifier: getTagTypeIndexSearchResponseDtosFromTerms
focal_class.modifiers: private
focal_class.parameters: (Terms aggregation)
focal_class.return: List<TagTypeIndexSearchResponseDto>
focal_class.signature: List<TagTypeIndexSearchResponseDto> getTagTypeIndexSearchResponseDtosFromTerms(Terms aggregation)
focal_class.class_method_signature: ElasticsearchHelper.getTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.full_signature: public List<TagTypeIndexSearchResponseDto> getTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.identifier: getTagTagIndexSearchResponseDto
focal_class.modifiers: public
focal_class.parameters: (SearchResponse searchResponse)
focal_class.return: List<TagTypeIndexSearchResponseDto>
focal_class.signature: List<TagTypeIndexSearchResponseDto> getTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.class_method_signature: ElasticsearchHelper.getNestedTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.full_signature: public List<TagTypeIndexSearchResponseDto> getNestedTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.identifier: getNestedTagTagIndexSearchResponseDto
focal_class.modifiers: public
focal_class.parameters: (SearchResponse searchResponse)
focal_class.return: List<TagTypeIndexSearchResponseDto>
focal_class.signature: List<TagTypeIndexSearchResponseDto> getNestedTagTagIndexSearchResponseDto(SearchResponse searchResponse)
focal_class.class_method_signature: ElasticsearchHelper.createTagTypeFacet(TagTypeIndexSearchResponseDto tagTypeIndexSearchResponseDto)
focal_class.full_signature: private Facet createTagTypeFacet(TagTypeIndexSearchResponseDto tagTypeIndexSearchResponseDto)
focal_class.identifier: createTagTypeFacet
focal_class.modifiers: private
focal_class.parameters: (TagTypeIndexSearchResponseDto tagTypeIndexSearchResponseDto)
focal_class.return: Facet
focal_class.signature: Facet createTagTypeFacet(TagTypeIndexSearchResponseDto tagTypeIndexSearchResponseDto)
focal_class.class_method_signature: ElasticsearchHelper.getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.full_signature: public List<Facet> getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.identifier: getFacetsResponse
focal_class.modifiers: public
focal_class.parameters: (ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.return: List<Facet>
focal_class.signature: List<Facet> getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.class_method_signature: ElasticsearchHelper.getAggregation(SearchResponse searchResponse, String aggregationName)
focal_class.full_signature: public Terms getAggregation(SearchResponse searchResponse, String aggregationName)
focal_class.identifier: getAggregation
focal_class.modifiers: public
focal_class.parameters: (SearchResponse searchResponse, String aggregationName)
focal_class.return: Terms
focal_class.signature: Terms getAggregation(SearchResponse searchResponse, String aggregationName)
focal_class.class_method_signature: ElasticsearchHelper.getNestedAggregation(SearchResponse searchResponse, String nestedAggregationName, String subAggregationName)
focal_class.full_signature: public Terms getNestedAggregation(SearchResponse searchResponse, String nestedAggregationName, String subAggregationName)
focal_class.identifier: getNestedAggregation
focal_class.modifiers: public
focal_class.parameters: (SearchResponse searchResponse, String nestedAggregationName, String subAggregationName)
focal_class.return: Terms
focal_class.signature: Terms getNestedAggregation(SearchResponse searchResponse, String nestedAggregationName, String subAggregationName)
focal_class.class_method_signature: ElasticsearchHelper.getSearchIndexType(final String indexName, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.full_signature: public String getSearchIndexType(final String indexName, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.identifier: getSearchIndexType
focal_class.modifiers: public
focal_class.parameters: (final String indexName, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.return: String
focal_class.signature: String getSearchIndexType(final String indexName, final String bdefActiveIndex, final String tagActiveIndex)
focal_class.class_method_signature: ElasticsearchHelper.getAggregationsFromNestedAggregation(Nested nestedAggregation, SearchResponse searchResponse)
focal_class.full_signature: protected Aggregations getAggregationsFromNestedAggregation(Nested nestedAggregation, SearchResponse searchResponse)
focal_class.identifier: getAggregationsFromNestedAggregation
focal_class.modifiers: protected
focal_class.parameters: (Nested nestedAggregation, SearchResponse searchResponse)
focal_class.return: Aggregations
focal_class.signature: Aggregations getAggregationsFromNestedAggregation(Nested nestedAggregation, SearchResponse searchResponse)
focal_class.class_method_signature: ElasticsearchHelper.getAggregationsFromSearchResponse(SearchResponse searchResponse)
focal_class.full_signature: protected Aggregations getAggregationsFromSearchResponse(SearchResponse searchResponse)
focal_class.identifier: getAggregationsFromSearchResponse
focal_class.modifiers: protected
focal_class.parameters: (SearchResponse searchResponse)
focal_class.return: Aggregations
focal_class.signature: Aggregations getAggregationsFromSearchResponse(SearchResponse searchResponse)
focal_method.body: public List<Facet> getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
      {
          List<Facet> facets = new ArrayList<>();
  
          List<Facet> tagTypeFacets;
          if (elasticsearchResponseDto.getNestTagTypeIndexSearchResponseDtos() != null)
          {
              tagTypeFacets = new ArrayList<>();
              //construct a list of facet information
              for (TagTypeIndexSearchResponseDto tagTypeIndexSearchResponseDto : elasticsearchResponseDto.getNestTagTypeIndexSearchResponseDtos())
              {
                  tagTypeFacets.add(createTagTypeFacet(tagTypeIndexSearchResponseDto));
              }
  
              facets.addAll(tagTypeFacets);
          }
  
          if (elasticsearchResponseDto.getTagTypeIndexSearchResponseDtos() != null)
          {
              for (TagTypeIndexSearchResponseDto tagTypeIndexDto : elasticsearchResponseDto.getTagTypeIndexSearchResponseDtos())
              {
                  boolean foundMatchingTagType = false;
                  for (Facet tagFacet : facets)
                  {
                      if (tagFacet.getFacetId().equals(tagTypeIndexDto.getCode()))
                      {
                          foundMatchingTagType = true;
                          boolean foundMatchingTagCode = false;
                          for (TagIndexSearchResponseDto tagIndexDto : tagTypeIndexDto.getTagIndexSearchResponseDtos())
                          {
                              for (Facet nestedTagIndexDto : tagFacet.getFacets())
                              {
                                  if (tagIndexDto.getTagCode().equals(nestedTagIndexDto.getFacetId()))
                                  {
                                      foundMatchingTagCode = true;
                                  }
                              }
                              if (!foundMatchingTagCode)
                              {
                                  tagFacet.getFacets().add(
                                      new Facet(tagIndexDto.getTagDisplayName(), tagIndexDto.getCount(), FacetTypeEnum.TAG.value(), tagIndexDto.getTagCode(),
                                          null));
                              }
                          }
                      }
                  }
                  if (!foundMatchingTagType)
                  {
                      facets.add(createTagTypeFacet(tagTypeIndexDto));
                  }
              }
          }
  
          if (elasticsearchResponseDto.getResultTypeIndexSearchResponseDtos() != null)
          {
              List<Facet> resultTypeFacets = new ArrayList<>();
              //construct a list of facet information
              for (ResultTypeIndexSearchResponseDto resultTypeIndexSearchResponseDto : elasticsearchResponseDto.getResultTypeIndexSearchResponseDtos())
              {
                  String facetId = getSearchIndexType(resultTypeIndexSearchResponseDto.getResultTypeDisplayName(), bdefActiveIndex, tagActiveIndex);
                  Facet resultTypeFacet = new Facet(facetId, resultTypeIndexSearchResponseDto.getCount(), FacetTypeEnum.RESULT_TYPE.value(), facetId, null);
                  resultTypeFacets.add(resultTypeFacet);
              }
              facets.addAll(resultTypeFacets);
          }
  
          return facets;
      }
focal_method.class_method_signature: ElasticsearchHelper.getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_method.full_signature: public List<Facet> getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_method.identifier: getFacetsResponse
focal_method.invocations: getNestTagTypeIndexSearchResponseDtos getNestTagTypeIndexSearchResponseDtos add createTagTypeFacet addAll getTagTypeIndexSearchResponseDtos getTagTypeIndexSearchResponseDtos equals getFacetId getCode getTagIndexSearchResponseDtos getFacets equals getTagCode getFacetId add getFacets getTagDisplayName getCount value getTagCode add createTagTypeFacet getResultTypeIndexSearchResponseDtos getResultTypeIndexSearchResponseDtos getSearchIndexType getResultTypeDisplayName getCount value add addAll
focal_method.modifiers: public
focal_method.parameters: (ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)
focal_method.return: List<Facet>
focal_method.signature: List<Facet> getFacetsResponse(ElasticsearchResponseDto elasticsearchResponseDto, final String bdefActiveIndex, final String tagActiveIndex)