Class Aggregations

org.elasticsearch.search.aggregations.Aggregations
All Implemented Interfaces:
<Aggregation>, org.elasticsearch.common.xcontent.ToXContent, org.elasticsearch.common.xcontent.ToXContentFragment
Direct Known Subclasses:
InternalAggregations

public class Aggregations extends implements <Aggregation>, org.elasticsearch.common.xcontent.ToXContentFragment
Represents a set of Aggregations
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent

    org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.Params
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected <? extends Aggregation>
     
    static
     

    Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent

    EMPTY_PARAMS
  • Constructor Summary

    Constructors
    Constructor
    Description
    <? extends Aggregation> aggregations)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    The list of Aggregations.
    Returns the Aggregations keyed by aggregation name.
    boolean
     obj)
     
    fromXContent​(org.elasticsearch.common.xcontent.XContentParser parser)
     
    <A extends Aggregation>
    A
     name)
    Returns the aggregation that is associated with the specified name.
    Returns the Aggregations keyed by aggregation name.
    int
     
    Iterates over the Aggregations.
    org.elasticsearch.common.xcontent.XContentBuilder
    toXContent​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
     
    org.elasticsearch.common.xcontent.XContentBuilder
    toXContentInternal​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
    Directly write all the aggregations without their bounding object.

    Methods inherited from class java.lang.

    , , , , , , , ,

    Methods inherited from interface java.lang.

    ,

    Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentFragment

    isFragment
  • Field Details

    • AGGREGATIONS_FIELD

      public static final  AGGREGATIONS_FIELD
      See Also:
      Constant Field Values
    • aggregations

      protected final <? extends Aggregation> aggregations
  • Constructor Details

    • Aggregations

      public Aggregations(<? extends Aggregation> aggregations)
  • Method Details

    • iterator

      public final <Aggregation> iterator()
      Iterates over the Aggregations.
      Specified by:
       in interface <Aggregation>
    • asList

      public final <Aggregation> asList()
      The list of Aggregations.
    • asMap

      public final <,​Aggregation> asMap()
      Returns the Aggregations keyed by aggregation name.
    • getAsMap

      public final <,​Aggregation> getAsMap()
      Returns the Aggregations keyed by aggregation name.
    • get

      public final <A extends  name)
      Returns the aggregation that is associated with the specified name.
    • equals

      public final boolean equals( obj)
      Overrides:
       in class 
    • hashCode

      public final int hashCode()
      Overrides:
       in class 
    • toXContent

      public org.elasticsearch.common.xcontent.XContentBuilder toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws
      Specified by:
      toXContent in interface org.elasticsearch.common.xcontent.ToXContent
      Throws:
    • toXContentInternal

      public org.elasticsearch.common.xcontent.XContentBuilder toXContentInternal(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws
      Directly write all the aggregations without their bounding object. Used by sub-aggregations (non top level aggs)
      Throws:
    • fromXContent

      public static Aggregations fromXContent(org.elasticsearch.common.xcontent.XContentParser parser) throws
      Throws: