<?php
class PaginationWidget extends Widget
{
    /**
     * @var iWebPage
     */
    private $_pageObj = null;
    
    public $pageSize = 10;
    
    public $totalRecord;
    
    public function init()
    {
        parent::init();
        $this->_pageObj = new iWebPage();
    }
    
    public function run()
    {
        $this->getWebPage()->setTotalRecord($this->totalRecord);
        $this->getWebPage()->setPageSize($this->pageSize);
        $this->getWebPage()->show();
    }
    
    /*
     * @return iWebPage
     */
    public function getWebPage()
    {
        return $this->_pageObj;
    }
}