-
- All Implemented Interfaces:
-
org.readium.r2.shared.util.SuspendingCloseable
public interface SearchIterator implements SuspendingCloseable
Iterates through search results.
-
-
Method Summary
Modifier and Type Method Description abstract Try<LocatorCollection, SearchError>next()Retrieves the next page of results. Unitclose()Closes any resources allocated for the search query, such as a cursor. Try<Unit, SearchError>forEach(Function1<LocatorCollection, Unit> action)Performs the given operation on each result page of this SearchIterator. IntegergetResultCount()-
-
Method Detail
-
next
abstract Try<LocatorCollection, SearchError> next()
Retrieves the next page of results.
-
close
Unit close()
Closes any resources allocated for the search query, such as a cursor. To be called when the user dismisses the search.
-
forEach
Try<Unit, SearchError> forEach(Function1<LocatorCollection, Unit> action)
Performs the given operation on each result page of this SearchIterator.
-
getResultCount
Integer getResultCount()
-
-
-
-