1 | <?php |
||
9 | class UrlCheck extends AbstractCheck |
||
10 | { |
||
11 | |||
12 | protected $url; |
||
13 | |||
14 | /** |
||
15 | * @var Client |
||
16 | */ |
||
17 | protected $client; |
||
18 | |||
19 | /** |
||
20 | * UrlCheck constructor. |
||
21 | * |
||
22 | * @param string $label Label |
||
23 | * @param string $url URL to be tested |
||
24 | */ |
||
25 | public function __construct(string $label, string $url) |
||
31 | |||
32 | /** |
||
33 | * set http client |
||
34 | * |
||
35 | * @param Client $client |
||
36 | */ |
||
37 | public function setHttpClient(Client $client): void |
||
41 | |||
42 | /** |
||
43 | * Check URL |
||
44 | * |
||
45 | * @return Result |
||
46 | * @throws GuzzleException |
||
47 | */ |
||
48 | public function checkStatus(): Result |
||
63 | } |
||
64 |