Files
izyim/app/Classes/Modules/ControllersLogic/Exceptions/ServiceApiException.php
T
2019-02-14 11:43:19 +08:00

23 lines
545 B
PHP

<?php
namespace App\Classes\Modules\ControllerLogic\Exceptions;
use App\Classes\Exceptions\Common\ErrorException;
abstract class ServiceApiException extends ErrorException {
/** @var int */
private $httpStatusCode;
public function __construct(string $message, int $httpStatusCode = 500) {
parent::__construct($message, $httpStatusCode);
$this->httpStatusCode = $httpStatusCode;
}
/**
* @return int
*/
public function getHttpStatusCode(): int {
return $this->httpStatusCode;
}
}