NamedWriteable
, Writeable
, ToXContent
, ToXContentFragment
, Aggregation
, MultiBucketsAggregation
, Terms
public class LongTerms extends InternalMappedTerms<LongTerms,LongTerms.Bucket>
TermsAggregator
when the field is some kind of whole number like a integer, long, or a date.Modifier and Type | Class | Description |
---|---|---|
static class |
LongTerms.Bucket |
Aggregation.CommonFields
InternalAggregation.ReduceContext
InternalMultiBucketAggregation.InternalBucket
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
Writeable.Reader<V>, Writeable.Writer<V>
Modifier and Type | Field | Description |
---|---|---|
static java.lang.String |
NAME |
TYPED_KEYS_DELIMITER
metaData, name
bucketMap, buckets, docCountError, format, otherDocCount, shardSize, showTermDocCountError
DOC_COUNT_ERROR_UPPER_BOUND_FIELD_NAME, minDocCount, order, requiredSize, SUM_OF_OTHER_DOC_COUNTS
EMPTY_PARAMS
Constructor | Description |
---|---|
LongTerms(java.lang.String name,
BucketOrder order,
int requiredSize,
long minDocCount,
java.util.List<PipelineAggregator> pipelineAggregators,
java.util.Map<java.lang.String,java.lang.Object> metaData,
DocValueFormat format,
int shardSize,
boolean showTermDocCountError,
long otherDocCount,
java.util.List<LongTerms.Bucket> buckets,
long docCountError) |
|
LongTerms(StreamInput in) |
Read from a stream.
|
Modifier and Type | Method | Description |
---|---|---|
protected LongTerms |
create(java.lang.String name,
java.util.List<LongTerms.Bucket> buckets,
long docCountError,
long otherDocCount) |
|
LongTerms |
create(java.util.List<LongTerms.Bucket> buckets) |
Create a new copy of this
Aggregation with the same settings as
this Aggregation and contains the provided buckets. |
LongTerms.Bucket |
createBucket(InternalAggregations aggregations,
LongTerms.Bucket prototype) |
Create a new
InternalMultiBucketAggregation.InternalBucket using the provided prototype bucket
and aggregations. |
protected LongTerms.Bucket[] |
createBucketsArray(int size) |
Create an array to hold some buckets.
|
InternalAggregation |
doReduce(java.util.List<InternalAggregation> aggregations,
InternalAggregation.ReduceContext reduceContext) |
|
java.lang.String |
getWriteableName() |
Returns the name of the writeable object
|
getMetaData, getName, getType
equals, getMetaData, getName, getProperty, getType, hashCode, pipelineAggregators, readSize, reduce, toString, toXContent, writeSize, writeTo
doEquals, doHashCode, doXContentBody, getBucketByKey, getBuckets, getDocCountError, getShardSize, getSumOfOtherDocCounts, setDocCountError, writeTermTypeInfoTo
countInnerBucket, countInnerBucket, getProperty
doWriteTo, doXContentCommon
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
toXContent
isFragment
public static final java.lang.String NAME
public LongTerms(java.lang.String name, BucketOrder order, int requiredSize, long minDocCount, java.util.List<PipelineAggregator> pipelineAggregators, java.util.Map<java.lang.String,java.lang.Object> metaData, DocValueFormat format, int shardSize, boolean showTermDocCountError, long otherDocCount, java.util.List<LongTerms.Bucket> buckets, long docCountError)
public LongTerms(StreamInput in) throws java.io.IOException
java.io.IOException
public java.lang.String getWriteableName()
NamedWriteable
public LongTerms create(java.util.List<LongTerms.Bucket> buckets)
InternalMultiBucketAggregation
Aggregation
with the same settings as
this Aggregation
and contains the provided buckets.create
in class InternalMultiBucketAggregation<LongTerms,LongTerms.Bucket>
buckets
- the buckets to use in the new Aggregation
Aggregation
public LongTerms.Bucket createBucket(InternalAggregations aggregations, LongTerms.Bucket prototype)
InternalMultiBucketAggregation
InternalMultiBucketAggregation.InternalBucket
using the provided prototype bucket
and aggregations.createBucket
in class InternalMultiBucketAggregation<LongTerms,LongTerms.Bucket>
aggregations
- the aggregations for the new bucketprototype
- the bucket to use as a prototypeprotected LongTerms create(java.lang.String name, java.util.List<LongTerms.Bucket> buckets, long docCountError, long otherDocCount)
create
in class InternalTerms<LongTerms,LongTerms.Bucket>
protected LongTerms.Bucket[] createBucketsArray(int size)
InternalTerms
createBucketsArray
in class InternalTerms<LongTerms,LongTerms.Bucket>
public InternalAggregation doReduce(java.util.List<InternalAggregation> aggregations, InternalAggregation.ReduceContext reduceContext)
doReduce
in class InternalTerms<LongTerms,LongTerms.Bucket>