3 * Exception for HTTP requests
9 * Exception for HTTP requests
13 class Requests_Exception extends Exception {
22 * Data associated with the exception
29 * Create a new exception
31 * @param string $message Exception message
32 * @param string $type Exception type
33 * @param mixed $data Associated data
34 * @param integer $code Exception numerical code, if applicable
36 public function __construct($message, $type, $data = null, $code = 0) {
37 parent::__construct($message, $code);
44 * Like {@see getCode()}, but a string code.
49 public function getType() {
54 * Gives any relevant data
59 public function getData() {