PaginatedCollection
class PaginatedCollection extends Collection (View source)
Properties
| protected int | $total | The total number of items. |
Methods
paginate(int $perPage = 15, int|null $page = null, string $pageName = 'page', bool $prepaginated = false)
Paginate the current collection.
paginator(Collection $items, int $total, int $perPage, int|null $currentPage, string $pageName)
Create a new length-aware paginator instance.
int|null
total(int|null $total = null)
Get or set the total amount.
Details
LengthAwarePaginator
paginate(int $perPage = 15, int|null $page = null, string $pageName = 'page', bool $prepaginated = false)
Paginate the current collection.
protected LengthAwarePaginator
paginator(Collection $items, int $total, int $perPage, int|null $currentPage, string $pageName)
Create a new length-aware paginator instance.
int|null
total(int|null $total = null)
Get or set the total amount.