public function Response::getMessage

Get the entire response as a string

Return value

string

1 call to Response::getMessage()
Response::__toString in drupal/core/vendor/guzzle/http/Guzzle/Http/Message/Response.php
Convert the response object to a string

File

drupal/core/vendor/guzzle/http/Guzzle/Http/Message/Response.php, line 317

Class

Response
Guzzle HTTP response object

Namespace

Guzzle\Http\Message

Code

public function getMessage() {
  $message = $this
    ->getRawHeaders();

  // Only include the body in the message if the size is < 2MB
  $size = $this->body
    ->getSize();
  if ($size < 2097152) {
    $message .= (string) $this->body;
  }
  return $message;
}