Paginator
interface Paginator (View source)
Methods
Get the URL for a given page.
Add a set of query string values to the paginator.
Get / set the URL fragment to be appended to URLs.
The the URL for the next page, or null.
Get the URL for the previous page, or null.
Get all of the items being paginated.
Get the "index" of the first item being paginated.
Get the "index" of the last item being paginated.
Determine how many items are being shown per page.
Determine the current page being paginated.
Determine if there are enough items to split into multiple pages.
Determine if there is more items in the data store.
Determine if the list of items is empty or not.
Details
at line 11
string
url(int $page)
Get the URL for a given page.
at line 20
$this
appends(array|string $key, string|null $value = null)
Add a set of query string values to the paginator.
at line 28
$this|string
fragment(string|null $fragment = null)
Get / set the URL fragment to be appended to URLs.
at line 35
string|null
nextPageUrl()
The the URL for the next page, or null.
at line 42
string|null
previousPageUrl()
Get the URL for the previous page, or null.
at line 49
array
items()
Get all of the items being paginated.
at line 56
int
firstItem()
Get the "index" of the first item being paginated.
at line 63
int
lastItem()
Get the "index" of the last item being paginated.
at line 70
int
perPage()
Determine how many items are being shown per page.
at line 77
int
currentPage()
Determine the current page being paginated.
at line 84
bool
hasPages()
Determine if there are enough items to split into multiple pages.
at line 91
bool
hasMorePages()
Determine if there is more items in the data store.
at line 98
bool
isEmpty()
Determine if the list of items is empty or not.