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


PHP type::getMessage方法代码示例

本文整理汇总了PHP中type::getMessage方法的典型用法代码示例。如果您正苦于以下问题:PHP type::getMessage方法的具体用法?PHP type::getMessage怎么用?PHP type::getMessage使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在type的用法示例。


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

示例1: pushEvent

 /**
  * Static since a store config exception (caused by a module config error) cannot call magento's model objects.
  * If a store config exception occurs, the exception class logs it drect.
  * 
  * @param type $e
  */
 public static function pushEvent($e, $setAppName = true)
 {
     if (extension_loaded('newrelic')) {
         $message = $e->getMessage();
         $message = empty($message) ? get_class($e) : $message;
         if ($setAppName) {
             Mage::Helper('newrelic')->setAppName();
         }
         newrelic_notice_error($message, $e);
     }
 }
开发者ID:Bobspadger,项目名称:NewRelic,代码行数:17,代码来源:Exception.php

示例2: handleReqException

/**
 * Exception handler.
 *
 * @global type $document
 * @global array $totalFailure
 * @global boolean $responding
 * @global type $standalone
 * @param type $e
 */
function handleReqException($e)
{
    global $document, $totalFailure, $responding, $standalone;
    $responding = true;
    $message = 'Exception: "' . $e->getMessage() . '" in ' . $e->getFile() . ' L' . $e->getLine() . "\n";
    foreach ($e->getTrace() as $stackLevel) {
        $message .= $stackLevel['file'] . ' L' . $stackLevel['line'] . ' ';
        if ($stackLevel['class'] != '') {
            $message .= $stackLevel['class'];
            $message .= '->';
        }
        $message .= $stackLevel['function'];
        $message .= "();\n";
    }
    $message = str_replace('{scenario}', 'uncaught exception', $totalFailure[0] . $message . $totalFailure[1]);
    echo strtr($document, array('{headerContent}' => '', '{bodyContent}' => $message));
    RIP();
}
开发者ID:shuvro35,项目名称:X2CRM,代码行数:27,代码来源:requirements.php

示例3: exception_error

/**
 * 异常处理
 * @param type $e
 */
function exception_error($e)
{
    echo $e->getMessage();
}
开发者ID:beijizhou,项目名称:xinjiang001,代码行数:8,代码来源:function.php

示例4: error

 /**
  * Error handler
  *
  * @param type $err
  */
 function error($err)
 {
     print_r($err->getMessage());
 }
开发者ID:rtCamp,项目名称:migrate-wufoo-to-gravity-forms,代码行数:9,代码来源:rtWufoo.php

示例5: catch_exception

 /**
  * Exception Handler
  * 
  * @internal
  * @static
  * @param type $exception 
  */
 public static function catch_exception($exception)
 {
     argent_logger::log_event('Exception', $exception->getMessage());
     echo "Argent Exception: " . $exception->getMessage();
 }
开发者ID:relativeie,项目名称:argent-cloudkit,代码行数:12,代码来源:class.argent_error.php

示例6: error

 /**
  *
  *
  * @param type $trace
  * @param type $error
  */
 public static function error($trace, $error)
 {
     echo '<br>' . '<b>Fatal error</b>: ' . $error->getMessage() . ' in method <strong>' . $trace[0]['function'] . '</strong> ' . 'called at <strong>' . $trace[0]['file'] . '</strong> on line <strong>' . $trace[0]['line'] . '</strong>' . "<br>";
     die;
 }
开发者ID:javanile,项目名称:schemadb,代码行数:11,代码来源:ProtectedApi.php

示例7: errorAction

 /**
  * 异常数据报错
  * @param type $e
  */
 protected function errorAction($e, array $config, $action = 'execute')
 {
     $error = $this->PDOStatement->errorInfo();
     //记录日志报错情况[]
     $this->logWrite($e->getCode() . ":" . $e->getMessage());
     if ($error[1] == 2006 || $error[1] == 2013) {
         $this->_linkcount++;
         //重连次数+1
         if ($this->_linkcount < $this->_linkCount) {
             //服务器重连接
             $this->resetConnect();
             return $this->{$action}($config[0], $config[1]);
         } else {
             return false;
         }
     }
 }
开发者ID:weijer,项目名称:thinkphp,代码行数:21,代码来源:Driver.class.php


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