| 1 | <?php | ||
| 8 | abstract class AbstractSslCertificateChecker extends AbstractChecker | ||
| 9 | { | ||
| 10 | /** | ||
| 11 | * The hostname that must be checked. | ||
| 12 | * | ||
| 13 | * @var string | ||
| 14 | */ | ||
| 15 | protected $hostname; | ||
| 16 | |||
| 17 | /** | ||
| 18 | * The port to request the certificate on. | ||
| 19 | * | ||
| 20 | * @var string | ||
| 21 | */ | ||
| 22 | protected $port = 443; | ||
| 23 | |||
| 24 | /** | ||
| 25 | * Creates a new instance of this checker with a Ssl Certificate Downloader. | ||
| 26 | * | ||
| 27 | * @param \Spatie\SslCertificate\Downloader $downloader | ||
| 28 | */ | ||
| 29 | public function __construct(Downloader $downloader) | ||
| 33 | |||
| 34 | /** | ||
| 35 | * Requests the URL and handles any thrown exceptions. | ||
| 36 | * | ||
| 37 | * @return null | ||
| 38 | */ | ||
| 39 | public function run() | ||
| 55 | } | ||
| 56 | 
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: