26 $this->error_code = $code;
27 $message = strval($message);
29 parent::__construct($message, intval($code), $previous);
45 return $this->status == 0 ? \CRestServer::STATUS_WRONG_REQUEST :
$this->status;
55 $this->message = $msg;
79 $this->message = $ex->getString();
86 if (is_a($e,
'\Bitrix\Main\DB\SqlException'))
91 \CRestServer::STATUS_INTERNAL,
95 elseif(is_a($e,
'\Bitrix\Main\SystemException'))
97 if(is_a($e,
'\Bitrix\Main\ArgumentException'))
102 \CRestServer::STATUS_WRONG_REQUEST,
106 $ex->setAdditional(array(
107 "argument" => $e->getParameter(),
117 \CRestServer::STATUS_WRONG_REQUEST,
const ERROR_INTERNAL_PORTAL_DELETED
setErrorCode($error_code)
const ERROR_METHOD_NOT_FOUND
const ERROR_INTERNAL_WRONG_TRANSPORT
__construct($message, $code="", $status=0, \Exception $previous=null)
const ERROR_INTERNAL_WRONG_FILE_HANDLER
setApplicationException(\CApplicationException $ex)
setAdditional($error_additional)
const ERROR_INTERNAL_WRONG_HANDLER_CLASS
static initFromException(\Exception $e)
const ERROR_OPERATION_TIME_LIMIT