/** * @inheritDoc */ protected function extractData($responseLine, Server $server) { list(, $dataLength) = explode(' ', $responseLine); $rawData = $server->readData($dataLength); try { return Yaml::parse($rawData); } catch (ParseException $exception) { throw Exception::wrap($exception); } }
public function __construct($response, Server $server) { parent::__construct(sprintf(self::DEFAULT_MESSAGE, (string) $server, $response), self::DEFAULT_CODE); }
public function __construct(Server $server) { parent::__construct(sprintf(static::DEFAULT_MESSAGE, (string) $server), static::DEFAULT_CODE); }