public abstract static class InternalTerms.Bucket<B extends InternalTerms.Bucket<B>> extends InternalMultiBucketAggregation.InternalBucket implements Terms.Bucket
Modifier and Type | Class and Description |
---|---|
static interface |
InternalTerms.Bucket.Reader<B extends InternalTerms.Bucket<B>>
Reads a bucket.
|
MultiBucketsAggregation.Bucket.SubAggregationComparator<B extends MultiBucketsAggregation.Bucket>
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
Writeable.Writer<V>
Modifier and Type | Field and Description |
---|---|
protected InternalAggregations |
aggregations |
protected long |
docCount |
protected long |
docCountError |
protected DocValueFormat |
format |
protected boolean |
showDocCountError |
EMPTY_PARAMS
Modifier | Constructor and Description |
---|---|
protected |
Bucket(long docCount,
InternalAggregations aggregations,
boolean showDocCountError,
long docCountError,
DocValueFormat formatter) |
protected |
Bucket(StreamInput in,
DocValueFormat formatter,
boolean showDocCountError)
Read from a stream.
|
Modifier and Type | Method and Description |
---|---|
Aggregations |
getAggregations() |
long |
getDocCount() |
long |
getDocCountError() |
protected abstract XContentBuilder |
keyToXContent(XContentBuilder builder) |
B |
reduce(java.util.List<B> buckets,
InternalAggregation.ReduceContext context) |
XContentBuilder |
toXContent(XContentBuilder builder,
ToXContent.Params params) |
protected abstract void |
writeTermTo(StreamOutput out) |
void |
writeTo(StreamOutput out)
Write this into the StreamOutput.
|
getProperty
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compareTerm, getKeyAsNumber
getKey, getKeyAsString
isFragment
protected long docCount
protected long docCountError
protected InternalAggregations aggregations
protected final boolean showDocCountError
protected final DocValueFormat format
protected Bucket(long docCount, InternalAggregations aggregations, boolean showDocCountError, long docCountError, DocValueFormat formatter)
protected Bucket(StreamInput in, DocValueFormat formatter, boolean showDocCountError) throws java.io.IOException
java.io.IOException
public final void writeTo(StreamOutput out) throws java.io.IOException
Writeable
protected abstract void writeTermTo(StreamOutput out) throws java.io.IOException
java.io.IOException
public long getDocCount()
getDocCount
in interface MultiBucketsAggregation.Bucket
public long getDocCountError()
getDocCountError
in interface Terms.Bucket
public Aggregations getAggregations()
getAggregations
in interface MultiBucketsAggregation.Bucket
getAggregations
in interface HasAggregations
public B reduce(java.util.List<B> buckets, InternalAggregation.ReduceContext context)
public final XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
toXContent
in interface ToXContent
java.io.IOException
protected abstract XContentBuilder keyToXContent(XContentBuilder builder) throws java.io.IOException
java.io.IOException