(no description)
File Size: | 51 lines (2 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
Proxy:: (2 methods):
wrapSync()
wrapStreaming()
wrapSync(callable $default, callable $sync) X-Ref |
Sends synchronous requests to a specific handler while sending all other requests to another handler. param: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $default Handler used for normal responses param: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $sync Handler used for synchronous responses. return: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler. |
wrapStreaming(callable $default, callable $streaming) X-Ref |
Sends streaming requests to a streaming compatible handler while sending all other requests to a default handler. This, for example, could be useful for taking advantage of the performance benefits of curl while still supporting true streaming through the StreamHandler. param: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $default Handler used for non-streaming responses param: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $streaming Handler used for streaming responses return: callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler. |