Skip to content
This repository was archived by the owner on Apr 27, 2023. It is now read-only.

Commit 2ab4305

Browse files
committed
Update docblock.
1 parent e2c394f commit 2ab4305

File tree

3 files changed

+22
-15
lines changed

3 files changed

+22
-15
lines changed

src/Factory.php

+10-7
Original file line numberDiff line numberDiff line change
@@ -16,30 +16,33 @@
1616
* @method \Gokure\Http\Client\PendingRequest asForm()
1717
* @method \Gokure\Http\Client\PendingRequest asJson()
1818
* @method \Gokure\Http\Client\PendingRequest asMultipart()
19-
* @method \Gokure\Http\Client\PendingRequest attach(string $name, string $contents, string|null $filename = null, array $headers = [])
19+
* @method \Gokure\Http\Client\PendingRequest async()
20+
* @method \Gokure\Http\Client\PendingRequest attach(string|array $name, string $contents = '', string|null $filename = null, array $headers = [])
2021
* @method \Gokure\Http\Client\PendingRequest baseUrl(string $url)
2122
* @method \Gokure\Http\Client\PendingRequest beforeSending(callable $callback)
2223
* @method \Gokure\Http\Client\PendingRequest bodyFormat(string $format)
2324
* @method \Gokure\Http\Client\PendingRequest contentType(string $contentType)
25+
* @method \Gokure\Http\Client\PendingRequest dd()
26+
* @method \Gokure\Http\Client\PendingRequest dump()
2427
* @method \Gokure\Http\Client\PendingRequest retry(int $times, int $sleep = 0)
28+
* @method \Gokure\Http\Client\PendingRequest sink(string|resource $to)
2529
* @method \Gokure\Http\Client\PendingRequest stub(callable $callback)
2630
* @method \Gokure\Http\Client\PendingRequest timeout(int $seconds)
2731
* @method \Gokure\Http\Client\PendingRequest withBasicAuth(string $username, string $password)
2832
* @method \Gokure\Http\Client\PendingRequest withBody(resource|string $content, string $contentType)
2933
* @method \Gokure\Http\Client\PendingRequest withCookies(array $cookies, string $domain)
3034
* @method \Gokure\Http\Client\PendingRequest withDigestAuth(string $username, string $password)
3135
* @method \Gokure\Http\Client\PendingRequest withHeaders(array $headers)
36+
* @method \Gokure\Http\Client\PendingRequest withMiddleware(callable $middleware)
3237
* @method \Gokure\Http\Client\PendingRequest withOptions(array $options)
3338
* @method \Gokure\Http\Client\PendingRequest withToken(string $token, string $type = 'Bearer')
39+
* @method \Gokure\Http\Client\PendingRequest withUserAgent(string $userAgent)
3440
* @method \Gokure\Http\Client\PendingRequest withoutRedirecting()
3541
* @method \Gokure\Http\Client\PendingRequest withoutVerifying()
36-
* @method \Gokure\Http\Client\PendingRequest dump()
37-
* @method \Gokure\Http\Client\PendingRequest dd()
38-
* @method \Gokure\Http\Client\PendingRequest async()
39-
* @method \Gokure\Http\Client\Pool pool(callable $callback)
42+
* @method array pool(callable $callback)
4043
* @method \Gokure\Http\Client\Response delete(string $url, array $data = [])
41-
* @method \Gokure\Http\Client\Response get(string $url, array $query = [])
42-
* @method \Gokure\Http\Client\Response head(string $url, array $query = [])
44+
* @method \Gokure\Http\Client\Response get(string $url, array|string|null $query = null)
45+
* @method \Gokure\Http\Client\Response head(string $url, array|string|null $query = null)
4346
* @method \Gokure\Http\Client\Response patch(string $url, array $data = [])
4447
* @method \Gokure\Http\Client\Response post(string $url, array $data = [])
4548
* @method \Gokure\Http\Client\Response put(string $url, array $data = [])

src/Http.php

+10-8
Original file line numberDiff line numberDiff line change
@@ -12,31 +12,33 @@
1212
* @method static \Gokure\Http\Client\PendingRequest asForm()
1313
* @method static \Gokure\Http\Client\PendingRequest asJson()
1414
* @method static \Gokure\Http\Client\PendingRequest asMultipart()
15-
* @method static \Gokure\Http\Client\PendingRequest attach(string $name, string $contents, string|null $filename = null, array $headers = [])
15+
* @method static \Gokure\Http\Client\PendingRequest async()
16+
* @method static \Gokure\Http\Client\PendingRequest attach(string|array $name, string $contents = '', string|null $filename = null, array $headers = [])
1617
* @method static \Gokure\Http\Client\PendingRequest baseUrl(string $url)
1718
* @method static \Gokure\Http\Client\PendingRequest beforeSending(callable $callback)
1819
* @method static \Gokure\Http\Client\PendingRequest bodyFormat(string $format)
1920
* @method static \Gokure\Http\Client\PendingRequest contentType(string $contentType)
21+
* @method static \Gokure\Http\Client\PendingRequest dd()
22+
* @method static \Gokure\Http\Client\PendingRequest dump()
2023
* @method static \Gokure\Http\Client\PendingRequest retry(int $times, int $sleep = 0)
21-
* @method static \Gokure\Http\Client\PendingRequest sink($to)
24+
* @method static \Gokure\Http\Client\PendingRequest sink(string|resource $to)
2225
* @method static \Gokure\Http\Client\PendingRequest stub(callable $callback)
2326
* @method static \Gokure\Http\Client\PendingRequest timeout(int $seconds)
2427
* @method static \Gokure\Http\Client\PendingRequest withBasicAuth(string $username, string $password)
2528
* @method static \Gokure\Http\Client\PendingRequest withBody(resource|string $content, string $contentType)
2629
* @method static \Gokure\Http\Client\PendingRequest withCookies(array $cookies, string $domain)
2730
* @method static \Gokure\Http\Client\PendingRequest withDigestAuth(string $username, string $password)
2831
* @method static \Gokure\Http\Client\PendingRequest withHeaders(array $headers)
32+
* @method static \Gokure\Http\Client\PendingRequest withMiddleware(callable $middleware)
2933
* @method static \Gokure\Http\Client\PendingRequest withOptions(array $options)
3034
* @method static \Gokure\Http\Client\PendingRequest withToken(string $token, string $type = 'Bearer')
35+
* @method static \Gokure\Http\Client\PendingRequest withUserAgent(string $userAgent)
3136
* @method static \Gokure\Http\Client\PendingRequest withoutRedirecting()
3237
* @method static \Gokure\Http\Client\PendingRequest withoutVerifying()
33-
* @method static \Gokure\Http\Client\PendingRequest dump()
34-
* @method static \Gokure\Http\Client\PendingRequest dd()
35-
* @method static \Gokure\Http\Client\PendingRequest async()
36-
* @method static \Gokure\Http\Client\Pool pool(callable $callback)
38+
* @method static array pool(callable $callback)
3739
* @method static \Gokure\Http\Client\Response delete(string $url, array $data = [])
38-
* @method static \Gokure\Http\Client\Response get(string $url, array $query = [])
39-
* @method static \Gokure\Http\Client\Response head(string $url, array $query = [])
40+
* @method static \Gokure\Http\Client\Response get(string $url, array|string|null $query = null)
41+
* @method static \Gokure\Http\Client\Response head(string $url, array|string|null $query = null)
4042
* @method static \Gokure\Http\Client\Response patch(string $url, array $data = [])
4143
* @method static \Gokure\Http\Client\Response post(string $url, array $data = [])
4244
* @method static \Gokure\Http\Client\Response put(string $url, array $data = [])

src/ResponseSequence.php

+2
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,8 @@ public function isEmpty()
142142
* Get the next response in the sequence.
143143
*
144144
* @return mixed
145+
*
146+
* @throws \OutOfBoundsException
145147
*/
146148
public function __invoke()
147149
{

0 commit comments

Comments
 (0)