PHP Class Elcodi\Store\PageBundle\Twig\PageExtension

Inheritance: extends Twig_Extensio\Twig_Extension
Show file Open project: elcodi/bamboo

Public Methods

Method Description
__construct ( Elcodi\Component\Page\Repository\PageRepository $pageRepository ) Construct
getBlogPages ( integer $page = 1, integer $numberPerPage = 10 ) : array Get blog pages
getFooterPages ( ) : array Get footer pages
getFunctions ( ) : Twig_SimpleFunctio\Twig_SimpleFunction[] Return all functions
getName ( ) : string return extension name

Method Details

__construct() public method

Construct
public __construct ( Elcodi\Component\Page\Repository\PageRepository $pageRepository )
$pageRepository Elcodi\Component\Page\Repository\PageRepository Page Repository

getBlogPages() public method

Get blog pages
public getBlogPages ( integer $page = 1, integer $numberPerPage = 10 ) : array
$page integer Page
$numberPerPage integer Number per page
return array Collection of enabled pages for the blog

getFooterPages() public method

Get footer pages
public getFooterPages ( ) : array
return array Collection of enabled pages for the footer

getFunctions() public method

Return all functions
public getFunctions ( ) : Twig_SimpleFunctio\Twig_SimpleFunction[]
return Twig_SimpleFunctio\Twig_SimpleFunction[] Functions

getName() public method

return extension name
public getName ( ) : string
return string extension name