@@ -30,25 +30,36 @@ Btw, we're hiring!
3030
3131### The client
3232
33+ ### Instantiate the client
34+
35+ ```php
36+ $client = new Client($server);
37+ ```
38+
39+ ### Instantiate the client with custom Guzzle Client
40+
41+ ```php
42+ $client = Client::constructWithGuzzleClient($guzzleClient, $server);
43+ ```
44+
45+ ### Use the client instance
3346```php
34- $client = new Client($server);
35- $client->set(' /foo' , ' fooValue' );
36- // Set the ttl
37- $client->set(' /foo' , ' fooValue' , 10);
38- // get key value
39- echo $client->get(' /foo' );
40-
41- // Update value with key
42- $client->update(' /foo' , ' newFooValue' );
43-
44- // Delete key
45- $client->rm(' /foo' );
46-
47- // Create a directory
48- $client->mkdir(' /fooDir' );
49- // Remove dir
50- $client->rmdir(' /fooDir' );
51-
47+ $client->set(' /foo' , ' fooValue' );
48+ // Set the ttl
49+ $client->set(' /foo' , ' fooValue' , 10);
50+ // get key value
51+ echo $client->get(' /foo' );
52+
53+ // Update value with key
54+ $client->update(' /foo' , ' newFooValue' );
55+
56+ // Delete key
57+ $client->rm(' /foo' );
58+
59+ // Create a directory
60+ $client->mkdir(' /fooDir' );
61+ // Remove dir
62+ $client->rmdir(' /fooDir' );
5263```
5364
5465### The command line tool
0 commit comments