TYPO3 API  SVNRelease
TemplateParserBuilder.php
Go to the documentation of this file.
00001 <?php
00002 
00003 
00004 /*                                                                        *
00005  * This script is part of the TYPO3 project - inspiring people to share!  *
00006  *                                                                        *
00007  * TYPO3 is free software; you can redistribute it and/or modify it under *
00008  * the terms of the GNU General Public License version 2 as published by  *
00009  * the Free Software Foundation.                                          *
00010  *                                                                        *
00011  * This script is distributed in the hope that it will be useful, but     *
00012  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHAN-    *
00013  * TABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General      *
00014  * Public License for more details.                                       *
00015  *                                                                        */
00016 
00017 /**
00018  */
00019 /**
00020  * Build a template parser.
00021  * Use this class to get a fresh instance of a correctly initialized Fluid template parser.
00022  */
00023 class Tx_Fluid_Compatibility_TemplateParserBuilder {
00024     /**
00025      * Creates a new TemplateParser which is correctly initialized. This is the correct
00026      * way to get a Fluid parser instance.
00027      *
00028      * @return Tx_Fluid_Core_TemplateParser A correctly initialized Template Parser
00029      */
00030     static public function build() {
00031         $templateParser = t3lib_div::makeInstance('Tx_Fluid_Core_Parser_TemplateParser');
00032         $templateParser->injectObjectManager(t3lib_div::makeInstance('Tx_Extbase_Object_ObjectManager'));
00033         return $templateParser;
00034     }
00035 }
00036 
00037 
00038 ?>