message = $message; $this->url = $url; $this->details = $details; $this->code = $error_code; } /// Returns a string representation of the exception. /** * \return a string containing exception information */ public function __toString() { if($this->code) return "Error {$this->code}: {$this->message}"; else return "Error: {$this->message}"; } /// Returns a brief description of the error. /** * \return the error description */ public function Message() { return $this->message; } /// Returns the URL that generated the exception. /** * \return the URL object */ public function URL() { return $this->url; } /// Returns an error code associated with the exception. /** * \return the error code */ public function ErrorCode() { return $this->code; } /// Returns additional details about the exception. /** * \return details about the exception */ public function Details() { return $this->details; } } endif;