Base.php 602 B

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. namespace Pingpp\Error;
  3. use Exception;
  4. abstract class Base extends Exception
  5. {
  6. public function __construct($message, $httpStatus=null,
  7. $httpBody=null, $jsonBody=null
  8. )
  9. {
  10. parent::__construct($message);
  11. $this->httpStatus = $httpStatus;
  12. $this->httpBody = $httpBody;
  13. $this->jsonBody = $jsonBody;
  14. }
  15. public function getHttpStatus()
  16. {
  17. return $this->httpStatus;
  18. }
  19. public function getHttpBody()
  20. {
  21. return $this->httpBody;
  22. }
  23. public function getJsonBody()
  24. {
  25. return $this->jsonBody;
  26. }
  27. }