21 private $dcpCode =
'';
22 private $httpHeader = array();
30 if ($code && (preg_match(
'/^([A-Z]+)([0-9]+)$/u', $code, $reg))) {
34 $nargs = func_num_args();
35 for ($ip = 1; $ip < $nargs; $ip++) {
36 $tArgs[] = func_get_arg($ip);
38 $msg = call_user_func_array(
"ErrorCode::getError", $tArgs);
40 $this->dcpCode = $code;
42 if ($argCode && is_numeric($argCode)) $intcode = intval($argCode);
45 parent::__construct(
$message, $intcode);
53 if ($this->dcpCode)
return $this->dcpCode;
54 if (preg_match(
"/^{([^}]+)/u", $this->message, $reg)) {
66 if (preg_match(
"/^{([^}]+)} *(.*)$/ums", $this->message, $reg)) {
76 return __CLASS__ .
": {$this->message}";
81 $this->httpHeader[] = $header;
85 return implode(
"\n", $this->httpHeader);
Exception class use exceptionCode to identifiy correctly exception.
__construct($message, $argCode=0)