StackFormation\Template::__construct PHP 메소드

__construct() 공개 메소드

public __construct ( $filePath, Preprocessor $preprocessor = null )
$preprocessor Preprocessor
    public function __construct($filePath, Preprocessor $preprocessor = null)
    {
        if (!is_file($filePath)) {
            throw new \Symfony\Component\Filesystem\Exception\FileNotFoundException("File '{$filePath}' not found");
        }
        $this->filepath = $filePath;
        $this->cache = new \StackFormation\Helper\Cache();
        $this->preProcessor = $preprocessor ? $preprocessor : new Preprocessor();
    }