本文整理匯總了PHP中__Config::getAllAsArray方法的典型用法代碼示例。如果您正苦於以下問題:PHP __Config::getAllAsArray方法的具體用法?PHP __Config::getAllAsArray怎麽用?PHP __Config::getAllAsArray使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類__Config
的用法示例。
在下文中一共展示了__Config::getAllAsArray方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: collect
/**
* {@inheritdoc}
*/
public function collect()
{
$application = org_glizy_ObjectValues::get('org.glizy', 'application');
$result = array();
$result['pageId'] = $application->getPageId();
$result['routing'] = __Request::get('__routingName__') . ' > ' . __Request::get('__routingPattern__');
$result['controllers'] = implode(', ', $this->calledControllers);
$user = $application->getCurrentUser();
$userData = array('id' => $user->id, 'firstName' => $user->firstName, 'lastName' => $user->lastName, 'email' => $user->email, 'groupId' => $user->groupId, 'backEndAccess' => $user->backEndAccess);
$result['user'] = $this->getDataFormatter()->formatVar($userData);
$menu = $application->getCurrentMenu();
$menuData = array('id' => $menu->id, 'title' => $menu->title, 'parentId' => $menu->parentId, 'pageType' => $menu->pageType, 'type' => $menu->type, 'depth' => $menu->depth);
$result['menu'] = $this->getDataFormatter()->formatVar($menuData);
// request
$data = __Request::getAllAsArray();
$tempData = array();
foreach ($data as $k => $v) {
if (strpos($k, '__') !== 0) {
$tempData[$k] = $v;
}
}
$result['__Request'] = $this->getDataFormatter()->formatVar($tempData);
$result['__Config'] = $this->getDataFormatter()->formatVar(__Config::getAllAsArray());
$result['__Routing'] = $this->getDataFormatter()->formatVar(__Routing::getAllAsArray());
$result['__Session'] = $this->getDataFormatter()->formatVar(__Session::getAllAsArray());
return $result;
}