factory() public static method

Static method to instantiate the paginator object and return itself to facilitate chaining methods together.
public static factory ( array $items, integer $perPage = 10, integer $range = 10, integer $total = null ) : Paginator
$items array
$perPage integer
$range integer
$total integer
return Paginator
Example #1
0
 public function testConstructor()
 {
     $this->assertInstanceOf('Pop\\Paginator\\Paginator', new Paginator(array()));
     $this->assertInstanceOf('Pop\\Paginator\\Paginator', Paginator::factory(array()));
 }