Class ResultNode

    • Field Summary

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

      Constructors 
      Constructor Description
      ResultNode()  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      int compareTo​(ResultNode b)  
      boolean equals​(Object obj)  
      abstract double getFloat()
      Returns the float representation of this result.
      abstract long getInteger()
      Returns the integer representation of this result.
      abstract byte[] getRaw()
      Returns the raw byte array representation of this result.
      abstract String getString()
      Returns the string representation of this result.
      void negate()
      Negate the value contained within the result node.
      protected abstract int onCmp​(ResultNode rhs)
      This method must be implemented by all subclasses of this to allow ordering of results.
      protected int onGetClassId()  
      protected abstract void set​(ResultNode rhs)
      This method must be implemented by all subclasses of this to allow new results to be calculated.
      • Methods inherited from class com.yahoo.vespa.objects.Identifiable

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

        select, select, selectMembers
    • Field Detail

      • classId

        public static final int classId
    • Constructor Detail

      • ResultNode

        public ResultNode()
    • Method Detail

      • onGetClassId

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

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

        protected abstract void set​(ResultNode rhs)
        This method must be implemented by all subclasses of this to allow new results to be calculated.
        Parameters:
        rhs - The node to get the result from.
      • onCmp

        protected abstract int onCmp​(ResultNode rhs)
        This method must be implemented by all subclasses of this to allow ordering of results. This method is used by the Cloneable implementation.
        Parameters:
        rhs - The other node to compare with.
        Returns:
        Comparable result.
      • getInteger

        public abstract long getInteger()
        Returns the integer representation of this result.
        Returns:
        The value of this.
      • getFloat

        public abstract double getFloat()
        Returns the float representation of this result.
        Returns:
        The value of this.
      • getString

        public abstract String getString()
        Returns the string representation of this result.
        Returns:
        The value of this.
      • getRaw

        public abstract byte[] getRaw()
        Returns the raw byte array representation of this result.
        Returns:
        The value of this.
      • negate

        public void negate()
        Negate the value contained within the result node.