Package com.datastax.astra.client.model
Class Page<R>
java.lang.Object
com.datastax.astra.client.model.Page<R>
- Type Parameters:
R
- document type
Hold results for paging
- Author:
- Cedrick LUNVEN (@clunven)
-
Field Summary
Modifier and TypeFieldDescriptionprotected float[]
Sort vector retrieved in the status. -
Constructor Summary
-
Method Summary
-
Field Details
-
sortVector
protected float[] sortVectorSort vector retrieved in the status.
-
-
Constructor Details
-
Page
Default constructor.- Parameters:
pageState
- page state with the offset of the pageresults
- List list of items for the pagesortVector
- float[] the sort vector if asked.
-
-
Method Details
-
isEmpty
public boolean isEmpty()Express if results is empty.- Returns:
- return value
-
findFirst
Expected from a stream of result.- Returns:
- first result if exist
-
one
When the result is a singleton.- Returns:
- result as a singleton
-
getPageState
Getter accessor for attribute 'pageState'.- Returns:
- current value of 'pageState'
-
getSortVector
If the sort Vector has been retrieved in the status, it will be available here.- Returns:
- sort vector if available
-