本文整理汇总了PHP中Zend_Wildfire_Plugin_FirePhp::group方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Wildfire_Plugin_FirePhp::group方法的具体用法?PHP Zend_Wildfire_Plugin_FirePhp::group怎么用?PHP Zend_Wildfire_Plugin_FirePhp::group使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend_Wildfire_Plugin_FirePhp
的用法示例。
在下文中一共展示了Zend_Wildfire_Plugin_FirePhp::group方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testgroupedloggingAction
public function testgroupedloggingAction()
{
$logger = Zend_Registry::get('logger');
Zend_Wildfire_Plugin_FirePhp::group("Collapsed Group", array('Collapsed' => true));
$logger->log('Message in collapsed group', Zend_Log::DEBUG);
Zend_Wildfire_Plugin_FirePhp::groupEnd();
Zend_Wildfire_Plugin_FirePhp::group("Expanded Group", array('Collapsed' => false));
$logger->log('Message in expanded group', Zend_Log::DEBUG);
Zend_Wildfire_Plugin_FirePhp::groupEnd();
}
示例2: testgroupsAction
public function testgroupsAction()
{
Zend_Wildfire_Plugin_FirePhp::group('Group 1');
Zend_Wildfire_Plugin_FirePhp::send('Test Message 1');
Zend_Wildfire_Plugin_FirePhp::group('Group 2');
Zend_Wildfire_Plugin_FirePhp::send('Test Message 2', 'Label', Zend_Wildfire_Plugin_FirePhp::INFO);
Zend_Wildfire_Plugin_FirePhp::groupEnd();
Zend_Wildfire_Plugin_FirePhp::send('Test Message 3');
Zend_Wildfire_Plugin_FirePhp::groupEnd();
}
示例3: _check
public function _check($subject, $controller, $action)
{
$decisions = array();
$object = Zend_Registry::get('userid');
$user = new Evil_Object_Fixed('user', $object);
$role = $user->getValue('role');
$logger = Zend_Registry::get('logger');
Zend_Wildfire_Plugin_FirePhp::group('Access');
$conditions = array('controller', 'action', 'object', 'subject', 'role');
foreach (self::$_rules as $ruleName => $rule) {
$selected = true;
foreach ($conditions as $condition) {
if (isset($rule[$condition])) {
if (is_array($rule[$condition])) {
if (!in_array(${$condition}, $rule[$condition])) {
$selected = false;
break;
}
} elseif ($rule[$condition] != ${$condition}) {
$selected = false;
break;
}
}
}
if ($selected) {
$decisions[(int) $rule['weight']] = $rule['decision'];
$logger->log($ruleName . ' applicable!', Zend_Log::INFO);
}
}
if (count($decisions) > 0) {
$decision = $decisions[max(array_keys($decisions))];
$logger->info('Вердикт: ' . $decision);
} else {
throw new Exception('No rules applicable');
}
Zend_Wildfire_Plugin_FirePhp::groupEnd('Access');
return $decision;
}
示例4: testMessageGroupsWithCollapsedFalseOption
/**
* @group ZF-10761
*/
public function testMessageGroupsWithCollapsedFalseOption()
{
$this->_setupWithFrontController();
Zend_Wildfire_Plugin_FirePhp::group('Test Group', array('Collapsed' => false));
Zend_Wildfire_Plugin_FirePhp::send('Test Message');
Zend_Wildfire_Plugin_FirePhp::groupEnd();
$this->_controller->dispatch();
$headers = array();
$headers['X-Wf-Protocol-1'] = 'http://meta.wildfirehq.org/Protocol/JsonStream/0.2';
$headers['X-Wf-1-Structure-1'] = 'http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1';
$headers['X-Wf-1-Plugin-1'] = 'http://meta.firephp.org/Wildfire/Plugin/ZendFramework/FirePHP/1.6.2';
$headers['X-Wf-1-1-1-1'] = '70|[{"Type":"GROUP_START","Label":"Test Group","Collapsed":"false"},null]|';
$headers['X-Wf-1-1-1-2'] = '31|[{"Type":"LOG"},"Test Message"]|';
$headers['X-Wf-1-1-1-3'] = '27|[{"Type":"GROUP_END"},null]|';
$this->assertTrue($this->_response->verifyHeaders($headers));
}
示例5: dirname
<?php
require_once dirname(__FILE__) . '/.Start.php';
Zend_Wildfire_Plugin_FirePhp::group('Group 1');
Zend_Wildfire_Plugin_FirePhp::send('Log message 1', '', Zend_Wildfire_Plugin_FirePhp::LOG);
Zend_Wildfire_Plugin_FirePhp::group('Group 2');
Zend_Wildfire_Plugin_FirePhp::send('Log message 2', '', Zend_Wildfire_Plugin_FirePhp::INFO);
Zend_Wildfire_Plugin_FirePhp::send('Backtrace to here', '', Zend_Wildfire_Plugin_FirePhp::TRACE);
Zend_Wildfire_Plugin_FirePhp::groupEnd();
Zend_Wildfire_Plugin_FirePhp::send('Log message 3', 'Label', Zend_Wildfire_Plugin_FirePhp::WARN);
Zend_Wildfire_Plugin_FirePhp::groupEnd();
require_once dirname(__FILE__) . '/.End.php';