From 3dc4c471c90f14f68b91297b8f17012b5f755374 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Mon, 1 Jan 2018 08:40:10 +0100 Subject: [PATCH] Continued: - "imported" classes/interfaces - added task visitors for active and shutdown phase - rename GameManager to GameOptionsManager - updated core framework to latest commit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../city_daemon/class_BaseCityDaemon.php | 1 + .../html/class_CityHtmlCityMapCommand.php | 4 + .../class_CityInformationDatabaseWrapper.php | 2 + .../class_CitySectionsDatabaseWrapper.php | 2 +- ...class_RegionInformationDatabaseWrapper.php | 3 + ...CityDaemonTaskHandlerInitializerFilter.php | 1 + .../verifier/class_CityNameVerifierFilter.php | 1 + .../manager/city/class_CityManager.php | 1 + .../districts/class_CityDistrictsManager.php | 2 +- .../lots/class_CityLotsManager.php | 2 +- .../sections/class_CitySectionsManager.php | 2 +- .../manager/game/class_GameManager.php | 113 ------------------ .../manager/game/class_GameOptionsManager.php | 59 +++++++++ .../city/classes/tasks/class_BaseCityTask.php | 3 + .../class_CityDaemonBuildingGrowthTask.php | 6 + .../classes/tasks/daemon/class_CityDaemon | 9 ++ .../class_CityDaemonHouseholdGrowthTask.php | 6 + .../class_CityDaemonMapExpanderTask.php | 6 + .../city/classes/visitor}/.htaccess | 0 .../city/classes/visitor/tasks/.htaccess | 1 + .../visitor/tasks/class_ActiveTaskVisitor.php | 88 ++++++++++++++ .../tasks/class_ShutdownTaskVisitor.php | 83 +++++++++++++ application/city/config.php | 32 +++-- .../manager/city/class_ManageableCity.php | 6 + .../class_ManageableCityEntities.php | 6 + .../class_ManageableCityDistricts.php | 6 + .../lots/class_ManageableCityLots.php | 6 + .../sections/class_ManageableCitySections.php | 6 + .../interfaces/manager/class_Manageable.php | 6 + .../manager/region/class_ManageableRegion.php | 6 + .../region/class_ManageableRegionMap.php | 6 + core | 2 +- db/city_sections/.htaccess | 1 + 33 files changed, 347 insertions(+), 131 deletions(-) delete mode 100644 application/city/classes/manager/game/class_GameManager.php create mode 100644 application/city/classes/manager/game/class_GameOptionsManager.php rename {db/city_section => application/city/classes/visitor}/.htaccess (100%) create mode 100644 application/city/classes/visitor/tasks/.htaccess create mode 100644 application/city/classes/visitor/tasks/class_ActiveTaskVisitor.php create mode 100644 application/city/classes/visitor/tasks/class_ShutdownTaskVisitor.php create mode 100644 db/city_sections/.htaccess diff --git a/application/city/classes/city_daemon/class_BaseCityDaemon.php b/application/city/classes/city_daemon/class_BaseCityDaemon.php index 6efac65..3543c39 100644 --- a/application/city/classes/city_daemon/class_BaseCityDaemon.php +++ b/application/city/classes/city_daemon/class_BaseCityDaemon.php @@ -3,6 +3,7 @@ namespace Org\Mxchange\City\Daemon; // Import application-specific stuff +use Org\Mxchange\City\Factory\Manager\ManagerFactory; use Org\Mxchange\City\Factory\State\CityStateFactory; use Org\Mxchange\City\Generic\BaseCitySystem; use Org\Mxchange\City\Database\Frontend\Information\CityInformationDatabaseWrapper; diff --git a/application/city/classes/commands/html/class_CityHtmlCityMapCommand.php b/application/city/classes/commands/html/class_CityHtmlCityMapCommand.php index b7d68b4..eccba63 100644 --- a/application/city/classes/commands/html/class_CityHtmlCityMapCommand.php +++ b/application/city/classes/commands/html/class_CityHtmlCityMapCommand.php @@ -2,6 +2,10 @@ // Own namespace namespace Org\Mxchange\City\Command; +// Import application-specific stuff +use Org\Mxchange\City\Factory\Manager\ManagerFactory; +use Org\Mxchange\City\Manager\City\ManageableCity; + // Import framework stuff use Org\Mxchange\CoreFramework\Command\BaseCommand; use Org\Mxchange\CoreFramework\Command\Commandable; diff --git a/application/city/classes/database/frontend/city/class_CityInformationDatabaseWrapper.php b/application/city/classes/database/frontend/city/class_CityInformationDatabaseWrapper.php index 9654293..071b150 100644 --- a/application/city/classes/database/frontend/city/class_CityInformationDatabaseWrapper.php +++ b/application/city/classes/database/frontend/city/class_CityInformationDatabaseWrapper.php @@ -4,7 +4,9 @@ namespace Org\Mxchange\City\Database\Frontend\Information; // Import application-specific stuff use Org\Mxchange\City\Daemon\BaseCityDaemon; +use Org\Mxchange\City\Factory\Manager\ManagerFactory; use Org\Mxchange\City\Helper\CityHelper; +use Org\Mxchange\City\Manager\City\ManageableCity; // Import framework stuff use Org\Mxchange\CoreFramework\Database\Frontend\BaseDatabaseWrapper; diff --git a/application/city/classes/database/frontend/city_entities/sections/class_CitySectionsDatabaseWrapper.php b/application/city/classes/database/frontend/city_entities/sections/class_CitySectionsDatabaseWrapper.php index c7a07c3..6f29ee8 100644 --- a/application/city/classes/database/frontend/city_entities/sections/class_CitySectionsDatabaseWrapper.php +++ b/application/city/classes/database/frontend/city_entities/sections/class_CitySectionsDatabaseWrapper.php @@ -39,7 +39,7 @@ use Org\Mxchange\CoreFramework\Registry\Registerable; */ class CitySectionsDatabaseWrapper extends BaseDatabaseWrapper implements CitySectionsWrapper, Registerable { // Constants for database table names - const DB_TABLE_CITY_SECTIONS = 'city_sections'; + const DB_TABLE_CITY_SECTIONS = 'city_sections'; // Entry id const DB_COLUMN_ENTRY_ID = 'entry_id'; diff --git a/application/city/classes/database/frontend/region/class_RegionInformationDatabaseWrapper.php b/application/city/classes/database/frontend/region/class_RegionInformationDatabaseWrapper.php index 6a4581a..720f818 100644 --- a/application/city/classes/database/frontend/region/class_RegionInformationDatabaseWrapper.php +++ b/application/city/classes/database/frontend/region/class_RegionInformationDatabaseWrapper.php @@ -2,6 +2,9 @@ // Own namespace namespace Org\Mxchange\City\Database\Frontend\RegionInformation; +// Import application-specific stuff +use Org\Mxchange\City\Factory\Manager\ManagerFactory; + // Import framework stuff use Org\Mxchange\CoreFramework\Database\Frontend\BaseDatabaseWrapper; use Org\Mxchange\CoreFramework\Factory\ObjectFactory; diff --git a/application/city/classes/filter/task/city_daemon/class_CityDaemonTaskHandlerInitializerFilter.php b/application/city/classes/filter/task/city_daemon/class_CityDaemonTaskHandlerInitializerFilter.php index 8e73df1..c318db8 100644 --- a/application/city/classes/filter/task/city_daemon/class_CityDaemonTaskHandlerInitializerFilter.php +++ b/application/city/classes/filter/task/city_daemon/class_CityDaemonTaskHandlerInitializerFilter.php @@ -9,6 +9,7 @@ use Org\Mxchange\City\Filter\BaseCityFilter; // Import framework stuff use Org\Mxchange\CoreFramework\Factory\ObjectFactory; use Org\Mxchange\CoreFramework\Filter\Filterable; +use Org\Mxchange\CoreFramework\Registry\Registry; use Org\Mxchange\CoreFramework\Request\Requestable; use Org\Mxchange\CoreFramework\Response\Responseable; diff --git a/application/city/classes/filter/verifier/class_CityNameVerifierFilter.php b/application/city/classes/filter/verifier/class_CityNameVerifierFilter.php index 816badc..b2ad8fb 100644 --- a/application/city/classes/filter/verifier/class_CityNameVerifierFilter.php +++ b/application/city/classes/filter/verifier/class_CityNameVerifierFilter.php @@ -4,6 +4,7 @@ namespace Org\Mxchange\City\Filter\Verifier; // Import application-specific stuff use Org\Mxchange\City\Database\Frontend\Information\CityInformationDatabaseWrapper; +use Org\Mxchange\City\Factory\Manager\ManagerFactory; // Import framework stuff use Org\Mxchange\CoreFramework\Filter\BaseFilter; diff --git a/application/city/classes/manager/city/class_CityManager.php b/application/city/classes/manager/city/class_CityManager.php index 208a356..6d79528 100644 --- a/application/city/classes/manager/city/class_CityManager.php +++ b/application/city/classes/manager/city/class_CityManager.php @@ -4,6 +4,7 @@ namespace Org\Mxchange\City\Manager\City; // Import application-specific stuff use Org\Mxchange\City\Database\Frontend\Information\CityInformationDatabaseWrapper; +use Org\Mxchange\City\Factory\Manager\ManagerFactory; // Import framework stuff use Org\Mxchange\CoreFramework\Bootstrap\FrameworkBootstrap; diff --git a/application/city/classes/manager/city_entities/districts/class_CityDistrictsManager.php b/application/city/classes/manager/city_entities/districts/class_CityDistrictsManager.php index d308d42..038e22e 100644 --- a/application/city/classes/manager/city_entities/districts/class_CityDistrictsManager.php +++ b/application/city/classes/manager/city_entities/districts/class_CityDistrictsManager.php @@ -1,6 +1,6 @@ - * @version 0.0.0 - * @copyright Copyright (c) 2015, 2016 City Developer Team - * @license GNU GPL 3.0 or any newer version - * @link http://www.ship-simu.org - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -class RegionManager extends BaseManager implements ManageableRegion { - /** - * Protected constructor - * - * @return void - */ - protected function __construct () { - // Call parent constructor - parent::__construct(__CLASS__); - } - - /** - * Creates an instance of this class - * - * @return $managerInstance An instance of a ManageableRegion class - */ - public final static function createRegionManager () { - // Get new instance - $managerInstance = new RegionManager(); - - // Get database wrapper - $wrapperInstance = DatabaseWrapperFactory::createWrapperByConfiguredName('region_info_db_wrapper_class'); - - // And set it here - $managerInstance->setWrapperInstance($wrapperInstance); - - // Return the prepared instance - return $managerInstance; - } - - /** - * Checks whether the current user has already founded a region - * - * @return $isFounded Whether the current user has already founded a region - */ - public function ifUserHasCreatedRegion () { - // Check if the currently set user has already founded a region - $isFounded = $this->getWrapperInstance()->ifUserHasCreatedRegion(); - - // Return result - return $isFounded; - } - - /** - * Checks whether the given region name is already taken - * - * @para $regionName Name of region - * @return $isTaken Whether the given region name is already taken - */ - public function ifRegionNameExists ($regionName) { - // Check if the given region name is taken - $isTaken = $this->getWrapperInstance()->ifRegionExists($regionName); - - // Return result - return $isTaken; - } - - /** - * Founds the first region. A dummy region will also be created - * - * @return $resultInstance Found result after creating it - */ - public function createFirstRegion () { - // Dummy name - // @TODO Move to language system - $regionName = 'Region 1'; - - // Some pre-checks - assert(!$this->ifUserHasCreatedRegion()); - assert(!$this->ifRegionNameExists($regionName)); - - // First region can now be created - $this->getWrapperInstance()->createRegionByName($regionName); - - // Then try to find it - assert($this->ifRegionNameExists($regionName)); - - // Get result instance - $resultInstance = $this->getResultInstance(); - - // And return it - return $resultInstance; - } -} diff --git a/application/city/classes/manager/game/class_GameOptionsManager.php b/application/city/classes/manager/game/class_GameOptionsManager.php new file mode 100644 index 0000000..6eea04d --- /dev/null +++ b/application/city/classes/manager/game/class_GameOptionsManager.php @@ -0,0 +1,59 @@ + + * @version 0.0.0 + * @copyright Copyright (c) 2015, 2016 City Developer Team + * @license GNU GPL 3.0 or any newer version + * @link http://www.ship-simu.org + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +class GameOptionsManager extends BaseManager implements ManageableGame { + /** + * Protected constructor + * + * @return void + */ + protected function __construct () { + // Call parent constructor + parent::__construct(__CLASS__); + } + + /** + * Creates an instance of this class + * + * @return $managerInstance An instance of a ManageableRegion class + */ + public final static function createGameOptionsManager () { + // Get new instance + $managerInstance = new GameOptionsManager(); + + // Get database wrapper + $wrapperInstance = DatabaseWrapperFactory::createWrapperByConfiguredName('game_options_db_wrapper_class'); + + // And set it here + $managerInstance->setWrapperInstance($wrapperInstance); + + // Return the prepared instance + return $managerInstance; + } +} diff --git a/application/city/classes/tasks/class_BaseCityTask.php b/application/city/classes/tasks/class_BaseCityTask.php index b61c2ea..a489bbd 100644 --- a/application/city/classes/tasks/class_BaseCityTask.php +++ b/application/city/classes/tasks/class_BaseCityTask.php @@ -5,6 +5,9 @@ namespace Org\Mxchange\City\Task; // Import application-specific stuff use Org\Mxchange\City\Helper\CityHelper; +// Import framework stuff +use Org\Mxchange\CoreFramework\Task\BaseTask; + /** * A general CityTask class * diff --git a/application/city/classes/tasks/daemon/building/class_CityDaemonBuildingGrowthTask.php b/application/city/classes/tasks/daemon/building/class_CityDaemonBuildingGrowthTask.php index 0a0a817..357f634 100644 --- a/application/city/classes/tasks/daemon/building/class_CityDaemonBuildingGrowthTask.php +++ b/application/city/classes/tasks/daemon/building/class_CityDaemonBuildingGrowthTask.php @@ -4,6 +4,12 @@ namespace Org\Mxchange\City\Daemon\Task\Growth\Building; // Import application-specific stuff use Org\Mxchange\City\Daemon\Factory\CityDaemonFactory; +use Org\Mxchange\City\Task\BaseCityTask; + +// Import framework stuff +use Org\Mxchange\CoreFramework\Task\Taskable; +use Org\Mxchange\CoreFramework\Visitor\Visitable; +use Org\Mxchange\CoreFramework\Visitor\Visitor; /** * A BuildingGrowth city daemon-task diff --git a/application/city/classes/tasks/daemon/class_CityDaemon b/application/city/classes/tasks/daemon/class_CityDaemon index a230088..073f377 100644 --- a/application/city/classes/tasks/daemon/class_CityDaemon +++ b/application/city/classes/tasks/daemon/class_CityDaemon @@ -1,4 +1,13 @@ + * @version 0.0.0 + * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2017 Hub Developer Team + * @license GNU GPL 3.0 or any newer version + * @link http://www.shipsimu.org + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +class ActiveTaskVisitor extends BaseVisitor implements TaskVisitor, DecoratorVisitor { + /** + * Protected constructor + * + * @return void + */ + protected function __construct () { + // Call parent constructor + parent::__construct(__CLASS__); + + // Set visitor mode + $this->setVisitorMode('task'); + } + + /** + * Creates an instance of this class + * + * @return $visitorInstance An instance a Visitorable class + */ + public static final function createActiveTaskVisitor () { + // Get new instance + $visitorInstance = new ActiveTaskVisitor(); + + // Return the prepared instance + return $visitorInstance; + } + + /** + * Visits the given task instance + * + * @param $taskInstance A Taskable instance + * @return void + */ + public function visitTask (Taskable $taskInstance) { + // Execute the task from this visitor + //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('ACTIVE-TASK-VISITOR: Visiting task ' . $taskInstance->__toString() . ' - CALLED!'); + $taskInstance->executeTask(); + //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('ACTIVE-TASK-VISITOR: Visiting task ' . $taskInstance->__toString() . ' - EXIT!'); + } + + /** + * Visits the given decorator instance + * + * @param $decoratorInstance A decorator instance + * @return void + */ + public function visitDecorator (BaseDecorator $decoratorInstance) { + /* + * A decorator itself can never become an active task so this method + * remains empty. + */ + //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('ACTIVE-TASK-VISITOR: decoratorInstance=%s - CALLED!', $decoratorInstance->__toString())); + } + +} diff --git a/application/city/classes/visitor/tasks/class_ShutdownTaskVisitor.php b/application/city/classes/visitor/tasks/class_ShutdownTaskVisitor.php new file mode 100644 index 0000000..1996b48 --- /dev/null +++ b/application/city/classes/visitor/tasks/class_ShutdownTaskVisitor.php @@ -0,0 +1,83 @@ + + * @version 0.0.0 + * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2017 Hub Developer Team + * @license GNU GPL 3.0 or any newer version + * @link http://www.shipsimu.org + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +class ShutdownTaskVisitor extends BaseVisitor implements TaskVisitor, DecoratorVisitor { + /** + * Protected constructor + * + * @return void + */ + protected function __construct () { + // Call parent constructor + parent::__construct(__CLASS__); + + // Set visitor mode + $this->setVisitorMode('task'); + } + + /** + * Creates an instance of this class + * + * @return $visitorInstance An instance a Visitorable class + */ + public static final function createShutdownTaskVisitor () { + // Get new instance + $visitorInstance = new ShutdownTaskVisitor(); + + // Return the prepared instance + return $visitorInstance; + } + + /** + * Visits the given task instance + * + * @param $taskInstance A Taskable instance + * @return void + */ + public function visitTask (Taskable $taskInstance) { + // Shutdown the task instance + $taskInstance->doShutdown(); + } + + /** + * Visits the given decorator instance + * + * @param $decoratorInstance A decorator instance + * @return void + */ + public function visitDecorator (BaseDecorator $decoratorInstance) { + // Shutdown the decorator instance + $decoratorInstance->doShutdown(); + } + +} diff --git a/application/city/config.php b/application/city/config.php index 30e8470..28745ee 100644 --- a/application/city/config.php +++ b/application/city/config.php @@ -56,13 +56,13 @@ $cfg->setConfigEntry('game_options_db_wrapper_class', 'CityGameOptionsDatabaseWr $cfg->setConfigEntry('region_map_db_wrapper_class', 'RegionMapDatabaseWrapper'); // CFG: CITY-SECTIONS-DB-WRAPPER-CLASS -$cfg->setConfigEntry('city_sections_db_wrapper_class', 'CitySectionsDatabaseWrapper'); +$cfg->setConfigEntry('city_sections_db_wrapper_class', 'Org\Mxchange\City\Database\Frontend\Sections\CitySectionsDatabaseWrapper'); // CFG: CITY-LOTS-DB-WRAPPER-CLASS -$cfg->setConfigEntry('city_lots_db_wrapper_class', 'CityLotsDatabaseWrapper'); +$cfg->setConfigEntry('city_lots_db_wrapper_class', 'Org\Mxchange\City\Database\Frontend\Lots\CityLotsDatabaseWrapper'); // CFG: CITY-DISTRICTS-DB-WRAPPER-CLASS -$cfg->setConfigEntry('city_districts_db_wrapper_class', 'CityDistrictsDatabaseWrapper'); +$cfg->setConfigEntry('city_districts_db_wrapper_class', 'Org\Mxchange\City\Database\Frontend\Districts\CityDistrictsDatabaseWrapper'); // CFG: CITY-INIT-STATE-CLASS $cfg->setConfigEntry('city_init_state_class', 'Org\Mxchange\City\State\Init\CityInitState'); @@ -477,7 +477,7 @@ $cfg->setConfigEntry('user_points_db_wrapper_class', 'UserPointsDatabaseWrapper' $cfg->setConfigEntry('user_government_wrapper_class', 'UserGovernmentDatabaseWrapper'); // CFG: PAYMENT-DB-WRAPPER-CLASS -$cfg->setConfigEntry('payment_db_wrapper_class', 'PaymentsDatabaseWrapper'); +$cfg->setConfigEntry('payment_db_wrapper_class', 'Org\Mxchange\CoreFramework\Database\Frontend\PaymentsDatabaseWrapper'); // CFG: LOGIN-ENABLED $cfg->setConfigEntry('login_enabled', 'Y'); @@ -486,22 +486,22 @@ $cfg->setConfigEntry('login_enabled', 'Y'); $cfg->setConfigEntry('login_type', 'username'); // CFG: CITY-MANAGER-CLASS -$cfg->setConfigEntry('city_manager_class', 'CityManager'); +$cfg->setConfigEntry('city_manager_class', 'Org\Mxchange\City\Manager\City\CityManager'); // CFG: CITY-SECTIONS-MANAGER-CLASS -$cfg->setConfigEntry('city_sections_manager_class', 'CitySectionsManager'); +$cfg->setConfigEntry('city_sections_manager_class', 'Org\Mxchange\City\Manager\Entities\Sections\CitySectionsManager'); // CFG: CITY-LOTS-MANAGER-CLASS -$cfg->setConfigEntry('city_lots_manager_class', 'CityLotsManager'); +$cfg->setConfigEntry('city_lots_manager_class', 'Org\Mxchange\City\Manager\Entities\Lots\CityLotsManager'); // CFG: CITY-DISTRICTS-MANAGER-CLASS -$cfg->setConfigEntry('city_districts_manager_class', 'CityDistrictsManager'); +$cfg->setConfigEntry('city_districts_manager_class', 'Org\Mxchange\City\Manager\Entities\Districts\CityDistrictsManager'); // CFG: REGION-MANAGER-CLASS -$cfg->setConfigEntry('region_manager_class', 'RegionManager'); +$cfg->setConfigEntry('region_manager_class', 'Org\Mxchange\City\Manager\Region\RegionManager'); // CFG: REGION-MAP-MANAGER-CLASS -$cfg->setConfigEntry('region_map_manager_class', 'RegionMapManager'); +$cfg->setConfigEntry('region_map_manager_class', 'Org\Mxchange\City\Manager\RegionMap\RegionMapManager'); /****************************************************************************** * Daemon * @@ -550,7 +550,7 @@ $cfg->setConfigEntry('news_reader_daemon_class', 'Org\Mxchange\CoreFramework\Rea $cfg->setConfigEntry('news_daemon_limit', 5); // CFG: CITY-DAEMON-MAP-EXPANDER-TASK-CLASS -$cfg->setConfigEntry('city_daemon_map_expander_task_class', 'CityDaemonMapExpanderTask'); +$cfg->setConfigEntry('city_daemon_map_expander_task_class', 'Org\Mxchange\City\Daemon\Task\Expander\Map\CityDaemonMapExpanderTask'); // CFG: TASK-MAP-EXPANDER-STARTUP-DELAY $cfg->setConfigEntry('task_map_expander_startup_delay', 500); @@ -562,7 +562,7 @@ $cfg->setConfigEntry('task_map_expander_interval_delay', 100); $cfg->setConfigEntry('task_map_expander_max_runs', 0); // CFG: CITY-DAEMON-HOUSEHOLD-GROWTH-TASK-CLASS -$cfg->setConfigEntry('city_daemon_household_growth_task_class', 'CityDaemonHouseholdGrowthTask'); +$cfg->setConfigEntry('city_daemon_household_growth_task_class', 'Org\Mxchange\City\Daemon\Task\Growth\Household\CityDaemonHouseholdGrowthTask'); // CFG: TASK-HOUSEHOLD-GROWTH-STARTUP-DELAY $cfg->setConfigEntry('task_household_growth_startup_delay', 1000); @@ -574,7 +574,7 @@ $cfg->setConfigEntry('task_household_growth_interval_delay', 200); $cfg->setConfigEntry('task_household_growth_max_runs', 0); // CFG: CITY-DAEMON-BUILDING-GROWTH-TASK-CLASS -$cfg->setConfigEntry('city_daemon_building_growth_task_class', 'CityDaemonBuildingGrowthTask'); +$cfg->setConfigEntry('city_daemon_building_growth_task_class', 'Org\Mxchange\City\Daemon\Task\Growth\Building\CityDaemonBuildingGrowthTask'); // CFG: TASK-BUILDING-GROWTH-STARTUP-DELAY $cfg->setConfigEntry('task_building_growth_startup_delay', 1000); @@ -593,3 +593,9 @@ $cfg->setConfigEntry('city_max_initial_up_expansion', 5); // CFG: CITY-MAX-INITIAL-DOWN-EXPANSION $cfg->setConfigEntry('city_max_initial_down_expansion', 3); + +// CFG: ACTIVE-TASK-VISITOR-CLASS +$cfg->setConfigEntry('active_task_visitor_class', 'Org\Mxchange\City\Visitor\Task\Active\ActiveTaskVisitor'); + +// CFG: SHUTDOWN-TASK-VISITOR-CLASS +$cfg->setConfigEntry('shutdown_task_visitor_class', 'Org\Mxchange\CoreFramework\Visitor\Task\Shutdown\ShutdownTaskVisitor'); diff --git a/application/city/interfaces/manager/city/class_ManageableCity.php b/application/city/interfaces/manager/city/class_ManageableCity.php index 0055983..dd17ca3 100644 --- a/application/city/interfaces/manager/city/class_ManageableCity.php +++ b/application/city/interfaces/manager/city/class_ManageableCity.php @@ -1,4 +1,10 @@