ApiResponse.php 712 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. namespace Stripe;
  3. use Stripe\Util\CaseInsensitiveArray;
  4. /**
  5. * Class ApiResponse.
  6. */
  7. class ApiResponse
  8. {
  9. /**
  10. * @var null|array|CaseInsensitiveArray
  11. */
  12. public $headers;
  13. /**
  14. * @var string
  15. */
  16. public $body;
  17. /**
  18. * @var null|array
  19. */
  20. public $json;
  21. /**
  22. * @var int
  23. */
  24. public $code;
  25. /**
  26. * @param string $body
  27. * @param int $code
  28. * @param null|array|CaseInsensitiveArray $headers
  29. * @param null|array $json
  30. */
  31. public function __construct($body, $code, $headers, $json)
  32. {
  33. $this->body = $body;
  34. $this->code = $code;
  35. $this->headers = $headers;
  36. $this->json = $json;
  37. }
  38. }