public static fromCommand ( Guzzle\Service\Command\OperationCommand $command ) | ||
$command | Guzzle\Service\Command\OperationCommand |
public static function fromCommand(OperationCommand $command)
{
$response = $command->getResponse();
return new self(['status' => $response->getStatusCode(), 'reason' => $response->getReasonPhrase(), 'text' => $response->getBody(true)]);
}