Class GroupingLevel

  • All Implemented Interfaces:
    java.lang.Cloneable

    public class GroupingLevel
    extends com.yahoo.vespa.objects.Identifiable
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int classId  
    • Constructor Summary

      Constructors 
      Constructor Description
      GroupingLevel()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      GroupingLevel clone()  
      boolean equals​(java.lang.Object obj)  
      ExpressionNode getExpression()
      Returns the expression used to classify hits into groups.
      Group getGroupPrototype()
      Returns the prototype to use when creating groups at this level.
      long getMaxGroups()
      Returns the maximum number of groups allowed at this level.
      long getPrecision()
      Returns the presicion (i.e number of groups) returned up from this level.
      int hashCode()  
      boolean needResultCollection()
      Tell if ordering will need results collected in children.
      protected void onDeserialize​(com.yahoo.vespa.objects.Deserializer buf)  
      protected int onGetClassId()  
      protected void onSerialize​(com.yahoo.vespa.objects.Serializer buf)  
      GroupingLevel setExpression​(ExpressionNode exp)
      Sets the expression used to classify hits into groups.
      GroupingLevel setGroupPrototype​(Group group)
      Sets the prototype to use when creating groups at this level.
      GroupingLevel setMaxGroups​(long max)
      Sets the maximum number of groups allowed at this level.
      GroupingLevel setPrecision​(long precision)
      Sets the presicion (i.e number of groups) returned up from this level.
      void visitMembers​(com.yahoo.vespa.objects.ObjectVisitor visitor)  
      • Methods inherited from class com.yahoo.vespa.objects.Identifiable

        create, createFromId, deserialize, deserializeOptional, deserializeWithId, equals, getClassId, getUtf8, putUtf8, registerClass, serialize, serializeOptional, serializeWithId, toString
      • Methods inherited from class com.yahoo.vespa.objects.Selectable

        select, select, selectMembers
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • classId

        public static final int classId
    • Constructor Detail

      • GroupingLevel

        public GroupingLevel()
    • Method Detail

      • getPrecision

        public long getPrecision()

        Returns the presicion (i.e number of groups) returned up from this level.

        Returns:
        The precision.
      • getMaxGroups

        public long getMaxGroups()

        Returns the maximum number of groups allowed at this level.

        Returns:
        The maximum number.
      • setMaxGroups

        public GroupingLevel setMaxGroups​(long max)

        Sets the maximum number of groups allowed at this level.

        Parameters:
        max - The maximum number to set.
        Returns:
        This, to allow chaining.
      • setPrecision

        public GroupingLevel setPrecision​(long precision)

        Sets the presicion (i.e number of groups) returned up from this level.

        Parameters:
        precision - The precision to set.
        Returns:
        This, to allow chaining.
      • getExpression

        public ExpressionNode getExpression()

        Returns the expression used to classify hits into groups.

        Returns:
        The classifier expression.
      • setExpression

        public GroupingLevel setExpression​(ExpressionNode exp)

        Sets the expression used to classify hits into groups.

        Parameters:
        exp - The classifier expression to set.
        Returns:
        This, to allow chaining.
      • setGroupPrototype

        public GroupingLevel setGroupPrototype​(Group group)

        Sets the prototype to use when creating groups at this level.

        Parameters:
        group - The group prototype.
        Returns:
        This, to allow chaining.
      • getGroupPrototype

        public Group getGroupPrototype()

        Returns the prototype to use when creating groups at this level.

        Returns:
        The group prototype.
      • needResultCollection

        public boolean needResultCollection()

        Tell if ordering will need results collected in children.

        Returns:
        If deeper resultcollection is needed.
      • onGetClassId

        protected int onGetClassId()
        Overrides:
        onGetClassId in class com.yahoo.vespa.objects.Identifiable
      • onSerialize

        protected void onSerialize​(com.yahoo.vespa.objects.Serializer buf)
        Overrides:
        onSerialize in class com.yahoo.vespa.objects.Identifiable
      • onDeserialize

        protected void onDeserialize​(com.yahoo.vespa.objects.Deserializer buf)
        Overrides:
        onDeserialize in class com.yahoo.vespa.objects.Identifiable
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class com.yahoo.vespa.objects.Identifiable
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class com.yahoo.vespa.objects.Identifiable
      • clone

        public GroupingLevel clone()
        Overrides:
        clone in class com.yahoo.vespa.objects.Identifiable
      • visitMembers

        public void visitMembers​(com.yahoo.vespa.objects.ObjectVisitor visitor)
        Overrides:
        visitMembers in class com.yahoo.vespa.objects.Identifiable