From 70b13a597b5d16abb250a743e76bd53bf56d99c5 Mon Sep 17 00:00:00 2001 From: Ryann Micua Date: Thu, 29 Aug 2013 11:30:13 +0800 Subject: [PATCH] update PageArray methods to include setTotal(), setLimit() and setStart() methods --- index.html | 3 +++ 1 file changed, 3 insertions(+) diff --git a/index.html b/index.html index 7a5921d..15e6261 100644 --- a/index.html +++ b/index.html @@ -192,8 +192,11 @@

PageArray / WireArray

PageArray only

$a->getTotal() Get the total number of pages that were found from a $pages->find("selectors, limit=n") operation that led to this PageArray. The number returned may be greater than the number of pages actually in this PageArray instance, and is used for calculating pagination. Whereas $p->count() will always return the number of pages actually in this PageArray instance.

+

$a->setTotal($total) Manually set the total number of pages in this PageArray. Used for calculating pagination.

$a->getLimit() Get the number (n) from a "limit=n" portion of a selector that resulted in this PageArray. In pagination, this value represents the max items to display per page. If there was no limit applied, this will return 0.

+

$a->setLimit($numLimit) Set the imposed limit on this PageArray. Used for pagination.

$a->getStart() Get the number of the starting result that led to this PageArray in pagination. Returns 0 if in the first page of results.

+

$a->setStart($numStart) Set the 'start' limitor that resulted in this PageArray.

$a->getSelectors() Return the Selectors that led to this PageArray, or null if not set/applicable. Returns an instance of Selectors (WireArray) containing one or more Selector objects.