Class SingleBucketAggregate
java.lang.Object
org.nuxeo.ecm.platform.query.core.AggregateBase<B>
org.nuxeo.elasticsearch.aggregate.AggregateEsBase<org.opensearch.search.aggregations.bucket.SingleBucketAggregation,BucketTerm>
org.nuxeo.elasticsearch.aggregate.SingleBucketAggregate
- All Implemented Interfaces:
Aggregate<BucketTerm>
- Direct Known Subclasses:
MissingAggregate
public abstract class SingleBucketAggregate
extends AggregateEsBase<org.opensearch.search.aggregations.bucket.SingleBucketAggregation,BucketTerm>
An aggregate that returns a single bucket.
- Since:
- 10.3
-
Field Summary
FieldsFields inherited from class org.nuxeo.elasticsearch.aggregate.AggregateEsBase
ES_MUTLI_LEVEL_SEP, MAX_AGG_SIZE, XPATH_SEPFields inherited from class org.nuxeo.ecm.platform.query.core.AggregateBase
bucketMap, buckets, definition, extendedBuckets, searchDocument, selection -
Constructor Summary
ConstructorsConstructorDescriptionSingleBucketAggregate(AggregateDefinition definition, DocumentModel searchDocument) -
Method Summary
Modifier and TypeMethodDescriptionlongorg.opensearch.index.query.QueryBuilderReturn the Elasticsearch aggregate filter corresponding to the selectionvoidparseAggregation(org.opensearch.search.aggregations.bucket.SingleBucketAggregation aggregation) Extract the aggregation from the Elasticsearch responseMethods inherited from class org.nuxeo.elasticsearch.aggregate.AggregateEsBase
getAggSize, getEsAggregate, getField, getXPathFieldMethods inherited from class org.nuxeo.ecm.platform.query.core.AggregateBase
getBucket, getBucketMap, getBuckets, getDateRanges, getExtendedBuckets, getId, getProperties, getRanges, getSearchDocument, getSelection, getType, hasBucket, resetSelection, setBuckets, setSelection, toString
-
Field Details
-
docCount
protected long docCount
-
-
Constructor Details
-
SingleBucketAggregate
-
-
Method Details
-
parseAggregation
public void parseAggregation(org.opensearch.search.aggregations.bucket.SingleBucketAggregation aggregation) Description copied from class:AggregateEsBaseExtract the aggregation from the Elasticsearch response- Specified by:
parseAggregationin classAggregateEsBase<org.opensearch.search.aggregations.bucket.SingleBucketAggregation,BucketTerm>
-
getEsFilter
public org.opensearch.index.query.QueryBuilder getEsFilter()Description copied from class:AggregateEsBaseReturn the Elasticsearch aggregate filter corresponding to the selection- Specified by:
getEsFilterin classAggregateEsBase<org.opensearch.search.aggregations.bucket.SingleBucketAggregation,BucketTerm>
-
getDocCount
public long getDocCount()
-