original_string: public function build(array $data = array())
      {
          $data += array(
              'page' => 1,
              'limit' => 0,
              'total' => 0,
              'mini' => false,
              'max_pages' => 10,
              'query' => array()
          );
  
          $this->setPage($data['page'])
              ->setPerPage($data['limit'])
              ->setTotal($data['total'])
              ->setMaxPages($data['max_pages'])
              ->setUrlPattern('?' . urldecode(http_build_query($data['query'])));
  
          return $this;
      }
code: public function build(array $data = array())
      {
          $data += array(
              'page' => 1,
              'limit' => 0,
              'total' => 0,
              'mini' => false,
              'max_pages' => 10,
              'query' => array()
          );
  
          $this->setPage($data['page'])
              ->setPerPage($data['limit'])
              ->setTotal($data['total'])
              ->setMaxPages($data['max_pages'])
              ->setUrlPattern('?' . urldecode(http_build_query($data['query'])));
  
          return $this;
      }
code_tokens: public function build ( array $ data = array ( ) ) { $ data += array ( 'page' => 1 , 'limit' => 0 , 'total' => 0 , 'mini' => false , 'max_pages' => 10 , 'query' => array ( ) ) ; $ this -> setPage ( $ data [ 'page' ] ) -> setPerPage ( $ data [ 'limit' ] ) -> setTotal ( $ data [ 'total' ] ) -> setMaxPages ( $ data [ 'max_pages' ] ) -> setUrlPattern ( '?' . urldecode ( http_build_query ( $ data [ 'query' ] ) ) ) ; return $ this ; }
docstring: Set up pager from an array of parameters
  @param array $data
  @return $this
docstring_tokens: Set up pager from an array of parameters