X-Git-Url: https://git.mxchange.org/?p=core.git;a=blobdiff_plain;f=inc%2Fclasses%2Fmain%2Ftemplate%2Fconsole%2Fclass_ConsoleTemplateEngine.php;h=0a9bc8dc5f022fb22006b3c476f9c1d04efd54c7;hp=efdcd06e31121a27b7e8a45b57a267257b459b94;hb=ec6bb7da038135934f0d5abfcb82a7a7780945a4;hpb=a3fa89c7cbc54491fc74f13db0927d14acf550c8 diff --git a/inc/classes/main/template/console/class_ConsoleTemplateEngine.php b/inc/classes/main/template/console/class_ConsoleTemplateEngine.php index efdcd06e..0a9bc8dc 100644 --- a/inc/classes/main/template/console/class_ConsoleTemplateEngine.php +++ b/inc/classes/main/template/console/class_ConsoleTemplateEngine.php @@ -4,7 +4,7 @@ * * @author Roland Haeder * @version 0.0.0 - * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009, 2010 Core Developer Team + * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2011 Core Developer Team * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org * @todo This template engine does not make use of setTemplateType() @@ -36,8 +36,8 @@ class ConsoleTemplateEngine extends BaseTemplateEngine implements CompileableTem /** * Creates an instance of the class TemplateEngine and prepares it for usage * - * @param $appInstance A manageable application - * @return $templateInstance An instance of TemplateEngine + * @param $applicationInstance A manageable application + * @return $templateInstance An instance of TemplateEngine * @throws BasePathIsEmptyException If the provided $templateBasePath is empty * @throws InvalidBasePathStringException If $templateBasePath is no string * @throws BasePathIsNoDirectoryException If $templateBasePath is no @@ -45,16 +45,12 @@ class ConsoleTemplateEngine extends BaseTemplateEngine implements CompileableTem * @throws BasePathReadProtectedException If $templateBasePath is * read-protected */ - public static final function createConsoleTemplateEngine (ManageableApplication $appInstance) { + public static final function createConsoleTemplateEngine (ManageableApplication $applicationInstance) { // Get a new instance $templateInstance = new ConsoleTemplateEngine(); - // Get language and file I/O instances from application - $langInstance = $appInstance->getLanguageInstance(); - $ioInstance = $appInstance->getFileIoInstance(); - // Determine base path - $templateBasePath = $templateInstance->getConfigInstance()->getConfigEntry('application_base_path') . $appInstance->getRequestInstance()->getRequestElement('app') . '/'; + $templateBasePath = $templateInstance->getConfigInstance()->getConfigEntry('application_base_path') . $applicationInstance->getRequestInstance()->getRequestElement('app') . '/'; // Is the base path valid? if (empty($templateBasePath)) { @@ -74,10 +70,6 @@ class ConsoleTemplateEngine extends BaseTemplateEngine implements CompileableTem // Set the base path $templateInstance->setTemplateBasePath($templateBasePath); - // Set the language and IO instances - $templateInstance->setLanguageInstance($langInstance); - $templateInstance->setFileIoInstance($ioInstance); - // Set template extensions $templateInstance->setRawTemplateExtension($templateInstance->getConfigInstance()->getConfigEntry('raw_template_extension')); $templateInstance->setCodeTemplateExtension($templateInstance->getConfigInstance()->getConfigEntry('code_template_extension'));