PHP 클래스 Bolt\Twig\Handler\WidgetHandler

파일 보기 프로젝트 열기: bolt/bolt 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( Silex\Application $app )
countWidgets ( string $location = null, string $zone = Zone::FRONTEND ) : integer Return the number of widgets in the queue for a given type / location.
getWidgets ( ) : array Gets a list of the registered widgets.
hasWidgets ( string $location = null, string $zone = Zone::FRONTEND ) : boolean Check if a type / location has widgets in the queue.
widgets ( string $location = null, string $zone = Zone::FRONTEND, string $wrapper = 'widgetwrapper.twig' ) : string | Twig_Markup Renders a particular widget type on the given location.

메소드 상세

__construct() 공개 메소드

public __construct ( Silex\Application $app )
$app Silex\Application

countWidgets() 공개 메소드

Return the number of widgets in the queue for a given type / location.
public countWidgets ( string $location = null, string $zone = Zone::FRONTEND ) : integer
$location string Location (e.g. 'dashboard_aside_top')
$zone string Either Zone::FRONTEND or Zone::BACKEND
리턴 integer

getWidgets() 공개 메소드

Gets a list of the registered widgets.
public getWidgets ( ) : array
리턴 array

hasWidgets() 공개 메소드

Check if a type / location has widgets in the queue.
public hasWidgets ( string $location = null, string $zone = Zone::FRONTEND ) : boolean
$location string Location (e.g. 'dashboard_aside_top')
$zone string Either Zone::FRONTEND or Zone::BACKEND
리턴 boolean

widgets() 공개 메소드

Renders a particular widget type on the given location.
public widgets ( string $location = null, string $zone = Zone::FRONTEND, string $wrapper = 'widgetwrapper.twig' ) : string | Twig_Markup
$location string Location (e.g. 'dashboard_aside_top')
$zone string Either Zone::FRONTEND or Zone::BACKEND
$wrapper string
리턴 string | Twig_Markup