Skip to content

Commit 518caf8

Browse files
committed
Tweaks
1 parent 00a85a7 commit 518caf8

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

components/http_client.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,9 @@ following methods::
344344
// casts the response JSON contents to a PHP array
345345
$content = $response->toArray();
346346

347+
// casts the response content to a PHP stream resource
348+
$content = $response->toStream();
349+
347350
// cancels the request/response
348351
$response->cancel();
349352

@@ -356,6 +359,10 @@ following methods::
356359
// returns detailed logs about the requests and responses of the HTTP transaction
357360
$httpLogs = $response->getInfo('debug');
358361

362+
.. versionadded:: 4.4
363+
364+
The ``toStream()`` method was introduced in Symfony 4.4.
365+
359366
.. note::
360367

361368
``$response->getInfo()`` is non-blocking: it returns *live* information

0 commit comments

Comments
 (0)