/**
  * @param int $statusCode
  * @param string $statusMessage
  * @param string $content
  */
 public function __construct($statusCode, $statusMessage, $content = '')
 {
     parent::__construct("Request failed, received: {$statusCode} {$statusMessage}", $statusCode);
     $this->statusMessage = $statusMessage;
     $this->content = $content;
 }
 /**
  * @param ResponseInterface $response
  */
 public function __construct(ResponseInterface $response)
 {
     $this->response = $response;
     parent::__construct('Server did not return any content, status code was ' . $response->getStatusCode());
 }
Esempio n. 3
0
 public function __construct($message, $body)
 {
     $this->body = $body;
     parent::__construct($message);
 }