Create a new exception
Parameters
$message
stringrequired- Exception message
$type
stringrequired- Exception type
$data
mixedoptional- Associated data
Default:
null
$code
integerrequired- Exception numerical code, if applicable
Source
public function __construct($message, $type, $data = null, $code = 0) {
parent::__construct($message, $code);
$this->type = $type;
$this->data = $data;
}
User Contributed Notes
You must log in before being able to contribute a note or feedback.