本文整理汇总了PHP中DefaultController::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP DefaultController::__construct方法的具体用法?PHP DefaultController::__construct怎么用?PHP DefaultController::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DefaultController
的用法示例。
在下文中一共展示了DefaultController::__construct方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct()
{
parent::__construct();
# initialize the Perms controller
$this->_model = new Perms();
$this->activeSection = 'perms';
}
示例2: __construct
public function __construct()
{
parent::__construct();
if (!isset($this->cache) || !is_array($this->cache)) {
static::raiseError(__METHOD__ . '(), $cache property is not an array!', true);
return;
}
if (!isset($this->cache_index) || !is_array($this->cache_index)) {
static::raiseError(__METHOD__ . '(), $cache_index property is not an array!', true);
return;
}
}
示例3: __construct
public function __construct()
{
if (!$this->removeExpiredJobs()) {
static::raiseError('removeExpiredJobs() returned false!', true);
return false;
}
try {
$this->registerHandler('delete-request', array($this, 'handleDeleteRequest'));
$this->registerHandler('save-request', array($this, 'handleSaveRequest'));
} catch (\Exception $e) {
static::raiseError(__METHOD__ . '(), failed to register handlers!', true);
return false;
}
// Define the JSON errors.
$constants = get_defined_constants(true);
$this->json_errors = array();
foreach ($constants["json"] as $name => $value) {
if (!strncmp($name, "JSON_ERROR_", 11)) {
$this->json_errors[$value] = $name;
}
}
parent::__construct();
return true;
}
示例4: __construct
public function __construct(SearchModel $model)
{
parent::__construct($model);
$this->model = $model;
}
示例5: __construct
public function __construct(ProfileModel $model)
{
parent::__construct($model);
$this->model = $model;
}
示例6: __construct
public function __construct(DefaultModel $model)
{
parent::__construct($model);
$this->model = $model;
}
示例7: __construct
public function __construct(SubdescriptionModel $model)
{
parent::__construct($model);
$this->model = $model;
}
示例8: __construct
public function __construct(CheckOrderModel $model)
{
parent::__construct($model);
$this->model = $model;
}