Class RatedSearchHit

java.lang.Object
org.opensearch.index.rankeval.RatedSearchHit
All Implemented Interfaces:
Writeable, org.opensearch.core.xcontent.ToXContent, org.opensearch.core.xcontent.ToXContentObject

public class RatedSearchHit extends Object implements Writeable, org.opensearch.core.xcontent.ToXContentObject
Combines a SearchHit with a document rating.
  • Constructor Details

  • Method Details

    • writeTo

      public void writeTo(StreamOutput out) throws IOException
      Specified by:
      writeTo in interface Writeable
      Throws:
      IOException
    • getSearchHit

      public SearchHit getSearchHit()
    • getRating

      public OptionalInt getRating()
    • toXContent

      public org.opensearch.core.xcontent.XContentBuilder toXContent(org.opensearch.core.xcontent.XContentBuilder builder, org.opensearch.core.xcontent.ToXContent.Params params) throws IOException
      Specified by:
      toXContent in interface org.opensearch.core.xcontent.ToXContent
      Throws:
      IOException
    • parse

      public static RatedSearchHit parse(org.opensearch.core.xcontent.XContentParser parser) throws IOException
      Throws:
      IOException
    • equals

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

      public final int hashCode()
      Overrides:
      hashCode in class Object