public class Hits
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
The collection of documents that match the search request.
Modifier and Type | Field and Description |
---|---|
private java.lang.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.
|
private java.lang.Long |
found
The total number of documents that match the search request.
|
private SdkInternalList<Hit> |
hit
A document that matches the search request.
|
private java.lang.Long |
start
The index of the first matching document.
|
Constructor and Description |
---|
Hits() |
Modifier and Type | Method and Description |
---|---|
Hits |
clone() |
boolean |
equals(java.lang.Object obj) |
java.lang.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.
|
java.lang.Long |
getFound()
The total number of documents that match the search request.
|
java.util.List<Hit> |
getHit()
A document that matches the search request.
|
java.lang.Long |
getStart()
The index of the first matching document.
|
int |
hashCode() |
void |
setCursor(java.lang.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(java.lang.Long found)
The total number of documents that match the search request.
|
void |
setHit(java.util.Collection<Hit> hit)
A document that matches the search request.
|
void |
setStart(java.lang.Long start)
The index of the first matching document.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
Hits |
withCursor(java.lang.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.
|
Hits |
withFound(java.lang.Long found)
The total number of documents that match the search request.
|
Hits |
withHit(java.util.Collection<Hit> hit)
A document that matches the search request.
|
Hits |
withHit(Hit... hit)
A document that matches the search request.
|
Hits |
withStart(java.lang.Long start)
The index of the first matching document.
|
private java.lang.Long found
The total number of documents that match the search request.
private java.lang.Long start
The index of the first matching document.
private java.lang.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.
private SdkInternalList<Hit> hit
A document that matches the search request.
public void setFound(java.lang.Long found)
The total number of documents that match the search request.
found
- The total number of documents that match the search request.public java.lang.Long getFound()
The total number of documents that match the search request.
public Hits withFound(java.lang.Long found)
The total number of documents that match the search request.
found
- The total number of documents that match the search request.public void setStart(java.lang.Long start)
The index of the first matching document.
start
- The index of the first matching document.public java.lang.Long getStart()
The index of the first matching document.
public Hits withStart(java.lang.Long start)
The index of the first matching document.
start
- The index of the first matching document.public void setCursor(java.lang.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.
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.public java.lang.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.
public Hits withCursor(java.lang.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.
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.public java.util.List<Hit> getHit()
A document that matches the search request.
public void setHit(java.util.Collection<Hit> hit)
A document that matches the search request.
hit
- A document that matches the search request.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.
hit
- A document that matches the search request.public Hits withHit(java.util.Collection<Hit> hit)
A document that matches the search request.
hit
- A document that matches the search request.public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Hits clone()
clone
in class java.lang.Object