Messages translated to english, a lot uneccessary debug messages removed
authorRoland Häder <roland@mxchange.org>
Mon, 21 Apr 2008 11:50:22 +0000 (11:50 +0000)
committerRoland Häder <roland@mxchange.org>
Mon, 21 Apr 2008 11:50:22 +0000 (11:50 +0000)
15 files changed:
application/selector/starter.php
application/ship-simu/starter.php
inc/classes.php
inc/classes/main/class_BaseFrameworkSystem.php
inc/classes/main/commands/local/class_LocalHomeCommand.php
inc/classes/main/compressor/class_Bzip2Compressor.php
inc/classes/main/compressor/class_GzipCompressor.php
inc/classes/main/compressor/class_NullCompressor.php
inc/classes/main/database/class_BaseDatabaseFrontend.php
inc/classes/main/database/classes/class_LocalFileDatabase.php
inc/classes/main/extended/class_SerializationContainer.php
inc/classes/main/template/class_TemplateEngine.php
inc/database.php
inc/language.php
inc/output.php

index 9d0d8acb2d90bbb796548fa3d911dd1b15049495..a4b17b3a2d47855120bbccf5cfc17f25e5c95982 100644 (file)
@@ -28,18 +28,18 @@ $app = ApplicationHelper::getInstance();
 // Some sanity checks
 if ((empty($app)) || (is_null($app))) {
        // Something went wrong!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die Hilfsklasse <strong>%s</strong> nicht geladen ist!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because the helper class <strong>%s</strong> is not loaded.",
                $application,
                FrameworkConfiguration::getInstance()->readConfig("app_helper_class")
        ));
 } elseif (!is_object($app)) {
        // No object!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die &#39;app&#39; kein Objekt ist!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because &#39;app&#39; is not an object.",
                $application
        ));
 } elseif (!method_exists($app, FrameworkConfiguration::getInstance()->readConfig("entry_method"))) {
        // Method not found!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die Methode <strong>%s</strong> fehlt!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because the method <strong>%s</strong> is missing.",
                $application,
                FrameworkConfiguration::getInstance()->readConfig("entry_method")
        ));
@@ -53,7 +53,7 @@ try {
        );
        eval($eval);
 } catch (FrameworkException  $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden. Grund: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched for the follwing reason: <strong>%s</strong>",
                $application,
                $e->getMessage()
        ));
index 458ccf8fdcfaf5fe675b25b55f8342f83c2c2c90..7086fda8b04afea297703b3b0ba3fd49fd396681 100644 (file)
@@ -29,18 +29,18 @@ $app = ApplicationHelper::getInstance();
 // Some sanity checks
 if ((empty($app)) || (is_null($app))) {
        // Something went wrong!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die Hilfsklasse <strong>%s</strong> nicht geladen ist!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because the helper class <strong>%s</strong> is not loaded.",
                $application,
                FrameworkConfiguration::getInstance()->readConfig("app_helper_class")
        ));
 } elseif (!is_object($app)) {
        // No object!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die &#39;app&#39; kein Objekt ist!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because &#39;app&#39; is not an object.",
                $application
        ));
 } elseif (!method_exists($app, FrameworkConfiguration::getInstance()->readConfig("entry_method"))) {
        // Method not found!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden, da die Methode <strong>%s</strong> fehlt!",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched because the method <strong>%s</strong> is missing.",
                $application,
                FrameworkConfiguration::getInstance()->readConfig("entry_method")
        ));
@@ -54,7 +54,7 @@ try {
        );
        eval($eval);
 } catch (FrameworkException  $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Die Applikation <strong>%s</strong> kann nicht gestartet werden. Grund: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <strong>%s</strong> could not be launched for the follwing reason: <strong>%s</strong>",
                $application,
                $e->getMessage()
        ));
index 4b52f3f6c2446d02bcfdda6c1dd3ba4c403ab11f..27034212b2dc4f79f9b2081463d9ee9ff63c236e 100644 (file)
@@ -35,19 +35,19 @@ foreach ($lowerClasses as $class) {
        try {
                ClassLoader::getInstance()->loadClasses(sprintf("inc/classes/%s/", $class));
        } catch (PathIsNoDirectoryException $e) {
-               ApplicationEntryPoint::app_die(sprintf("[Main:] Kann Framework-Klassen im Pfad <strong>%s</strong> nicht laden. Reason: <strong>%s</strong>",
+               ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path <strong>%s</strong> for the follwing reason: <strong>%s</strong>",
                        $class
                ));
        } catch (PathIsEmptyException $e) {
-               ApplicationEntryPoint::app_die(sprintf("[Main:] Kann Framework-Klassen im Pfad <strong>%s</strong> nicht laden. Reason: <strong>%s</strong>",
+               ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path <strong>%s</strong> for the follwing reason: <strong>%s</strong>",
                        $class
                ));
        } catch (PathReadProtectedException $e) {
-               ApplicationEntryPoint::app_die(sprintf("[Main:] Kann Framework-Klassen im Pfad <strong>%s</strong> nicht laden. Reason: <strong>%s</strong>",
+               ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path <strong>%s</strong> for the follwing reason: <strong>%s</strong>",
                        $class
                ));
        } catch (DirPointerNotOpenedException $e) {
-               ApplicationEntryPoint::app_die(sprintf("[Main:] Kann Framework-Klassen im Pfad <strong>%s</strong> nicht laden. Reason: <strong>%s</strong>",
+               ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path <strong>%s</strong> for the follwing reason: <strong>%s</strong>",
                        $class
                ));
        }
index 6cc7a20e038754b6e562b4d4856beab09024c668..9db30498b2b1fb6dd8ded9e163ca2b124fb06069 100644 (file)
@@ -257,7 +257,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                                );
 
                                // Debug message
-                               if ((defined('DEBUG_EVAL')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruierte PHP-Anweisung: <pre><em>%s</em></pre><br />\n",
+                               if (defined('DEBUG_EVAL')) $this->getDebugInstance()->output(sprintf("[%s:] Constructed PHP command: <pre><em>%s</em></pre><br />\n",
                                        $this->__toString(),
                                        htmlentities($eval)
                                ));
@@ -284,11 +284,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                                        $this->setDatabaseInstance($db);
                                }
                        }
-
-                       // Debug output
-                       if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Alle Sub-Systeme sind initialisiert.<br />\n",
-                               $this->__toString()
-                       ));
                }
        }
 
@@ -301,10 +296,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         */
        public final function setConfigInstance (FrameworkConfiguration $configInstance) {
                self::$cfgInstance = $configInstance;
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Konfigurations-Handler auf <strong>%s</strong> gesetzt.<br />\n",
-                       $this->__toString(),
-                       $configInstance->__toString()
-               ));
        }
 
        /**
@@ -313,10 +304,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $cfhInstance - Configuration instance
         */
        public final function getConfigInstance () {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Konfigurations-Handler <strong>%s</strong> angefordert.<br />\n",
-                       $this->__toString(),
-                       self::$cfgInstance->__toString()
-               ));
                return self::$cfgInstance;
        }
 
@@ -328,10 +315,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         */
        public final function setDebugInstance (DebugMiddleware $debugInstance) {
                self::$debug = $debugInstance;
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Debug-Handler auf <strong>%s</strong> gesetzt.<br />\n",
-                       $this->__toString(),
-                       $this->getDebugInstance()->__toString()
-               ));
        }
 
        /**
@@ -351,10 +334,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         */
        public final function setWebOutputInstance (OutputStreamer $webInstance) {
                self::$webOutput = $webInstance;
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Web-Handler auf <strong>%s</strong> gesetzt.<br />\n",
-                       $this->__toString(),
-                       $this->getWebOutputInstance()->__toString()
-               ));
        }
 
        /**
@@ -374,9 +353,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      void
         */
        public final function setDatabaseInstance (DatabaseConnection $dbInstance) {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($dbInstance->getDebugInstance()))) $dbInstance->getDebugInstance()->output(sprintf("[%s:] Datenbankschicht gesetzt.<br />\n",
-                       $dbInstance->__toString()
-               ));
                $this->dbInstance = $dbInstance;
        }
 
@@ -386,9 +362,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $realClass The name of the real class (not BaseFrameworkSystem)
         */
        public final function __toString () {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] __toString() erreicht.<br />\n",
-                       $this->realClass
-               ));
                return $this->realClass;
        }
 
@@ -412,15 +385,8 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      void
         */
        public final function createUniqueID () {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] createUniqueID aufgerufen.<br />\n",
-                       $this->__toString()
-               ));
-
                // Existiert noch keine?
                if (empty($this->uniqueID)) {
-                       if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] createUniqueID erzeugt neue Unique-ID.<br />\n",
-                               $this->__toString()
-                       ));
 
                        // Correct missing class name
                        $corrected = false;
@@ -463,13 +429,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                                        // Abort the loop
                                        break;
                                }
-                       }
-
-                       // Debug message
-                       if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] uniqueID ist auf <strong>%s</strong> gesetzt.<br />\n",
-                               $this->__toString(),
-                               $tempID
-                       ));
+                       } // END - while
 
                        // Apply the new ID
                        $this->setUniqueID($tempID);
@@ -517,12 +477,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                // Cast to string
                $uniqueID = (string) $uniqueID;
 
-               // Debug message
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Unique-ID gesetzt auf <u>%s</u>.<br />\n",
-                       $this->__toString(),
-                       $uniqueID
-               ));
-
                // Set the ID number
                $this->uniqueID = $uniqueID;
        }
@@ -533,9 +487,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $uniqueID               The unique ID of this class
         */
        public final function getUniqueID () {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Unique-ID angefordert.<br />\n",
-                       $this->__toString()
-               ));
                return $this->uniqueID;
        }
 
@@ -547,10 +498,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
        public final function resetUniqueID() {
                // Sweet and simple... ;-)
                $newUniqueID = $this->generateIdNumber();
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Unique-ID zur&uuml;ckgesetzt auf <u>%s</u>.<br />\n",
-                       $this->__toString(),
-                       $newUniqueID
-               ));
                $this->setUniqueID($newUniqueID);
        }
 
@@ -560,9 +507,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $objectDescription      The description of this simulation part
         */
        public final function getObjectDescription () {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] getObjectDescription erreicht.<br />\n",
-                       $this->__toString()
-               ));
                if (isset($this->objectDescription)) {
                        return $this->objectDescription;
                } else {
@@ -578,10 +522,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         */
        public final function setObjectDescription ($objectDescription) {
                $this->objectDescription = (String) $objectDescription;
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Teilbeschreibung wird auf <strong>%s</strong> gesetzt.<br />\n",
-                       $this->__toString(),
-                       $this->objectDescription
-               ));
        }
 
        /**
@@ -618,11 +558,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      boolean The result of comparing both class names
         */
        public final function isClass ($class) {
-               if ((defined('DEBUG_SYSTEM')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] <strong>%s</strong>=<strong>%s</strong>?<br />\n",
-                       $this->__toString(),
-                       $this->__toString(),
-                       $class
-               ));
                return ($this->__toString() == $class);
        }
 
@@ -666,10 +601,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
 
                // Cast the number
                $value = (float) $value;
-               if (defined('DEBUG_CORE') && is_object($this->getDebugInstance())) $this->getDebugInstance()->output(sprintf("[%s:] <strong>%d</strong> wird umformatiert.<br />\n",
-                       $this->__toString(),
-                       $value
-               ));
 
                // Reformat the US number
                $price = sprintf("%s %s",
@@ -687,9 +618,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      void
         */
        public final function removeNumberFormaters () {
-               if (defined('DEBUG_CORE') && is_object($this->getDebugInstance())) $this->getDebugInstance()->output(sprintf("[%s:] Zahlenumformatierungszeichen werden entfernt.<br />\n",
-                       $this->__toString()
-               ));
                unset($this->thousands);
                unset($this->decimals);
        }
@@ -700,10 +628,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $dbInstance     The database layer instance
         */
        public final function getDatabaseInstance () {
-               if (defined('DEBUG_CORE') && is_object($this->getDebugInstance())) $this->getDebugInstance()->output(sprintf("[%s:] Datenbank-Instanz <u>%s</u> angefordert.<br />\n",
-                       $this->__toString(),
-                       $this->dbInstance
-               ));
                return $this->dbInstance;
        }
 
@@ -899,7 +823,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
 
                // Debug message
                if ((!is_null($this->getDebugInstance())) && (defined('DEBUG_EVAL'))) {
-                       $this->getDebugInstance()->output(sprintf("[%s:] Konstruierte PHP-Anweisung: <pre><em>%s</em></pre><br />\n",
+                       $this->getDebugInstance()->output(sprintf("[%s:] Constructed PHP command: <pre><em>%s</em></pre><br />\n",
                                $this->__toString(),
                                htmlentities($eval)
                        ));
index 24ef746cf96f7a79e7d79f4d9ec94b510526cd9b..033e1afc290ec5a738ccb8f6e34e81fd46886bdd 100644 (file)
@@ -90,6 +90,11 @@ class LocalHomeCommand extends BaseCommand implements Commandable {
                // Compile it...
                $templateInstance->compileTemplate();
 
+               // Set title
+               $title = ucfirst($requestInstance->getRequestElement($this->getConfigInstance()->readConfig("command_parameter")));
+               if (empty($title)) $title = "Home";
+               $templateInstance->assignVariable("title", $title);
+
                // ... and all variables. This should be merged together in a pattern
                // to make things easier. A cache mechanism should be added between
                // these two calls to cache compiled templates.
index 272a558c4e364877ac88b0e9281a03dca26b11e5..88322b60c499484237dece225877fdf5fb1eb93e 100644 (file)
@@ -31,11 +31,6 @@ class Bzip2Compressor extends BaseFrameworkSystem implements Compressor {
                // Call parent constructor!
                parent::__construct(__CLASS__);
 
-               // Debug message
-               if (((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) && (defined('DEBUG_CONSTRUCT'))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruktor erreicht.<br />\n",
-                       $this->__toString()
-               ));
-
                // Set description
                $this->setObjectDescription("BZIP2-Kompressor");
 
@@ -53,19 +48,9 @@ class Bzip2Compressor extends BaseFrameworkSystem implements Compressor {
                if ((function_exists('bzcompress')) && (function_exists('bzdecompress'))) {
                        // Compressor can maybe be used
                        $cInstance = new Bzip2Compressor();
-
-                       // Debug message
-                       if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $cInstance->getDebugInstance()->output(sprintf("[%s:] BZIP2-Kompression wird verwendet.<br />\n",
-                               $cInstance->__toString()
-                       ));
                } else {
                        // Routines not found!
                        $cInstance = null;
-
-                       // Debug message
-                       if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $cInstance->getDebugInstance()->output(sprintf("[%s:] BZIP2-Kompressionsroutinen <strong>nicht</strong> gefunden.<br />\n",
-                               $cInstance->__toString()
-                       ));
                }
 
                // Return the compressor instance
@@ -112,9 +97,6 @@ class Bzip2Compressor extends BaseFrameworkSystem implements Compressor {
         * @return      $string Returns always "bz2"
         */
        public final function getCompressorExtension () {
-               if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Dateierweiterung angefordert.<br />\n",
-                       $this->__toString()
-               ));
                return "bz2";
        }
 }
index 208e12bbbfb003dc20cff88cdd00b08047e5acf4..4e95f801f95ef6214b85777c0396e438d6a6e919 100644 (file)
@@ -31,11 +31,6 @@ class GzipCompressor extends BaseFrameworkSystem implements Compressor {
                // Call parent constructor!
                parent::__construct(__CLASS__);
 
-               // Debug message
-               if (((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) && (defined('DEBUG_CONSTRUCT'))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruktor erreicht.<br />\n",
-                       $this->__toString()
-               ));
-
                // Set description
                $this->setObjectDescription("GZIP-Kompressor");
 
@@ -53,19 +48,9 @@ class GzipCompressor extends BaseFrameworkSystem implements Compressor {
                if ((function_exists('gzcompress')) && (function_exists('gzuncompress'))) {
                        // Compressor can maybe be used
                        $cInstance = new GzipCompressor();
-
-                       // Debug message
-                       if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $cInstance->getDebugInstance()->output(sprintf("[%s:] GZIP-Kompression wird verwendet.<br />\n",
-                               $cInstance->__toString()
-                       ));
                } else {
                        // Routines not found!
                        $cInstance = null;
-
-                       // Debug message
-                       if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $cInstance->getDebugInstance()->output(sprintf("[%s:] GZIP-Kompressionsroutinen <strong>nicht</strong> gefunden.<br />\n",
-                               $cInstance->__toString()
-                       ));
                }
 
                // Return the compressor instance
@@ -112,9 +97,6 @@ class GzipCompressor extends BaseFrameworkSystem implements Compressor {
         * @return      $string Returns always "gz"
         */
        public final function getCompressorExtension () {
-               if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Dateierweiterung angefordert.<br />\n",
-                       $this->__toString()
-               ));
                return "gz";
        }
 }
index 74cb5d30d62d1da28bf0ecf4971898ffba30ec46..a8a570c581487ca464c9f05002e2f2576dbe13ee 100644 (file)
@@ -31,11 +31,6 @@ class NullCompressor extends BaseFrameworkSystem implements Compressor {
                // Call parent constructor!
                parent::__construct(__CLASS__);
 
-               // Debug message
-               if (((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) && (defined('DEBUG_CONSTRUCT'))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruktor erreicht.<br />\n",
-                       $this->__toString()
-               ));
-
                // Set description
                $this->setObjectDescription("Null-Kompressor");
 
@@ -96,9 +91,6 @@ class NullCompressor extends BaseFrameworkSystem implements Compressor {
         * @return      $string         Returns always "null"
         */
        public final function getCompressorExtension () {
-               if ((defined('DEBUG_COMPRESSOR')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Dateierweiterung angefordert.<br />\n",
-                       $this->__toString()
-               ));
                return "null";
        }
 }
index 790b424f702e6e7e0fc6f6b3802db88d3657fae0..ac31d501f9205e7a03106db688815c21bd7fd42e 100644 (file)
@@ -37,11 +37,6 @@ abstract class BaseDatabaseFrontend extends BaseFrameworkSystem implements Datab
                // Call parent constructor
                parent::__construct($class);
 
-               // Debug message
-               if (((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) && (defined('DEBUG_CONSTRUCT'))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruktor erreicht.<br />\n",
-                       $this->__toString()
-               ));
-
                // Clean up a little
                $this->removeNumberFormaters();
        }
@@ -52,10 +47,6 @@ abstract class BaseDatabaseFrontend extends BaseFrameworkSystem implements Datab
         * @return      $limitInstance          The instance to the object ObjectLimits
         */
        public final function getLimitInstance () {
-               if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Limitierungsinstanz <strong>%s</strong> angefordert.<br />\n",
-                       $this->__toString(),
-                       $this->limitInstance->__toString()
-               ));
                return $this->limitInstance;
        }
 
@@ -68,12 +59,6 @@ abstract class BaseDatabaseFrontend extends BaseFrameworkSystem implements Datab
         * @return      void
         */
        public final function limitObject (ObjectLimits $limitInstance) {
-               // Debug message
-               if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Limitierungsinstanz <strong>%s</strong> soll verwendet werden.<br />\n",
-                       $this->__toString(),
-                       $limitInstance->__toString()
-               ));
-
                // Get limitArray for validation
                $array = $limitInstance->getLimitArray();
 
@@ -81,13 +66,6 @@ abstract class BaseDatabaseFrontend extends BaseFrameworkSystem implements Datab
                if ($array->count() > 0) {
                        // Okay, there is enougth
                        $this->limitInstance = $limitInstance;
-
-                       // Debug message
-                       if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Limitierungsinstanz <strong>%s</strong> wird verwendet und beinhaltet <strong>%s</strong> Eintr&auml;ge.<br />\n",
-                               $this->__toString(),
-                               $limitInstance->__toString(),
-                               $array->count()
-                       ));
                }
        }
 }
index 7ac2b7db11c7f53d981f5d7eb45bb52aa9a50749..84babfeafd6d6d0fcf8d1a0e1c23da517cbd0203 100644 (file)
@@ -99,11 +99,6 @@ class LocalFileDatabase extends BaseDatabaseFrontend implements DatabaseFrontend
                        throw new SavePathWriteProtectedException($savePath, self::EXCEPTION_WRITE_PROTECED_PATH);
                }
 
-               // Debug output
-               if (defined('DEBUG_DATABASE')) $dbInstance->getDebugInstance()->output(sprintf("[%s:] Es werden lokale Dateien zum Speichern von Objekten verwendet.<br />\n",
-                       $dbInstance->__toString()
-               ));
-
                // Set save path and IO instance
                $dbInstance->setSavePath($savePath);
                $dbInstance->setFileIOInstance($ioInstance);
@@ -122,12 +117,6 @@ class LocalFileDatabase extends BaseDatabaseFrontend implements DatabaseFrontend
                // Secure string
                $savePath = (string) $savePath;
 
-               // Debug message
-               if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Lokaler Speicherpfad <strong>%s</strong> wird verwendet.<br />\n",
-                       $this->__toString(),
-                       $savePath
-               ));
-
                // Set save path
                $this->savePath = $savePath;
        }
@@ -164,24 +153,11 @@ class LocalFileDatabase extends BaseDatabaseFrontend implements DatabaseFrontend
                        throw new MissingMethodException(array($object, '__toString'), self::EXCEPTION_MISSING_METHOD);
                }
 
-               // Debug message
-               if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Das Objekt <strong>%s</strong> soll in eine lokale Datei gespeichert werden.<br />\n",
-                       $this->__toString(),
-                       $object->__toString()
-               ));
-
                // Get a string containing the serialized object. We cannot exchange
                // $this and $object here because $object does not need to worry
                // about it's limitations... ;-)
                $serialized = $this->serializeObject($object);
 
-               // Debug message
-               if ((defined('DEBUG_DATABASE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:] Das Objekt <strong>%s</strong> ist nach der Serialisierung <strong>%s</strong> Byte gross.<br />\n",
-                       $this->__toString(),
-                       $object->__toString(),
-                       strlen($serialized)
-               ));
-
                // Get a path name plus file name and append the extension
                $fqfn = $this->getSavePath() . $object->getPathFileNameFromObject() . "." . $this->getFileExtension();
 
index b07bfc9894fec44c805887d46c4a7f45d876e967..a0980e3d61f93fec58993f7ed775f3cbe1303ba4 100644 (file)
@@ -31,9 +31,6 @@ class SerializationContainer extends FrameworkArrayObject {
        public function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Debug message
-               if ((defined('DEBUG_CONTAINER')) && (defined('DEBUG_CONSTRUCT'))) $this->getDebugInstance()->output("[SerializationContainer:] Konstruktor erreicht.<br />\n");
        }
 
        /**
@@ -64,7 +61,7 @@ class SerializationContainer extends FrameworkArrayObject {
                                );
 
                                // Debug eval command
-                               if ((defined('DEBUG_EVAL')) || (defined('DEBUG_ALL'))) $limitInstance->getDebugInstance()->output(sprintf("[%s:] Konstruierte PHP-Anweisung: <pre><em>%s</em></pre><br />\n",
+                               if (defined('DEBUG_EVAL')) $limitInstance->getDebugInstance()->output(sprintf("[%s:] Constructed PHP command: <pre><em>%s</em></pre><br />\n",
                                        $this->__toString(),
                                        htmlentities($eval)
                                ));
index 6e09d8943f7ed32ee4e0b9259f9c37352a9a46fd..c9e05ab6029ebbb758b3ad20a5e3a963ca005733 100644 (file)
@@ -547,13 +547,6 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
         *                                                              required method
         */
        private function loadRawTemplateData ($fqfn) {
-               // Debug message
-               if ((defined('DEBUG_TEMPLATE')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Template <strong>%s</strong> vom Typ <strong>%s</strong> wird geladen.<br />\n",
-                       $this->__toString(),
-                       $template,
-                       $this->getTemplateType()
-               ));
-
                // Get a input/output instance from the middleware
                $ioInstance = $this->getFileIOInstance();
 
@@ -572,12 +565,6 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
                // Load the raw template
                $rawTemplateData = $ioInstance->loadFileContents($fqfn);
 
-               // Debug message
-               if ((defined('DEBUG_TEMPLATE')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] <strong>%s</strong> Byte Rohdaten geladen.<br />\n",
-                       $this->__toString(),
-                       strlen($rawTemplateData)
-               ));
-
                // Store the template's contents into this class
                $this->setRawTemplateData($rawTemplateData);
 
@@ -1004,7 +991,7 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
                );
 
                // Debug message
-               if (((defined('DEBUG_EVAL')) || (defined('DEBUG_ALL'))) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Konstruierte PHP-Anweisung: <pre><em>%s</em></pre><br />\n",
+               if ((defined('DEBUG_EVAL')) && (is_object($this->getDebugInstance()))) $this->getDebugInstance()->output(sprintf("[%s:] Constructed PHP command: <pre><em>%s</em></pre><br />\n",
                        $this->__toString(),
                        htmlentities($eval)
                ));
index 99611eabc51d88cd913fe97ecd95c70b6dca9fa7..ad29f0e495bf58a3c731bd70e596c30de1701f8d 100644 (file)
@@ -54,34 +54,34 @@ unset($INC);
 try {
        $db = DatabaseConnection::createDatabaseConnection(DebugMiddleware::getInstance(), $layer);
 } catch (NullPointerException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 } catch (InvalidDirectoryResourceException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 } catch (PathIsEmptyException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 } catch (PathIsNoDirectoryException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 } catch (PathReadProtectedException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 } catch (DirPointerNotOpenedException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Datenbank-System nicht initialisiert. Reason: <strong>%s</strong><br />\n",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] Database sub-system not initialized for the follwing reason: <strong>%s</strong><br />\n",
                $e->getMessage()
        ));
 }
 
 // Datenbankobjekt debuggen
 if (defined('DEBUG_DATABASE_OBJ')) {
-       DebugMiddleware::getInstance()->output(sprintf("Die Datenbank-Schicht sieht wie folgt aus:<br />
+       DebugMiddleware::getInstance()->output(sprintf("The database sub-system does now look like this:<br />
 <pre>%s</pre>\n",
                print_r($db, true)
        ));
index 58ea69e89b76c0d91572337b203ec88999504042..552dc45894955c2c4be3bdd27f58e03f0760b070 100644 (file)
@@ -26,19 +26,19 @@ try {
                FrameworkConfiguration::getInstance()->readConfig("lang_base_path")
        ));
 } catch (LanguagePathIsEmptyException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Sprachsystem konnte nicht initialisiert werden. Reason: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The language sub-system could not be initialized for the following reason: <strong>%s</strong>",
                $e->getMessage()
        ));
 } catch (InvalidLanguagePathStringException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Sprachsystem konnte nicht initialisiert werden. Reason: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The language sub-system could not be initialized for the following reason: <strong>%s</strong>",
                $e->getMessage()
        ));
 } catch (LanguagePathIsNoDirectoryException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Sprachsystem konnte nicht initialisiert werden. Reason: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The language sub-system could not be initialized for the following reason: <strong>%s</strong>",
                $e->getMessage()
        ));
 } catch (LanguagePathReadProtectedException $e) {
-       ApplicationEntryPoint::app_die(sprintf("[Main:] Sprachsystem konnte nicht initialisiert werden. Reason: <strong>%s</strong>",
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The language sub-system could not be initialized for the following reason: <strong>%s</strong>",
                $e->getMessage()
        ));
 }
index 72ff36bceed34710c3f53c8b3ed402d3657427ee..20f3fe8f5b7741944e64a20680a6b2f86298bcd4 100644 (file)
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
  */
 
-// Debug-Ausgabe vorbereiten
+// Get a debugger instance
 $debug = DebugMiddleware::createDebugMiddleware(FrameworkConfiguration::getInstance()->readConfig("debug_engine"));
 
-// Leere Strings werden ignoriert und sollten zum Testen der Middleware genommen werden
+// Empty string should be ignored and used for testing the middleware
 DebugMiddleware::getInstance()->output("");
 
 // [EOF]