public function getByFileName($fileName)
    {
        if (!isset($this->templates[$fileName])) {
            /** @var \Tx_Oelib_Template $template */
            $template = GeneralUtility::makeInstance(\Tx_Oelib_Template::class);

            if ($fileName !== '') {
                $template->processTemplateFromFile($fileName);
            }
            $this->templates[$fileName] = $template;
        }

        return clone $this->templates[$fileName];
    }
public function getByFileName($fileName)
    {
        if (!isset($this->templates[$fileName])) {
            /** @var \Tx_Oelib_Template $template */
            $template = GeneralUtility::makeInstance(\Tx_Oelib_Template::class);

            if ($fileName !== '') {
                $template->processTemplateFromFile($fileName);
            }
            $this->templates[$fileName] = $template;
        }

        return clone $this->templates[$fileName];
    }
public function getByFileName ( $ fileName ) { if ( ! isset ( $ this -> templates [ $ fileName ] ) ) { /** @var \Tx_Oelib_Template $template */ $ template = GeneralUtility :: makeInstance ( \ Tx_Oelib_Template :: class ) ; if ( $ fileName !== '' ) { $ template -> processTemplateFromFile ( $ fileName ) ; } $ this -> templates [ $ fileName ] = $ template ; } return clone $ this -> templates [ $ fileName ] ; }
Creates a new template for a provided template file name with an already
parsed the template file.

If the template file name is empty, no template file will be used for
that template.

@param string $fileName
the file name of the template to retrieve, may not be empty to get a template that is not related to a
template file

@return \Tx_Oelib_Template the template for the given template file name
Creates a new template for a provided template file name with an already parsed the template file .