]> git.mxchange.org Git - city.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Sun, 19 Feb 2023 01:37:50 +0000 (02:37 +0100)
committerRoland Häder <roland@mxchange.org>
Sun, 19 Feb 2023 01:37:50 +0000 (02:37 +0100)
- used <trace|debug>Mesage() instead of deprecated debugOutput()

15 files changed:
application/city/class_ApplicationHelper.php
application/city/classes/city_daemon/class_BaseCityDaemon.php
application/city/classes/commands/console/class_CityConsoleDaemonCommand.php
application/city/classes/database/frontend/city/class_CityInformationDatabaseFrontend.php
application/city/classes/database/frontend/city_entities/sections/class_CitySectionsDatabaseFrontend.php
application/city/classes/database/frontend/region/class_RegionInformationDatabaseWrapper.php
application/city/classes/database/frontend/region_map/class_RegionMapDatabaseFrontend.php
application/city/classes/factories/states/city/class_CityStateFactory.php
application/city/classes/filter/city_daemon/class_CityDaemonInitializationFilter.php
application/city/classes/filter/class_BaseCityFilter.php
application/city/classes/registration/class_CityRegistration.php
application/city/classes/tasks/daemon/building/class_CityDaemonBuildingGrowthTask.php
application/city/classes/tasks/daemon/household/class_CityDaemonHouseholdGrowthTask.php
application/city/classes/tasks/daemon/map_expander/class_CityDaemonMapExpanderTask.php
application/city/classes/visitor/tasks/class_ActiveTaskVisitor.php

index 68601c8dfc6ab252530028061e8e5e92a59a28b1..bce5068bce256ec5220569733545b2516221add3 100644 (file)
@@ -161,9 +161,9 @@ class ApplicationHelper extends BaseApplication implements ManageableApplication
                // Is console request?
                if (FrameworkBootstrap::getRequestTypeFromSystem() == 'console') {
                        // -------------------------- Shutdown phase --------------------------
-                       self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: Shutdown in progress ...');
+                       self::createDebugInstance(__CLASS__, __LINE__)->debugMessage('MAIN: Shutdown in progress ...');
                        $this->getControllerInstance()->executeShutdownFilters($requestInstance, $responseInstance);
-                       self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: Shutdown completed. (This is the last line.)');
+                       self::createDebugInstance(__CLASS__, __LINE__)->debugMessage('MAIN: Shutdown completed. (This is the last line.)');
                }
        }
 
index 90e59b147bc1cdada7dd046606952e97b999592a..07f00df15c7bcb859b5c2d3c9d4354e41aa57faf 100644 (file)
@@ -114,14 +114,14 @@ abstract class BaseCityDaemon extends BaseCitySystem implements Updateable, Adda
                $applicationInstance = ApplicationHelper::getSelfInstance();
 
                // Output all lines
-               self::createDebugInstance(__CLASS__)->debugOutput(' ');
-               self::createDebugInstance(__CLASS__)->debugOutput($applicationInstance->getAppName() . ' v' . $applicationInstance->getAppVersion() . ' - ' . FrameworkBootstrap::getRequestInstance()->getRequestElement('mode') . ' daemon starting');
-               self::createDebugInstance(__CLASS__)->debugOutput('Copyright (c) 2015 - 2023 City Developer Team');
-               self::createDebugInstance(__CLASS__)->debugOutput(' ');
-               self::createDebugInstance(__CLASS__)->debugOutput('This program comes with ABSOLUTELY NO WARRANTY; for details see docs/COPYING.');
-               self::createDebugInstance(__CLASS__)->debugOutput('This is free software, and you are welcome to redistribute it under certain');
-               self::createDebugInstance(__CLASS__)->debugOutput('conditions; see docs/COPYING for details.');
-               self::createDebugInstance(__CLASS__)->debugOutput(' ');
+               self::createDebugInstance(__CLASS__)->debugMessage(' ');
+               self::createDebugInstance(__CLASS__)->debugMessage($applicationInstance->getAppName() . ' v' . $applicationInstance->getAppVersion() . ' - ' . FrameworkBootstrap::getRequestInstance()->getRequestElement('mode') . ' daemon starting');
+               self::createDebugInstance(__CLASS__)->debugMessage('Copyright (c) 2015 - 2023 City Developer Team');
+               self::createDebugInstance(__CLASS__)->debugMessage(' ');
+               self::createDebugInstance(__CLASS__)->debugMessage('This program comes with ABSOLUTELY NO WARRANTY; for details see docs/COPYING.');
+               self::createDebugInstance(__CLASS__)->debugMessage('This is free software, and you are welcome to redistribute it under certain');
+               self::createDebugInstance(__CLASS__)->debugMessage('conditions; see docs/COPYING for details.');
+               self::createDebugInstance(__CLASS__)->debugMessage(' ');
        }
 
        /**
@@ -200,7 +200,7 @@ abstract class BaseCityDaemon extends BaseCitySystem implements Updateable, Adda
 
                // ----------------------- Last step from here ------------------------
                // Activate the city daemon. This is ALWAYS the last step in this method
-               /* DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('CITY[' . __METHOD__ . ':' . __LINE__ . ']: state=' . $this->getStateInstance()->__toString() . ' - Activating ...');
+               /* DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('CITY[' . __METHOD__ . ':' . __LINE__ . ']: state=' . $this->getStateInstance()->__toString() . ' - Activating ...');
                $this->getStateInstance()->citySimulationIsActivated();
                // ---------------------- Last step until here ------------------------
        }
@@ -251,7 +251,7 @@ abstract class BaseCityDaemon extends BaseCitySystem implements Updateable, Adda
                                $dataSetInstance->addCriteria($element, $cityData[$element]);
                        } else {
                                // Output warning message
-                               /* DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('CITY[' . __METHOD__ . ':' . __LINE__ . ']: addArrayToDataSet(): Element ' . $element . ' not found in CityData array.');
+                               self::createDebugInstance(__CLASS__)->warningMessage(sprintf('BASE-CITY-DAEMON: Element %s not found in CityData array.', $element));
                        }
                }
        }
index 546bb29703f50d2578572947833024b94b8ca661..fec4f7afb3eacc66724e031b7adfe2059efdddcf 100644 (file)
@@ -84,9 +84,9 @@ class CityConsoleDaemonCommand extends BaseCommand implements Commandable {
                 * extra arguments which mostly override config entries or enable special
                 * features within the hub (none is ready at this development stage)
                 */
-               self::createDebugInstance(__CLASS__)->debugOutput('BOOTSTRAP: Beginning with bootstrap...');
+               self::createDebugInstance(__CLASS__)->debugMessage('BOOTSTRAP: Beginning with bootstrap...');
                $applicationInstance->getControllerInstance()->executeBootstrapFilters($requestInstance, $responseInstance);
-               self::createDebugInstance(__CLASS__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
+               self::createDebugInstance(__CLASS__)->debugMessage('BOOTSTRAP: Bootstrap finished.');
 
                // Get city instance
                $cityInstance = CityDaemonFactory::createCityDaemonInstance();
@@ -105,7 +105,7 @@ class CityConsoleDaemonCommand extends BaseCommand implements Commandable {
                $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
 
                // Debug message
-               self::createDebugInstance(__CLASS__)->debugOutput('MAIN: --- Entering main loop. ---');
+               self::createDebugInstance(__CLASS__)->debugMessage('MAIN: --- Entering main loop. ---');
 
                /*
                 * ----------------------------- Main loop ----------------------------
@@ -119,7 +119,7 @@ class CityConsoleDaemonCommand extends BaseCommand implements Commandable {
                }
 
                // Debug message
-               self::createDebugInstance(__CLASS__)->debugOutput('MAIN: --- Leaving main loop. ---');
+               self::createDebugInstance(__CLASS__)->debugMessage('MAIN: --- Leaving main loop. ---');
        }
 
        /**
index b643401be8362c1eb6fcd9ddf95bdca7f10fe477..9b69ed2f92ce4406bbd75a30930e127c1836f108 100644 (file)
@@ -132,7 +132,7 @@ class CityInformationDatabaseFrontend extends BaseDatabaseFrontend implements Ci
         */
        public function removeNonPublicDataFromArray(array $data) {
                // Currently call only inner method
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('CITY-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('CITY-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
                $data = parent::removeNonPublicDataFromArray($data);
 
                // Return cleaned data
index f8608118d05fbbde90d3680763241cc67b1f2561..a3b7fda6d3d8c89e81aec483675c96696ec2ce5f 100644 (file)
@@ -130,7 +130,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
         */
        public function ifCityHasSections (int $cityId) {
                // Check parameter
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: cityId=%d - CALLED!', $cityId));
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->traceMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: cityId=%d - CALLED!', $cityId));
                if ($cityId < 1) {
                        // Throw IAE
                        throw new InvalidArgumentException(sprintf('cityId=%d is not a valid id', $cityId), FrameworkInterface::EXCEPTION_INVALID_ARGUMENT);
@@ -152,11 +152,11 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                $resultInstance = $this->doSelectByCriteria($searchInstance);
 
                // Check if there is one entry
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: resultInstance=%s', $resultInstance->__toString()));
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: resultInstance=%s', $resultInstance->__toString()));
                $isFound = $resultInstance->next();
 
                // Return result
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: isFound=%d - EXIT!', intval($isFound)));
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->traceMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: isFound=%d - EXIT!', intval($isFound)));
                return $isFound;
        }
 
@@ -171,7 +171,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
         */
        public function doInitialCityExpansion (int $cityId) {
                // Check parameter
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: cityId=%d - CALLED!', $cityId));
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->traceMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: cityId=%d - CALLED!', $cityId));
                if ($cityId < 1) {
                        // Throw IAE
                        throw new InvalidArgumentException(sprintf('cityId=%d is not a valid id', $cityId), FrameworkInterface::EXCEPTION_INVALID_ARGUMENT);
@@ -199,7 +199,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                $totalSections = (($radius + 1) * ($radius + 1) * $maxUp * ($maxDown + 1));
 
                // Get data set instance
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: radius=%d,maxUp=%d,maxDown=%d,totalSections=%d', $radius, $maxUp, $maxDown, $totalSections));
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: radius=%d,maxUp=%d,maxDown=%d,totalSections=%d', $radius, $maxUp, $maxDown, $totalSections));
                $dataSetInstance = ObjectFactory::createObjectByConfiguredName('dataset_criteria_class', array(self::DB_TABLE_CITY_SECTIONS));
 
                // Add values for "zero point"
@@ -232,7 +232,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                $sections = [];
 
                // Output message to ask for user's patience ...
-               self::createDebugInstance(__CLASS__)->debugOutput(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: Writing %d sections for city %d ... (this may takes some time)', $totalSections, $cityId));
+               self::createDebugInstance(__CLASS__)->debugMessage(sprintf('CITY-SECTIONS-DATABASE-FRONTEND: Writing %d sections for city %d ... (this may takes some time)', $totalSections, $cityId));
 
                // Expand half of it to north/south (north=positive, south=negative)
                for ($north = 1; $north < round($radius / 2); $north++) {
@@ -241,7 +241,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                                // Expand up/down (including "zero point")
                                for ($z = $maxDown; $z < ($maxUp + 1); $z++) {
                                        // Fill array up with south/east/down ids
-                                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('[' . __METHOD__ . ':' . __LINE__ . ']: north=' . $north . ',west=' . $west . ',z=' . $z);
+                                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('[' . __METHOD__ . ':' . __LINE__ . ']: north=' . $north . ',west=' . $west . ',z=' . $z);
                                        $sections[($north * -1)][($west * -1)][$z]['type'] = self::SECTION_TYPE_EMPTY_LAND;
                                        $sections[($north * -1)][($west * -1)][$z]['sub']  = self::SECTION_SUB_TYPE_GRASS;
 
@@ -262,7 +262,7 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                                // Loop through up/down values
                                foreach ($sectionY as $z => $sectionData) {
                                        // Set all coordinates for positive directions
-                                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ',y=' . $y . ',z=' . $z . ',sectionId=' . $sectionId);
+                                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ',y=' . $y . ',z=' . $z . ',sectionId=' . $sectionId);
                                        $dataSetInstance->setCriteria(self::DB_COLUMN_SECTION_ID        , $sectionId);
                                        $dataSetInstance->setCriteria(self::DB_COLUMN_SECTION_POSITION_X, $x);
                                        $dataSetInstance->setCriteria(self::DB_COLUMN_SECTION_POSITION_Y, $y);
@@ -278,14 +278,14 @@ class CitySectionsDatabaseFrontend extends BaseDatabaseFrontend implements CityS
                                }
 
                                // Debug message
-                               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ',y=' . $y . ' has been written.');
+                               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ',y=' . $y . ' has been written.');
                        }
 
                        // Debug message
-                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ' has been written.');
+                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('[' . __METHOD__ . ':' . __LINE__ . ']: x=' . $x . ' has been written.');
                }
 
                // Thank you for waiting! :-)
-               self::createDebugInstance(__CLASS__)->debugOutput('[' . __METHOD__ . ':' . __LINE__ . ']: A total of ' . $totalSections . ' sections has been written for city id ' . $cityId . '.');
+               self::createDebugInstance(__CLASS__)->debugMessage(sprintf('A total of %d sections has been written for city id %s', $totalSections, $cityId));
        }
 }
index 83de450e13ca1342d65b677999223d8c77ab2977..d78d6bdbb52d99d3ee4f104a65dee96184662fc2 100644 (file)
@@ -82,7 +82,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
         */
        public function removeNonPublicDataFromArray(array $data) {
                // Currently call only inner method
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('REGION-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('REGION-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
                $data = parent::removeNonPublicDataFromArray($data);
 
                // Return cleaned data
@@ -97,7 +97,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
         */
        public function ifUserHasCreatedRegion () {
                // Get user instance
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('REGION-INFORMATION-DATABASE-WRAPPER: CALLED!');
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage('REGION-INFORMATION-DATABASE-WRAPPER: CALLED!');
                $userInstance = GenericRegistry::getRegistry()->getInstance('user');
 
                // Now get a search criteria instance
@@ -125,7 +125,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
                $hasFounded = $resultInstance->valid();
 
                // Return result
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: hasFounded=%d - EXIT!', intval($hasFounded)));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: hasFounded=%d - EXIT!', intval($hasFounded)));
                return $hasFounded;
        }
 
@@ -139,7 +139,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
         */
        public function ifRegionExists (string $regionName) {
                // Pre-check name
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: regionName=%s - CALLED!', $regionName));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: regionName=%s - CALLED!', $regionName));
                if (empty($regionName)) {
                        // Throw IAE
                        throw new InvalidArgumentException('Parameter "regionName" is empty', FramworkInterface::EXCEPTION_INVALID_ARGUMENT);
@@ -156,11 +156,11 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
                $resultInstance = $this->doSelectByCriteria($searchInstance);
 
                // Check it
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: resultInstance[]=%s', gettype($resultInstance)));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: resultInstance[]=%s', gettype($resultInstance)));
                $isTaken = $resultInstance->next();
 
                // Get manger instance
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: isTaken=%d', intval($isTaken)));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: isTaken=%d', intval($isTaken)));
                $managerInstance = ManagerFactory::createManagerByType('region');
 
                // Make sure the instance is valid
@@ -173,7 +173,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
                $managerInstance->setResultInstance($resultInstance);
 
                // Return result
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: isTaken=%d - EXIT!', intval($isTaken)));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: isTaken=%d - EXIT!', intval($isTaken)));
                return $isTaken;
        }
 
@@ -187,7 +187,7 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
         */
        public function createRegionByName (string $regionName) {
                // Pre-check name
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: regionName=%s - CALLED!', $regionName));
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage(sprintf('REGION-INFORMATION-DATABASE-WRAPPER: regionName=%s - CALLED!', $regionName));
                if (empty($regionName)) {
                        // Throw IAE
                        throw new InvalidArgumentException('Parameter "regionName" is empty', FramworkInterface::EXCEPTION_INVALID_ARGUMENT);
@@ -217,6 +217,6 @@ class RegionInformationDatabaseFrontend extends BaseDatabaseFrontend implements
                assert($this->ifRegionExists($regionName));
 
                // Trace message
-               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('REGION-INFORMATION-DATABASE-WRAPPER: EXIT!');
+               /* NOISY-DEBUG */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage('REGION-INFORMATION-DATABASE-WRAPPER: EXIT!');
        }
 }
index 3b35fe6a3e4225540450778ef0fe1a610d443289..dacfc492f408333fd1577a87926ef73210c5ba16 100644 (file)
@@ -71,7 +71,7 @@ class RegionMapDatabaseFrontend extends BaseDatabaseFrontend implements RegionMa
         */
        public function removeNonPublicDataFromArray(array $data) {
                // Currently call only inner method
-               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('REGION-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
+               /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('REGION-WRAPPER[' . __METHOD__ . ':' . __LINE__ . ']: Calling parent::removeNonPublicDataFromArray(data) ...');
                $data = parent::removeNonPublicDataFromArray($data);
 
                // Return cleaned data
index 3ae6a87b9e5a4136cc3724691008973914aac220..34f19bb82d4da7c34766f4cc21910a9e1f17328a 100644 (file)
@@ -66,7 +66,7 @@ class CityStateFactory extends BaseFactory {
                $cityInstance = CityDaemonFactory::createCityDaemonInstance();
 
                // Debug message
-               self::createDebugInstance(__CLASS__)->debugOutput('CITY-STATE-FACTORY: City daemon state has changed from ' . $cityInstance->getPrintableState() . ' to ' . $stateInstance->getStateName() . '.');
+               self::createDebugInstance(__CLASS__)->debugMessage('CITY-STATE-FACTORY: City daemon state has changed from ' . $cityInstance->getPrintableState() . ' to ' . $stateInstance->getStateName() . '.');
 
                // Once we have that state, set it in the city instance
                $cityInstance->setStateInstance($stateInstance);
index 54b194fb2561dded0540f6bec32f5a95622a2069..d83ff7bf35d6ec49fe2acf58d7748e00f7ce474d 100644 (file)
@@ -76,6 +76,6 @@ class CityDaemonInitializationFilter extends BaseCityFilter implements Filterabl
                }
 
                // Debug message
-               /* DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('CITY-INIT-FILTER[' . __METHOD__ . ':' . __LINE__ . ']: City daemon has been added to registry.');
+               /* DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage('CITY-INIT-FILTER[' . __METHOD__ . ':' . __LINE__ . ']: City daemon has been added to registry.');
        }
 }
index 6972b7ffaa7a3f89612ab4585ea56ddabe718616..aa50ed495ac81b1eef74e5906e9b1eab400d48db 100644 (file)
@@ -71,7 +71,7 @@ abstract class BaseCityFilter extends BaseFilter {
                $templateInstance->renderXmlContent($messageContent);
 
                // Debug message
-               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(str_replace('_', '-', strtoupper($messageType)) . '-TAG: Handling ' . strlen($messageContent) . ' bytes: ' . $messageContent);
+               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage(str_replace('_', '-', strtoupper($messageType)) . '-TAG: Handling ' . strlen($messageContent) . ' bytes: ' . $messageContent);
 
                /*
                 * The template system now stores all required data as 'general'
@@ -89,14 +89,14 @@ abstract class BaseCityFilter extends BaseFilter {
                         */
                        if (is_null($value)) {
                                // Output a warning
-                               self::createDebugInstance(__CLASS__)->debugOutput(str_replace('_', '-', strtoupper($messageType)) . '-TAG: Found not fully supported variable ' . $key . ' - skipping.');
+                               self::createDebugInstance(__CLASS__)->debugMessage(str_replace('_', '-', strtoupper($messageType)) . '-TAG: Found not fully supported variable ' . $key . ' - skipping.');
 
                                // Skip this part, don't write NULLs to the array
                                continue;
                        }
 
                        // Debug message
-                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(str_replace('_', '-', strtoupper($messageType)) . '-TAG: key=' . $key . ',value=' . $value);
+                       //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugMessage(str_replace('_', '-', strtoupper($messageType)) . '-TAG: key=' . $key . ',value=' . $value);
 
                        // Set it now
                        $this->dataXmlNodes[$key] = $value;
index 0400ef9e5d575c611f7cb449efa734f298503a0e..988098cf7a073bfbf35e4a90a54a8409db988a6d 100644 (file)
@@ -190,13 +190,13 @@ class CityRegistration extends BaseRegistration implements UserRegister {
                                $criteriaInstance->addCriteria($alias, FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
 
                                // Debug message
-                               //* DEBUG: */ $this->debugOutput('ALIAS: alias='.$alias.',element='.$element.'='.FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
+                               //* DEBUG: */ $this->debugMessage('ALIAS: alias='.$alias.',element='.$element.'='.FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
                        } else {
                                // No, default entry
                                $criteriaInstance->addCriteria($element, FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
 
                                // Debug message
-                               //* DEBUG: */ $this->debugOutput('DEFAULT: element='.$element.'='.FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
+                               //* DEBUG: */ $this->debugMessage('DEFAULT: element='.$element.'='.FrameworkBootstrap::getRequestInstance()->getRequestElement($element));
                        }
 
                        // Is this a guest account?
index 58609c6086516604fa0704335830428e092633cc..9e481b512d1f1177da86f33ebd758afdd322bacd 100644 (file)
@@ -99,6 +99,6 @@ class CityDaemonBuildingGrowthTask extends BaseCityTask implements Taskable, Vis
         * @todo        0% done
         */
        public function doShutdown () {
-               self::createDebugInstance(__CLASS__)->debugOutput('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
+               self::createDebugInstance(__CLASS__)->debugMessage('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
        }
 }
index c7444508a5162b19ef2db5abfbe30760dc3c7426..05c96558a5e893c815f1b2bdf4226280e4e68b38 100644 (file)
@@ -99,6 +99,6 @@ class CityDaemonHouseholdGrowthTask extends BaseCityTask implements Taskable, Vi
         * @todo        0% done
         */
        public function doShutdown () {
-               self::createDebugInstance(__CLASS__)->debugOutput('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
+               self::createDebugInstance(__CLASS__)->debugMessage('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
        }
 }
index e589ee16ced055dcbd4dc6319015ffc0be779533..56b2566cd901ebc47ebc635267c0dd441ee625c4 100644 (file)
@@ -99,6 +99,6 @@ class CityDaemonMapExpanderTask extends BaseCityTask implements Taskable, Visita
         * @todo        0% done
         */
        public function doShutdown () {
-               self::createDebugInstance(__CLASS__)->debugOutput('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
+               self::createDebugInstance(__CLASS__)->debugMessage('TASK[' . __METHOD__ . ':' . __LINE__ . ']: Shutting down...');
        }
 }
index de78c149360ba438dba65d19b6930a70a1c4954e..33272dfd38a4df99381f45dd2d2f93b90991cd1e 100644 (file)
@@ -66,9 +66,9 @@ class ActiveTaskVisitor extends BaseVisitor implements TaskVisitor, DecoratorVis
         */
        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!');
+               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage('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!');
+               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage('ACTIVE-TASK-VISITOR: Visiting task ' . $taskInstance->__toString() . ' - EXIT!');
        }
 
        /**
@@ -82,7 +82,7 @@ class ActiveTaskVisitor extends BaseVisitor implements TaskVisitor, DecoratorVis
                 * 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()));
+               //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->traceMessage(sprintf('ACTIVE-TASK-VISITOR: decoratorInstance=%s - CALLED!', $decoratorInstance->__toString()));
        }
 
 }