make Iterable
inline fun <T> makeIterable(noinline countGetter: () -> Long, pageSize: Int = defaultPaginationPageSize, noinline paginationResultGetter: Pagination.() -> PaginationResult<T>): Iterable<T>(source)
Creates an Iterable that lazily fetches items from a paginated data source. This is useful for iterating over large datasets without loading all items into memory at once.
Return
An Iterable that can be used in for-loops or other iterable contexts
Parameters
count Getter
A function that returns the total count of available items
page Size
The size of each page to fetch. Defaults to defaultPaginationPageSize
pagination Result Getter
A function that fetches a page of results for a given pagination
Type Parameters
T
The type of items being iterated