// Import framework stuff
use Org\Mxchange\CoreFramework\Generic\FrameworkInterface;
-use Org\Mxchange\CoreFramework\Manager\ManageableApplication;
use Org\Mxchange\CoreFramework\Response\Responseable;
/**
*
* @author Roland Haeder <webmaster@shipsimu.org>
* @version 0.0.0
-<<<<<<< HEAD:framework/main/interfaces/template/class_CompileableTemplate.php
- * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2017 Core Developer Team
-=======
- * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2016 Core Developer Team
->>>>>>> Some updates::inc/main/interfaces/template/class_CompileableTemplate.php
+ * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2020 Core Developer Team
* @license GNU GPL 3.0 or any newer version
* @link http://www.shipsimu.org
*
* @param $value The value we want to store in the variable
* @return void
*/
- function assignVariable ($variableName, $value);
+ function assignVariable (string $variableName, $value);
/**
* Load a specified HTML template into the engine
* "html" by default
* @return void
*/
- function loadHtmlTemplate ($template);
+ function loadHtmlTemplate (string $template);
/**
* Load a specified code template into the engine for later compilation
* located in "html" by default
* @return void
*/
- function loadCodeTemplate ($template);
+ function loadCodeTemplate (string $template);
/**
* Load a specified email template into the engine for later compilation
* located in "html" by default
* @return void
*/
- function loadEmailTemplate ($template);
+ function loadEmailTemplate (string $template);
/**
* Compile all variables by inserting their respective values
* @param $value Value to store in variable
* @return void
*/
- function addGroupVariable ($variableName, $value);
+ function addGroupVariable (string $variableName, $value);
/**
* Removes a given variable
* @param $variableGroup Name of variable group (default: 'general')
* @return void
*/
- function removeVariable ($variableName, $variableGroup = 'general');
+ function removeVariable (string $variableName, string $variableGroup = 'general');
/**
* Assign a given congfiguration variable with a value
* @param $variableName The configuration variable we want to assign
* @return void
*/
- function assignConfigVariable ($variableName);
+ function assignConfigVariable (string $variableName);
/**
* Compiles configuration place-holders in all variables. This 'walks'
* @param $variableName Name of the variable we want to assign
* @return void
*/
- function assignTemplateWithVariable ($templateName, $variableName);
+ function assignTemplateWithVariable (string $templateName, string $variableName);
/**
* Transfers the content of this template engine to a given response instance
/**
* Assigns all the application data with template variables
*
- * @param $applicationInstance A manageable application instance
* @return void
*/
- function assignApplicationData (ManageableApplication $applicationInstance);
+ function assignApplicationData ();
/**
* "Compiles" a variable by replacing {?var?} with it's content
* @param $setMatchAsCode Sets $match if readVariable() returns empty result (default: false)
* @return $rawCode Compile code with inserted variable value
*/
- function compileRawCode ($rawCode, $setMatchAsCode = false);
+ function compileRawCode (string $rawCode, bool $setMatchAsCode = false);
/**
* Renames a variable in code and in stack
* @param $newName New name of variable
* @return void
*/
- function renameVariable ($oldName, $newName);
+ function renameVariable (string $oldName, string $newName);
/**
* Renders the given XML content
* @return void
* @throws XmlParserException If an XML error was found
*/
- function renderXmlContent ($content = NULL);
+ function renderXmlContent (string $content = NULL);
/**
* Enables or disables language support
* @param $languageSupport New language support setting
* @return void
*/
- function enableLanguageSupport ($languageSupport = true);
+ function enableLanguageSupport (bool $languageSupport = true);
/**
* Checks whether language support is enabled
* @param $xmlCompacting New XML compacting setting
* @return void
*/
- function enableXmlCompacting ($xmlCompacting = true);
+ function enableXmlCompacting (bool $xmlCompacting = true);
/**
* Checks whether XML compacting is enabled
* @param $uncompactedContent The uncompacted content
* @return $compactedContent The compacted content
*/
- function compactContent ($uncompactedContent);
+ function compactContent (string $uncompactedContent);
/**
* Getter for given variable group
* @param $variableGroup Variable group to check
* @return $varStack Found variable group
*/
- function getVarStack ($variableGroup);
+ function getVarStack (string $variableGroup);
/**
* Settter for variable group
* @param $add Whether add this group
* @return void
*/
- function setVariableGroup ($groupName, $add = true);
+ function setVariableGroup (string $groupName, bool $add = true);
/**
* Getter for template type