preliminary 2.3.0 docs
[mdref/mdref-http] / http / Client / configure.md
1 # http\Client http\Client::configure(array $configuration)
2
3 Configure the client's low level options.
4
5 ## Params:
6
7 * array $configuration
8 Key/value pairs of low level options.
9 See f.e. the [configuration options for the Curl driver](http/Client/Curl#Configuration:).
10
11 ## Returns:
12
13 * http\Client, self.
14
15 ## Throws:
16
17 * http\Exception\InvalidArgumentException
18 * http\Exception\UnexpectedValueException
19
20 ## Example:
21
22 <?php
23
24 $client = new http\Client("curl");
25 $client->configure([
26 "max_host_connections" => 8,
27 "pipelining" => true,
28 ]);
29
30 ?>