\hymie\viewPHPView

php 视图

Summary

Methods
Properties
Constants
render()
getView()
getContentType()
setContentType()
getModel()
setModel()
__construct()
No public properties found
No constants found
header()
$contentType
N/A
No private methods found
$model
$viewRoot
$file
$module
N/A

Properties

$contentType

$contentType : string

默认的 content-type

Type

string

$model

$model : array

模型对象

Type

array

$viewRoot

$viewRoot : \hymie\view\[type]

视图根目录 默认是 app 目录

Type

\hymie\view\[type]

$file

$file : string

php 文件

Type

string

$module

$module : string

模块

Type

string

Methods

render()

render(\hymie\Result  $result) : void

渲染视图

Parameters

\hymie\Result $result

结果

getView()

getView(string  $module, string  $result) : void

获取视图的工厂方法

Parameters

string $module
string $result

getContentType()

getContentType() 

Get the value of contentType

setContentType()

setContentType(  $contentType) : self

Set the value of contentType

Parameters

$contentType

Returns

self

getModel()

getModel() 

Get the value of model

setModel()

setModel(  $model) : self

Set the value of model

Parameters

$model

Returns

self

__construct()

__construct(string  $module, string  $file) 

构造函数

Parameters

string $module

模块名

string $file

文件名 不带 .php 后缀

header()

header()