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


PHP ApplicationException::__construct方法代码示例

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


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

示例1: __construct

 public function __construct($errors = null, $message = null, $ApplicationExceptionType = null)
 {
     parent::__construct();
     $this->errors = $errors;
     $this->message = $message;
     $this->ApplicationExceptionType = $ApplicationExceptionType;
 }
开发者ID:sonicgd,项目名称:google-adwords-api-light,代码行数:7,代码来源:ApiException.php

示例2: trim

		function __construct ($message, $code = E_USER_WARNING)
	 	{
	 		$message = trim($message, ".");
	 		$message = "Registry error: {$message}";
	 		$message = trim($message, ".");
	 		parent::__construct($message, $code);		
	 	}
开发者ID:rchicoria,项目名称:epp-drs,代码行数:7,代码来源:class.RegistryException.php

示例3: __construct

 public function __construct()
 {
     $message = 'Unexpected case';
     $backtrace = debug_backtrace(0, 2);
     if (isset($backtrace[1]['class'])) {
         $message .= ' in ' . $backtrace[1]['class'] . '::' . $backtrace[1]['function'];
     }
     parent::__construct($message);
 }
开发者ID:extpoint,项目名称:yii2-core,代码行数:9,代码来源:UnexpectedCaseException.php

示例4: __construct

 public function __construct(Controller $controller, $statusCode, $message = false)
 {
     $this->controller = $controller;
     $this->statusCode = $statusCode;
     if (!$message) {
         $action = $this->getController()->getRequest()->getControllerName() . '/' . $this->getController()->getRequest()->getActionName();
         $code = $this->getStatusCode() . ' (' . self::getCodeMeaning($this->getStatusCode()) . ')';
         $message = "Error accessing {$action}.\n {$code}";
     }
     parent::__construct($message);
 }
开发者ID:saiber,项目名称:www,代码行数:11,代码来源:HTTPStatusException.php

示例5: __construct

 public function __construct($errors = null, $message = null)
 {
     parent::__construct();
     $this->errors = $errors;
     $this->message = $message;
 }
开发者ID:stevenmaguire,项目名称:googleads-php-lib,代码行数:6,代码来源:LineItemService.php

示例6: __construct

 public function __construct($errors = NULL, $message = NULL, $ApplicationExceptionType = NULL)
 {
     if (get_parent_class('ApiException')) {
         parent::__construct();
     }
     $this->errors = $errors;
     $this->message = $message;
     $this->ApplicationExceptionType = $ApplicationExceptionType;
 }
开发者ID:josephbergdoll,项目名称:berrics,代码行数:9,代码来源:CustomFieldService.php

示例7:

 /**
  * @param string $argumentName
  * @param string $message
  */
 function __construct($argumentName, $message)
 {
     Assert::isScalar($argumentName);
     parent::__construct($message);
     $this->argumentName = $argumentName;
 }
开发者ID:phoebius,项目名称:phoebius,代码行数:10,代码来源:ArgumentException.class.php

示例8:

 function __construct($message, $code = null)
 {
     // Call ApplicationException constructor
     parent::__construct("Licensing error: {$message}");
 }
开发者ID:rchicoria,项目名称:epp-drs,代码行数:5,代码来源:class.LicensingException.php

示例9: trim

		function __construct ($message, $code = null)
	 	{
	 		$message = trim($message, ".");
	 		$message = "{$message}. Please consult API documentation.";
	 		parent::__construct($message, $code);		
	 	}
开发者ID:rchicoria,项目名称:epp-drs,代码行数:6,代码来源:class.APIException.php

示例10: __construct

 /**
  * @param \yii\base\Model $model
  */
 public function __construct($model)
 {
     $this->errors = $model->errors;
     parent::__construct('Cannot save model ' . $model->className() . ', errors: ' . print_r($this->errors, true));
 }
开发者ID:extpoint,项目名称:yii2-core,代码行数:8,代码来源:ModelSaveException.php

示例11: __construct

 /**
  * @inheritdoc
  */
 public function __construct()
 {
     parent::__construct('The occurred code block is not implemented and a placeholder error is currently put in place.');
 }
开发者ID:phabitat,项目名称:exceptional,代码行数:7,代码来源:NotImplementedException.php

示例12: __construct

 /**
  * @param string $controller Controllers name
  */
 public function __construct($controllerName)
 {
     parent::__construct("Specified controller ({$controllerName}) does not exist");
     $this->controllerName = $controllerName;
 }
开发者ID:saiber,项目名称:www,代码行数:8,代码来源:ControllerNotFoundException.php


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