Class GeoPage<T>
- All Implemented Interfaces:
Serializable
,Iterable<GeoResult<T>>
,Supplier<Stream<GeoResult<T>>>
,Page<GeoResult<T>>
,Slice<GeoResult<T>>
,Streamable<GeoResult<T>>
- Since:
- 1.8
- Author:
- Oliver Gierke, Thomas Darimont
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGeoPage
(GeoResults<T> results) Creates a newGeoPage
from the givenGeoResults
.GeoPage
(GeoResults<T> results, Pageable pageable, long total) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns the page content asList
.protected <U> List
<U> getConvertedContent
(Function<? super GeoResult<T>, ? extends U> converter) int
Returns the number of the currentSlice
.int
Returns the number of elements currently on thisSlice
.int
getSize()
Returns the size of theSlice
.getSort()
Returns the sorting parameters for theSlice
.boolean
Returns whether theSlice
has content at all.int
hashCode()
boolean
Returns if there is a previousSlice
.boolean
isFirst()
Returns whether the currentSlice
is the first one.iterator()
Methods inherited from class org.springframework.data.domain.PageImpl
getTotalElements, getTotalPages, hasNext, isLast, map, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
Methods inherited from interface org.springframework.data.domain.Slice
getContent, getNumber, getNumberOfElements, getPageable, getSize, getSort, hasContent, hasPrevious, isFirst, nextOrLastPageable, nextPageable, previousOrFirstPageable, previousPageable
-
Constructor Details
-
GeoPage
Creates a newGeoPage
from the givenGeoResults
.- Parameters:
results
- must not be null.
-
GeoPage
- Parameters:
results
- must not be null.pageable
- must not be null.total
- total number of results.
-
-
Method Details
-
getAverageDistance
-
equals
-
hashCode
-
getNumber
-
getSize
-
getNumberOfElements
-
hasPrevious
-
isFirst
-
nextPageable
Description copied from interface:Slice
Returns thePageable
to request the nextSlice
. Can bePageable.unpaged()
in case the currentSlice
is already the last one. Clients should checkSlice.hasNext()
before calling this method.- Specified by:
nextPageable
in interfaceSlice<T>
- Returns:
- the
Pageable
to request the nextSlice
. - See Also:
-
previousPageable
Description copied from interface:Slice
Returns thePageable
to request the previousSlice
. Can bePageable.unpaged()
in case the currentSlice
is already the first one. Clients should checkSlice.hasPrevious()
before calling this method.- Specified by:
previousPageable
in interfaceSlice<T>
- Returns:
- the
Pageable
to request the previousSlice
. - See Also:
-
hasContent
-
getContent
-
getPageable
-
getSort
-
iterator
-
getConvertedContent
-