ExtendedInformationPager
extends Pager
in package
ExtendedInformationPager
Table of Contents
- $offset : int
- $page : int
- $pageParameter : string
- $perPage : int
- $totalItemCount : int
- __construct() : mixed
- ExtendedInformationPager constructor.
- create() : Pager
- Named constructor of pager.
- createCustom() : Pager
- Named constructor of pager.
- createExtendedInformationPager() : ExtendedInformationPager
- Named constructor of extended information pager.
- getPages() : array<string|int, mixed>
- Get the all pages as an array with the following information: [ [ 'page' => 1, 'text' => 1, 'title' => 1 ] ]
- highestOnPage() : int
- Gets the highest item of the current page.
- isFirstPage() : bool
- Returns true if the current page is the first page.
- isLastPage() : bool
- Returns true if the current page is the last page.
- lowestOnPage() : int
- Gets the lowest item of the current page.
- offset() : int
- Returns the offset.
- page() : int
- Returns the current page.
- pageParameter() : string
- Gets the name of the page parameter.
- perPage() : int
- Returns the items count per page.
- totalItemCount() : int
- Gets the total number of items.
- totalPageCount() : int
- Gets the total number of pages.
Properties
$offset
protected
int
$offset
$page
protected
int
$page
$pageParameter
protected
string
$pageParameter
$perPage
protected
int
$perPage
$totalItemCount
protected
int
$totalItemCount
Methods
__construct()
ExtendedInformationPager constructor.
public
__construct(IntType $page, IntType $perPage, IntType $totalItemCount, StringType $pageParameter) : mixed
Parameters
- $page : IntType
- $perPage : IntType
- $totalItemCount : IntType
- $pageParameter : StringType
Return values
mixed —create()
Named constructor of pager.
public
static create(int $page, int $perPage) : Pager
Parameters
- $page : int
-
Current page.
- $perPage : int
-
Items per page.
Tags
Return values
Pager —New instance.
createCustom()
Named constructor of pager.
public
static createCustom(mixed $offset, mixed $limit) : Pager
Parameters
- $offset : mixed
- $limit : mixed
Tags
Return values
Pager —New instance.
createExtendedInformationPager()
Named constructor of extended information pager.
public
static createExtendedInformationPager(int $page, int $perPage, int $totalItemCount, string $pageParameter) : ExtendedInformationPager
Parameters
- $page : int
-
Current page.
- $perPage : int
-
Items per page.
- $totalItemCount : int
-
Total number of items.
- $pageParameter : string
-
The name of the page parameter
Tags
Return values
ExtendedInformationPager —New instance.
getPages()
Get the all pages as an array with the following information: [ [ 'page' => 1, 'text' => 1, 'title' => 1 ] ]
public
getPages() : array<string|int, mixed>
Return values
array<string|int, mixed> —highestOnPage()
Gets the highest item of the current page.
public
highestOnPage() : int
Return values
int —isFirstPage()
Returns true if the current page is the first page.
public
isFirstPage() : bool
Return values
bool —isLastPage()
Returns true if the current page is the last page.
public
isLastPage() : bool
Return values
bool —lowestOnPage()
Gets the lowest item of the current page.
public
lowestOnPage() : int
Return values
int —offset()
Returns the offset.
public
offset() : int
Return values
int —page()
Returns the current page.
public
page() : int
Return values
int —pageParameter()
Gets the name of the page parameter.
public
pageParameter() : string
Return values
string —perPage()
Returns the items count per page.
public
perPage() : int
Return values
int —totalItemCount()
Gets the total number of items.
public
totalItemCount() : int
Return values
int —totalPageCount()
Gets the total number of pages.
public
totalPageCount() : int