diff options
| author | s1n <[email protected]> | 2020-03-28 10:36:41 -0700 |
|---|---|---|
| committer | s1n <[email protected]> | 2020-03-28 10:36:41 -0700 |
| commit | 25b7d2aab61ae6421398d3abae5da6ffe590333d (patch) | |
| tree | 611985ec78bb2d94099c9fd5dd687f5c9cee6f3e /includes/vendor/rmccue/requests/library/Requests/Exception.php | |
| parent | Initial commit (diff) | |
| download | crack.cf-backup-master.tar.xz crack.cf-backup-master.zip | |
Diffstat (limited to 'includes/vendor/rmccue/requests/library/Requests/Exception.php')
| -rw-r--r-- | includes/vendor/rmccue/requests/library/Requests/Exception.php | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/includes/vendor/rmccue/requests/library/Requests/Exception.php b/includes/vendor/rmccue/requests/library/Requests/Exception.php new file mode 100644 index 0000000..37d4711 --- /dev/null +++ b/includes/vendor/rmccue/requests/library/Requests/Exception.php @@ -0,0 +1,62 @@ +<?php +/** + * Exception for HTTP requests + * + * @package Requests + */ + +/** + * Exception for HTTP requests + * + * @package Requests + */ +class Requests_Exception extends Exception { + /** + * Type of exception + * + * @var string + */ + protected $type; + + /** + * Data associated with the exception + * + * @var mixed + */ + protected $data; + + /** + * Create a new exception + * + * @param string $message Exception message + * @param string $type Exception type + * @param mixed $data Associated data + * @param integer $code Exception numerical code, if applicable + */ + public function __construct($message, $type, $data = null, $code = 0) { + parent::__construct($message, $code); + + $this->type = $type; + $this->data = $data; + } + + /** + * Like {@see getCode()}, but a string code. + * + * @codeCoverageIgnore + * @return string + */ + public function getType() { + return $this->type; + } + + /** + * Gives any relevant data + * + * @codeCoverageIgnore + * @return mixed + */ + public function getData() { + return $this->data; + } +}
\ No newline at end of file |