src/ViewFactory.php
protected function find($fileName)
    {
        $fileName = $fileName . '.' . $this->fileExtension;

        foreach ($this->viewPaths as $path) {
            if (file_exists($path . $fileName)) {
                return realpath($path . $fileName);
            }
        }

        throw new \Exception("View $fileName not found.");
    }
protected function find($fileName)
    {
        $fileName = $fileName . '.' . $this->fileExtension;

        foreach ($this->viewPaths as $path) {
            if (file_exists($path . $fileName)) {
                return realpath($path . $fileName);
            }
        }

        throw new \Exception("View $fileName not found.");
    }
protected function find ( $ fileName ) { $ fileName = $ fileName . '.' . $ this -> fileExtension ; foreach ( $ this -> viewPaths as $ path ) { if ( file_exists ( $ path . $ fileName ) ) { return realpath ( $ path . $ fileName ) ; } } throw new \ Exception ( "View $fileName not found." ) ; }
Locates a view file and returns its full path.

@param string $fileName The file name.
@return string|false The location of the file, or false if it cannot be found.
@throws \Exception
Locates a view file and returns its full path .