java.lang.Object
com.amazonaws.services.cloudsearchdomain.model.Hits
All Implemented Interfaces:
Serializable, Cloneable

public class Hits extends Object implements Serializable, Cloneable

The collection of documents that match the search request.

See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
     
    boolean
     
    A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
    The total number of documents that match the search request.
    A document that matches the search request.
    The index of the first matching document.
    int
     
    void
    setCursor(String cursor)
    A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
    void
    setFound(Long found)
    The total number of documents that match the search request.
    void
    A document that matches the search request.
    void
    setStart(Long start)
    The index of the first matching document.
    Returns a string representation of this object; useful for testing and debugging.
    A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
    withFound(Long found)
    The total number of documents that match the search request.
    withHit(Hit... hit)
    A document that matches the search request.
    A document that matches the search request.
    withStart(Long start)
    The index of the first matching document.

    Methods inherited from class java.lang.Object

    finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Hits

      public Hits()
  • Method Details

    • setFound

      public void setFound(Long found)

      The total number of documents that match the search request.

      Parameters:
      found - The total number of documents that match the search request.
    • getFound

      public Long getFound()

      The total number of documents that match the search request.

      Returns:
      The total number of documents that match the search request.
    • withFound

      public Hits withFound(Long found)

      The total number of documents that match the search request.

      Parameters:
      found - The total number of documents that match the search request.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setStart

      public void setStart(Long start)

      The index of the first matching document.

      Parameters:
      start - The index of the first matching document.
    • getStart

      public Long getStart()

      The index of the first matching document.

      Returns:
      The index of the first matching document.
    • withStart

      public Hits withStart(Long start)

      The index of the first matching document.

      Parameters:
      start - The index of the first matching document.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setCursor

      public void setCursor(String cursor)

      A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.

      Parameters:
      cursor - A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
    • getCursor

      public String getCursor()

      A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.

      Returns:
      A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
    • withCursor

      public Hits withCursor(String cursor)

      A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.

      Parameters:
      cursor - A cursor that can be used to retrieve the next set of matching documents when you want to page through a large result set.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • getHit

      public List<Hit> getHit()

      A document that matches the search request.

      Returns:
      A document that matches the search request.
    • setHit

      public void setHit(Collection<Hit> hit)

      A document that matches the search request.

      Parameters:
      hit - A document that matches the search request.
    • withHit

      public Hits withHit(Hit... hit)

      A document that matches the search request.

      NOTE: This method appends the values to the existing list (if any). Use setHit(java.util.Collection) or withHit(java.util.Collection) if you want to override the existing values.

      Parameters:
      hit - A document that matches the search request.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • withHit

      public Hits withHit(Collection<Hit> hit)

      A document that matches the search request.

      Parameters:
      hit - A document that matches the search request.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      public Hits clone()
      Overrides:
      clone in class Object