*
* @author Roland Haeder <webmaster@shipsimu.org>
* @version 0.0
- * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2015 Core Developer Team
+ * @copyright Copyright (c) 2015 City Developer Team
* @license GNU GPL 3.0 or any newer version
*
* This program is free software: you can redistribute it and/or modify
Registry::getRegistry()->addInstance('app', $this);
// Default response is console
- $response = $this->getResponseTypeFromSystem();
- $responseType = $this->getResponseTypeFromSystem();
+ $response = self::getResponseTypeFromSystem();
+ $responseType = self::getResponseTypeFromSystem();
// Create a new request object
$requestInstance = ObjectFactory::createObjectByName($this->convertToClassName($response) . 'Request');
// If it is null then get default command
if (is_null($commandName)) {
// Get default command
- $commandName = $responseInstance->getDefaultCommand();
+ $commandName = $responseInstance->determineDefaultCommand();
// Set it in request
$requestInstance->setRequestElement('command', $commandName);
// Get a controller instance as well
$this->setControllerInstance($resolverInstance->resolveController());
- // Launch the test suite here
+ // Initialize language system
+ $languageInstance = ObjectFactory::createObjectByConfiguredName('language_system_class');
+
+ // And set it here
+ $this->setLanguageInstance($languageInstance);
+
+ // Launch the game here
$this->getControllerInstance()->handleRequest($requestInstance, $responseInstance);
// -------------------------- Shutdown phase --------------------------
- // @TODO $this->getControllerInstance()->executeShutdownFilters($requestInstance, $responseInstance);
+ $this->getControllerInstance()->executeShutdownFilters($requestInstance, $responseInstance);
+ }
+
+ /**
+ * Assigns extra application-depending data
+ *
+ * @param $templateInstance An instance of a CompileableTemplate
+ * @return void
+ * @todo Nothing to add?
+ */
+ public function assignExtraTemplateData (CompileableTemplate $templateInstance) {
}
/**
* @return $masterTemplateName Name of the master template
*/
public function buildMasterTemplateName () {
- return 'node_main';
+ return 'city_main';
}
}