public function loadFile(string $file)
    {
        $path = $this->basePath . '/' . $file . '.phtml';
        if (!is_readable($path)) {
            throw new TemplateException(sprintf('Template engine could not read the file "%s"', $path));
        };

        if (($this->contents = file_get_contents($path)) === false) {
            throw new TemplateException(sprintf('File "%s" not readable', $path));
        }

    }
public function loadFile(string $file)
    {
        $path = $this->basePath . '/' . $file . '.phtml';
        if (!is_readable($path)) {
            throw new TemplateException(sprintf('Template engine could not read the file "%s"', $path));
        };

        if (($this->contents = file_get_contents($path)) === false) {
            throw new TemplateException(sprintf('File "%s" not readable', $path));
        }

    }
public function loadFile ( string $ file ) { $ path = $ this -> basePath . '/' . $ file . '.phtml' ; if ( ! is_readable ( $ path ) ) { throw new TemplateException ( sprintf ( 'Template engine could not read the file "%s"' , $ path ) ) ; } ; if ( ( $ this -> contents = file_get_contents ( $ path ) ) === false ) { throw new TemplateException ( sprintf ( 'File "%s" not readable' , $ path ) ) ; } }
Loads a template file into memory

@param string $file

@return mixed
Loads a template file into memory