Package org.elasticsearch.search.aggregations

Examples of org.elasticsearch.search.aggregations.InternalAggregations$Fields


        for (InternalAggregation aggregation : aggregations) {
            assert aggregation.getName().equals(getName());
            docCount += ((InternalSingleBucketAggregation) aggregation).docCount;
            subAggregationsList.add(((InternalSingleBucketAggregation) aggregation).aggregations);
        }
        final InternalAggregations aggs = InternalAggregations.reduce(subAggregationsList, reduceContext);
        return newAggregation(getName(), docCount, aggs);
    }
View Full Code Here


            suggest = hasSuggestions ? new Suggest(Suggest.Fields.SUGGEST, Suggest.reduce(groupedSuggestions)) : null;
        }

        // merge addAggregation
        InternalAggregations aggregations = null;
        if (!queryResults.isEmpty()) {
            if (firstResult.aggregations() != null && firstResult.aggregations().asList() != null) {
                List<InternalAggregations> aggregationsList = new ArrayList<>(queryResults.size());
                for (AtomicArray.Entry<? extends QuerySearchResultProvider> entry : queryResults) {
                    aggregationsList.add((InternalAggregations) entry.value.queryResult().aggregations());
View Full Code Here

            InternalFacets facets = null;
            if (response.getFacets() != null) {
                facets = new InternalFacets(response.getFacets().facets());
            }

            InternalAggregations aggregations = null;
            if (response.getAggregations() != null) {
                aggregations = new InternalAggregations(toInternal(response.getAggregations().asList()));
            }

            return new SearchResponse(
                    new InternalSearchResponse(
                            new InternalSearchHits(trimmedHits, allHits.getTotalHits(), allHits.getMaxScore()),
View Full Code Here

    @Override
    protected List<ColumnDefinition> getElements0() throws SQLException {
        List<ColumnDefinition> result = new ArrayList<ColumnDefinition>();

        Rdb$relationFields r = RDB$RELATION_FIELDS.as("r");
        Rdb$fields f = RDB$FIELDS.as("f");

        // Inspiration for the below query was taken from jaybird's
        // DatabaseMetaData implementation
        for (Record record : create().select(
                r.RDB$FIELD_NAME.trim(),
View Full Code Here

TOP

Related Classes of org.elasticsearch.search.aggregations.InternalAggregations$Fields

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.