Habari\HiEngineParser::stream_open PHP Method

stream_open() public method

Open a HiEngineParser stream
public stream_open ( string $path, string $mode, integer $options, string &$opened_path ) : boolean
$path string Path of the opened resource, including the protocol specifier
$mode string Mode used to open the file
$options integer Bitmask options for opening this stream
$opened_path string The actual path opened if using relative path, by reference
return boolean true on success
    function stream_open($path, $mode, $options, &$opened_path)
    {
        $this->filename = substr($path, 5);
        $this->file = file_get_contents($this->filename);
        // This processed value should cache and invalidate if a checksum of the template changes!  :)
        $this->file = $this->process($this->file);
        $this->position = 0;
        return true;
    }