* @param string $filename string */ public function __construct(string $filename) { $this->filename = $filename; if (!is_readable($filename)) { throw new Exception('Cannot read from file: ' . $filename); } $this->load(); } /** * Load the file * * @author Phil Burton */ public function load() { $this->file = file_get_contents($this->filename); } /** * Retun the raw file contents * * @author Phil Burton * @return string */ public function getFileContents(): string { return $this->file; } }