Class SearchResponseSections

  • All Implemented Interfaces:
    ToXContent, ToXContentFragment
    Direct Known Subclasses:

    public class SearchResponseSections
    extends java.lang.Object
    implements ToXContentFragment
    Base class that holds the various sections which a search response is composed of (hits, aggs, suggestions etc.) and allows to retrieve them. The reason why this class exists is that the high level REST client uses its own classes to parse aggregations into, which are not serializable. This is the common part that can be shared between core and client.
    • Field Detail

      • suggest

        protected final Suggest suggest
      • timedOut

        protected final boolean timedOut
      • terminatedEarly

        protected final java.lang.Boolean terminatedEarly
      • numReducePhases

        protected final int numReducePhases
    • Method Detail

      • timedOut

        public final boolean timedOut()
      • terminatedEarly

        public final java.lang.Boolean terminatedEarly()
      • suggest

        public final Suggest suggest()
      • getNumReducePhases

        public final int getNumReducePhases()
        Returns the number of reduce phases applied to obtain this search response
      • profile

        public final java.util.Map<java.lang.String,​ProfileShardResult> profile()
        Returns the profile results for this search response (including all shards). An empty map is returned if profiling was not enabled
        Profile results
      • writeTo

        protected void writeTo​(StreamOutput out)