public class UnmappedTerms extends InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>
TermsAggregator when the field is unmapped.| Modifier and Type | Class and Description |
|---|---|
protected static class |
UnmappedTerms.Bucket
Concrete type that can't be built because Java needs a concrent type so
InternalTerms.Bucket can have a self type but
UnmappedTerms doesn't ever need to build it because it never returns any buckets. |
InternalMultiBucketAggregation.InternalBucketInternalAggregation.ReduceContextTerms.OrderAggregation.CommonFieldsToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsWriteable.Reader<V>, Writeable.Writer<V>| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
NAME |
DOC_COUNT_ERROR_UPPER_BOUND_FIELD_NAME, minDocCount, order, requiredSize, SUM_OF_OTHER_DOC_COUNTSmetaData, nameTYPED_KEYS_DELIMITEREMPTY_PARAMS| Constructor and Description |
|---|
UnmappedTerms(StreamInput in)
Read from a stream.
|
UnmappedTerms(java.lang.String name,
Terms.Order order,
int requiredSize,
long minDocCount,
java.util.List<PipelineAggregator> pipelineAggregators,
java.util.Map<java.lang.String,java.lang.Object> metaData) |
| Modifier and Type | Method and Description |
|---|---|
UnmappedTerms |
create(java.util.List<UnmappedTerms.Bucket> buckets)
Create a new copy of this
Aggregation with the same settings as
this Aggregation and contains the provided buckets. |
protected UnmappedTerms |
create(java.lang.String name,
java.util.List<UnmappedTerms.Bucket> buckets,
long docCountError,
long otherDocCount) |
UnmappedTerms.Bucket |
createBucket(InternalAggregations aggregations,
UnmappedTerms.Bucket prototype)
Create a new
InternalMultiBucketAggregation.InternalBucket using the provided prototype bucket
and aggregations. |
protected UnmappedTerms.Bucket[] |
createBucketsArray(int size)
Create an array to hold some buckets.
|
InternalAggregation |
doReduce(java.util.List<InternalAggregation> aggregations,
InternalAggregation.ReduceContext reduceContext) |
XContentBuilder |
doXContentBody(XContentBuilder builder,
ToXContent.Params params) |
UnmappedTerms.Bucket |
getBucketByKey(java.lang.String term)
Get the bucket for the given term, or null if there is no such bucket.
|
java.util.List<UnmappedTerms.Bucket> |
getBuckets()
Return the sorted list of the buckets in this terms aggregation.
|
long |
getDocCountError()
Get an upper bound of the error on document counts in this aggregation.
|
protected int |
getShardSize() |
long |
getSumOfOtherDocCounts()
Return the sum of the document counts of all buckets that did not make
it to the top buckets.
|
java.lang.String |
getType() |
java.lang.String |
getWriteableName()
Returns the name of the writeable object
|
protected void |
setDocCountError(long docCountError) |
protected void |
writeTermTypeInfoTo(StreamOutput out) |
doWriteTo, doXContentCommongetPropertygetMetaData, getName, getProperty, pipelineAggregators, readSize, reduce, toXContent, writeSize, writeToclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetMetaData, getNameisFragment, toXContentpublic static final java.lang.String NAME
public UnmappedTerms(java.lang.String name,
Terms.Order order,
int requiredSize,
long minDocCount,
java.util.List<PipelineAggregator> pipelineAggregators,
java.util.Map<java.lang.String,java.lang.Object> metaData)
public UnmappedTerms(StreamInput in) throws java.io.IOException
java.io.IOExceptionprotected void writeTermTypeInfoTo(StreamOutput out) throws java.io.IOException
writeTermTypeInfoTo in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>java.io.IOExceptionpublic java.lang.String getWriteableName()
NamedWriteablepublic java.lang.String getType()
getType in interface AggregationgetType in class InternalAggregationpublic UnmappedTerms create(java.util.List<UnmappedTerms.Bucket> buckets)
InternalMultiBucketAggregationAggregation with the same settings as
this Aggregation and contains the provided buckets.create in class InternalMultiBucketAggregation<UnmappedTerms,UnmappedTerms.Bucket>buckets - the buckets to use in the new AggregationAggregationpublic UnmappedTerms.Bucket createBucket(InternalAggregations aggregations, UnmappedTerms.Bucket prototype)
InternalMultiBucketAggregationInternalMultiBucketAggregation.InternalBucket using the provided prototype bucket
and aggregations.createBucket in class InternalMultiBucketAggregation<UnmappedTerms,UnmappedTerms.Bucket>aggregations - the aggregations for the new bucketprototype - the bucket to use as a prototypeprotected UnmappedTerms create(java.lang.String name, java.util.List<UnmappedTerms.Bucket> buckets, long docCountError, long otherDocCount)
create in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>public InternalAggregation doReduce(java.util.List<InternalAggregation> aggregations, InternalAggregation.ReduceContext reduceContext)
doReduce in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>public final XContentBuilder doXContentBody(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
doXContentBody in class InternalAggregationjava.io.IOExceptionprotected void setDocCountError(long docCountError)
setDocCountError in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>protected int getShardSize()
getShardSize in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>public long getDocCountError()
Termspublic long getSumOfOtherDocCounts()
Termspublic java.util.List<UnmappedTerms.Bucket> getBuckets()
TermsgetBuckets in interface MultiBucketsAggregationgetBuckets in interface TermsgetBuckets in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>public UnmappedTerms.Bucket getBucketByKey(java.lang.String term)
TermsgetBucketByKey in interface TermsgetBucketByKey in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>protected UnmappedTerms.Bucket[] createBucketsArray(int size)
InternalTermscreateBucketsArray in class InternalTerms<UnmappedTerms,UnmappedTerms.Bucket>