Total Complexity | 2 |
Total Lines | 25 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
5 | class RateLimitReached extends AbstractException { |
||
6 | |||
7 | /** @var string|null */ |
||
8 | private $retryAfter; |
||
9 | |||
10 | 2 | public function __construct(string $request, string $detail, string $retryAfter = null) { |
|
17 | } |
||
18 | |||
19 | /** |
||
20 | * Returns the value of the given Retry-After header |
||
21 | * |
||
22 | * Retry-After: <http-date> |
||
23 | * Retry-After: <delay-seconds> |
||
24 | * @see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Retry-After |
||
25 | * |
||
26 | * @return string|null <http-date> or <delay-seconds> or null (when not given) |
||
27 | */ |
||
28 | 1 | public function getRetryAfter() : ?string { |
|
30 | } |
||
31 | } |