当前位置: 首页>>代码示例>>PHP>>正文


PHP monitor_custom_event函数代码示例

本文整理汇总了PHP中monitor_custom_event函数的典型用法代码示例。如果您正苦于以下问题:PHP monitor_custom_event函数的具体用法?PHP monitor_custom_event怎么用?PHP monitor_custom_event使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了monitor_custom_event函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: handle

 /**
  * Handle the error.
  *
  * @param string $errorMessage
  * @param string $debugMessage
  */
 public function handle($errorMessage, $debugMessage)
 {
     if ($this->zendPlatformAvailable()) {
         // log in zend platform
         $errMsg = implode(' | ', is_array($errorMessage) ? $errorMessage : array());
         if ($errMsg == '') {
             $errMsg = 'Something went terribly wrong, but there is no errormessage set...';
         } else {
             $errMsg = preg_replace('/\\[\\+.*s\\]/', '', $errMsg);
         }
         // get rid of timestamps because they will prevent ZP from finding duplicate errors
         monitor_custom_event(Tools::atktext('app_title'), $errMsg, true);
     }
 }
开发者ID:sintattica,项目名称:atk,代码行数:20,代码来源:ZendPlatformErrorHandler.php

示例2: doWrite

 /**
  * Write a message to the log.
  *
  * @param array $event log data event
  * @return void
  */
 protected function doWrite(array $event)
 {
     $priority = $event['priority'];
     $message = $event['message'];
     unset($event['priority'], $event['message']);
     if (!empty($event)) {
         if ($this->isZendServer) {
             // On Zend Server; third argument should be the event
             zend_monitor_custom_event($priority, $message, $event);
         } else {
             // On Zend Platform; third argument is severity -- either
             // 0 or 1 -- and fourth is optional (event)
             // Severity is either 0 (normal) or 1 (severe); classifying
             // notice, info, and debug as "normal", and all others as
             // "severe"
             monitor_custom_event($priority, $message, $priority > 4 ? 0 : 1, $event);
         }
     } else {
         monitor_custom_event($priority, $message);
     }
 }
开发者ID:Flesh192,项目名称:magento,代码行数:27,代码来源:ZendMonitor.php

示例3: _write

 /**
  * Write a message to the log.
  *
  * @param  array  $event  log data event
  * @return void
  */
 protected function _write($event)
 {
     $priority = $event['priority'];
     $message = $event['message'];
     unset($event['priority'], $event['message']);
     if (!empty($event)) {
         monitor_custom_event($priority, $message, false, $event);
     } else {
         monitor_custom_event($priority, $message);
     }
 }
开发者ID:bizanto,项目名称:Hooked,代码行数:17,代码来源:ZendMonitor.php


注:本文中的monitor_custom_event函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。