RequestException.php 731 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. namespace yzh52521\EasyHttp;
  3. class RequestException
  4. {
  5. public $exception;
  6. public function __construct($exception)
  7. {
  8. $this->exception = $exception;
  9. }
  10. public function getCode()
  11. {
  12. return $this->exception->getCode();
  13. }
  14. public function getMessage()
  15. {
  16. return $this->exception->getMessage();
  17. }
  18. public function getFile()
  19. {
  20. return $this->exception->getFile();
  21. }
  22. public function getLine()
  23. {
  24. return $this->exception->getLine();
  25. }
  26. public function getTrace()
  27. {
  28. return $this->exception->getTrace();
  29. }
  30. public function getTraceAsString()
  31. {
  32. return $this->exception->getTraceAsString();
  33. }
  34. }