PHP 클래스 Phlyty\View\MustacheViewModel
The main purpose of this class is to provide the view model with the App
instance, thus giving it access to the various helper methods available in
that class. Additionally, it provides an instance of Escaper, allowing you
to do context-specific escaping within helpers you define in the view model.
파일 보기
프로젝트 열기: phly/phlyty
1 사용 예제들
보호된 프로퍼티들
공개 메소드들
메소드 |
설명 |
|
__app ( ) : App |
Retrieve application instance |
|
__construct ( App $app, Zend\Escaper\Escaper $escaper = null ) |
Constructor |
|
__escaper ( ) : Zend\Escaper\Escaper |
Retrieve escaper instance |
|
bindHelper ( string $name, callable $helper ) : MustacheViewModel |
Bind a helper within the view model object's context |
|
메소드 상세
Retrieve application instance
public __app ( ) : App |
리턴 |
Phlyty\App |
|
Receive and set the App instance as a protected property.
If an Escaper instance is passed, it will be assigned;
otherwise, an Escaper instance will be instantiated and
assigned.
public __construct ( App $app, Zend\Escaper\Escaper $escaper = null ) |
$app |
Phlyty\App |
|
$escaper |
Zend\Escaper\Escaper |
|
Retrieve escaper instance
public __escaper ( ) : Zend\Escaper\Escaper |
리턴 |
Zend\Escaper\Escaper |
|
Allows using '$this' within the helper in order to access public
properties and methods. Binds the helper to the public property
given by $name.
프로퍼티 상세
protected App,Phlyty $app |
리턴 |
Phlyty\App |
|
protected Escaper,Zend\Escaper $escaper |
리턴 |
Zend\Escaper\Escaper |
|