$_emoji
$_emoji : \BEAR_Emoji
Smartyビューアダプター
BEARフレームワークで使われる基底クラスです。
BEARのクラスはBEAR::factoryやBEAR::dependency()によって以下の順でインスタンス化されます。
1) コンストラクタで設定を行う 2) 設定に基づいてインジェクタで必要なサービスをプロパティに用意
$_emoji : \BEAR_Emoji
$_log : \BEAR_Log
display(string $tplName = null, array $options = array()) : \BEAR_Ro
表示
ビューにセットされたバリューをテンプレートに適用して画面表示するHTTPボディとHTTPヘッダーを返します
string | $tplName | テンプレート名 |
array | $options | オプション |
_getRoleFile(array $role, string $dir, string $fileName, string $ext = 'tpl') : string
エージェントロールに対応したファイルを取得
配列でロールに応じたファイルを返します ex) roleが'Docomo'の場合 index.docomo.html index.mobile.html index.html というファイルに順にスキャンしてあればそれが使われます。Parameters
array | $role | エージェントロール |
string | $dir | ディレクトリパス |
string | $fileName | ファイル名ベース |
string | $ext | ファイル名拡張子 |
_exception(string $msg, array $config = array()) : \BEAR_Exception
例外の作成
string | $msg | 例外メッセージ |
array | $config | 例外config |
_getTemplateNameByPageClass(string $tplName) : string
ページクラスからパスを取得する
/はじまりだと絶対パス、テンプレート名省略または相対パスなら ページクラスからパス名を組み立てます。相対パスでテンプレートを 指定していれば指定したものにおきかわる。 例 絶対パス '/index.tpl' => '/index' '/some/index.tpl' => '/some/index' 相対パス Sample_Test_Pageクラスの場合 '' => 'sample/test/page' 'help.tpl' => 'sample/test/help' 'another/help.tpl' => 'sample/test/another/help'
string | $tplName | テンプレート名 |