]> git.mxchange.org Git - shipsimu.git/commitdiff
final added, code clean-ups
authorRoland Häder <roland@mxchange.org>
Mon, 7 Apr 2008 12:26:44 +0000 (12:26 +0000)
committerRoland Häder <roland@mxchange.org>
Mon, 7 Apr 2008 12:26:44 +0000 (12:26 +0000)
17 files changed:
application/selector/class_ApplicationSelector.php
application/ship-simu/main/class_BaseSimulator.php
application/ship-simu/main/constructions/class_BaseConstruction.php
application/ship-simu/main/drives/class_BaseDrive.php
application/ship-simu/main/parts/class_BaseShipPart.php
application/ship-simu/main/structures/class_BaseStructure.php
application/ship-simu/main/structures/extended/cabines/ship/class_EconomyCabin.php
application/ship-simu/main/structures/extended/cabines/ship/class_LowCabin.php
application/ship-simu/main/structures/extended/cabines/ship/class_LuxuryCabin.php
application/ship-simu/main/structures/extended/cabines/ship/class_PremierCabin.php
application/ship-simu/main/structures/extended/class_BaseCabinStructure.php
application/ship-simu/main/structures/extended/class_BaseDeckStructure.php
application/ship-simu/main/structures/extended/decks/cargo/class_CarDeck.php
application/ship-simu/main/structures/extended/decks/cargo/class_TrainDeck.php
application/ship-simu/main/structures/extended/decks/cargo/class_TruckDeck.php
inc/classes/main/template/class_TemplateEngine.php
inc/loader/class_ClassLoader.php

index eb863ba9effeefc972e19f4e9019104b5c58de43..b29414a18b3e0a2d676dcd8560eeae6fb57485a0 100644 (file)
@@ -286,7 +286,7 @@ class ApplicationSelector extends BaseFrameworkSystem {
         *
         * @return      void
         */
-       public function removeDirIgnoreList () {
+       public final function removeDirIgnoreList () {
                unset($this->dirIgnoreList);
        }
 
index 47576da871c9547005432c62d7646b333be40ea4..ec3fe30f342500500b6c8b66f9c16b27451f66a2 100644 (file)
@@ -146,7 +146,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Remover-Methode fuer die Teil-Instanz
-       public function removePartInstance () {
+       public final function removePartInstance () {
                if ($this->getPartInstance() !== null) {
                        // Warnung ausgeben
                        if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] partInstance ist nicht null! Instanz-Attribut wird nicht entfernt.<br />\n",
@@ -177,7 +177,7 @@ class BaseSimulator extends BaseFrameworkSystem {
 
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Maschinenraum mit Motor <strong>%s</strong> wird fuer das Schiff <strong>%s</strong> konstruiert.<br />\n",
                        $this->__toString(),
-                       $this->currPart->getPartDescr(),
+                       $this->getCurrPart()->getPartDescr(),
                        $this->currShip->getShipName()
                ));
 
@@ -186,17 +186,17 @@ class BaseSimulator extends BaseFrameworkSystem {
                        // Berechnungen fuer umliegendes Objekt anpassen
                        if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> vom Typ <strong>%s</strong> passt in das Schiff <strong>%s</strong> hinein.<br />\n",
                                $this->__toString(),
-                               $this->currPart->getPartDescr(),
-                               $this->currPart->__toString(),
+                               $this->getCurrPart()->getPartDescr(),
+                               $this->getCurrPart()->__toString(),
                                $this->currShip->getShipName()
                        ));
 
                        // Muessen die Masse angepasst werden?
                        if ($this->isResizeFactorValid()) {
                                // Neue Angaben berechnen (wir lassen etwas Lust fuer Kabelbaeume, Roehren, Maschinisten, etc.)
-                               $this->newWidth  = (float) $this->currPart->getWidth()  * $this->resizeFactorArray['width'];
-                               $this->newHeight = (float) $this->currPart->getHeight() * $this->resizeFactorArray['height'];
-                               $this->newLength = (float) $this->currPart->getLength() * $this->resizeFactorArray['length'];
+                               $this->newWidth  = (float) $this->getCurrPart()->getWidth()  * $this->resizeFactorArray['width'];
+                               $this->newHeight = (float) $this->getCurrPart()->getHeight() * $this->resizeFactorArray['height'];
+                               $this->newLength = (float) $this->getCurrPart()->getLength() * $this->resizeFactorArray['length'];
 
                                // Passt dies nun immer noch?
                                if ($this->isNewSizeValid()) {
@@ -215,41 +215,41 @@ class BaseSimulator extends BaseFrameworkSystem {
                                } else {
                                        // Passt nicht! Also wieder Exception werfen...
                                        throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> vom Typ <strong>%s</strong> ist zu gross f&uuml;r das Schiff!",
-                                               $this->currPart->__toString(),
-                                               $this->currPart->getPartDescr(),
-                                               $this->currPart->__toString()
+                                               $this->getCurrPart()->__toString(),
+                                               $this->getCurrPart()->getPartDescr(),
+                                               $this->getCurrPart()->__toString()
                                        ), 2);
                                }
                        } elseif ($this->currPart != null) {
                                // Aktuelle Masse setzen
-                               $this->setWidth($this->currPart->getWidth());
-                               $this->setHeight($this->currPart->getHeight());
-                               $this->setLength($this->currPart->getLength());
+                               $this->setWidth($this->getCurrPart()->getWidth());
+                               $this->setHeight($this->getCurrPart()->getHeight());
+                               $this->setLength($this->getCurrPart()->getLength());
                        }
 
                        // Existiert ein Schiffsteil?
                        if (!is_null($this->currPart)) {
                                // Debug-Meldung ausgeben
                                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Schiffsteil <strong>%s</strong> gefunden.<br />\n",
-                                       $this->currPart->realClass,
-                                       $this->currPart->getPartDescr()
+                                       $this->getCurrPart()->realClass,
+                                       $this->getCurrPart()->getPartDescr()
                                ));
 
                                // Schiffsteil-Instanz setzen
                                $this->setPartInstance($this->currPart);
 
                                // Instanzen entfernen
-                               $this->currPart->removeCurrShip();
-                               $this->currPart->removeCurrPart();
-                               $this->currPart->removePartInstance();
-                               $this->currPart->removeResizeFactorArray();
+                               $this->getCurrPart()->removeCurrShip();
+                               $this->getCurrPart()->removeCurrPart();
+                               $this->getCurrPart()->removePartInstance();
+                               $this->getCurrPart()->removeResizeFactorArray();
                        }
                } else {
                        // Exception werfen!
                        throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <u>%s</u> vom Typ <u>%s</u> passt nicht in das Schiff!",
-                               $this->currPart->realClass,
-                               $this->currPart->getPartDescr(),
-                               $this->currPart->__toString()
+                               $this->getCurrPart()->realClass,
+                               $this->getCurrPart()->getPartDescr(),
+                               $this->getCurrPart()->__toString()
                        ), 1);
                }
 
@@ -260,7 +260,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Array fuer Umrechnungstabelle entfernen
-       public function removeResizeFactorArray () {
+       public final function removeResizeFactorArray () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] removeResizeFactor erreicht.<br />\n",
                        $this->__toString()
                ));
@@ -272,7 +272,7 @@ class BaseSimulator extends BaseFrameworkSystem {
         *
         * @return      void
         */
-       public function removeAllNewAttr () {
+       public final function removeAllNewAttr () {
                unset($this->newWidth);
                unset($this->newHeight);
                unset($this->newLength);
@@ -283,7 +283,7 @@ class BaseSimulator extends BaseFrameworkSystem {
         *
         * @return      void
         */
-       public function removeCurrShip () {
+       public final function removeCurrShip () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] removeCurrShip erreicht.<br />\n",
                        $this->__toString()
                ));
@@ -291,7 +291,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Aktuelle Schiffsteil-Instanz entfernen
-       public function removeCurrPart () {
+       public final function removeCurrPart () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] removeCurrPart erreicht.<br />\n",
                        $this->__toString()
                ));
@@ -299,7 +299,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Breite entfernen
-       public function removeWidth () {
+       public final function removeWidth () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Breite entfernt.<br />\n",
                        $this->__toString()
                ));
@@ -307,7 +307,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Hoehe entfernen
-       public function removeHeight () {
+       public final function removeHeight () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] H&ouml;he entfernt.<br />\n",
                        $this->__toString()
                ));
@@ -315,7 +315,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Laenge entfernen
-       public function removeLength () {
+       public final function removeLength () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] L&auml;nge entfernt.<br />\n",
                        $this->__toString()
                ));
@@ -323,7 +323,7 @@ class BaseSimulator extends BaseFrameworkSystem {
        }
 
        // Tiefgang entfernen
-       public function removeDraught () {
+       public final function removeDraught () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Tiefgang entfernt.<br />\n",
                        $this->__toString()
                ));
@@ -363,18 +363,18 @@ class BaseSimulator extends BaseFrameworkSystem {
                return (
                        (
                                ( // Already defined ship messurings
-                                                ($this->currPart->getWidth()  < $this->currShip->getWidth())
-                                       && ($this->currPart->getHeight() < $this->currShip->getDraught())
-                                       && ($this->currPart->getLength() < $this->currShip->getLength())
+                                                ($this->getCurrPart()->getWidth()  < $this->currShip->getWidth())
+                                       && ($this->getCurrPart()->getHeight() < $this->currShip->getDraught())
+                                       && ($this->getCurrPart()->getLength() < $this->currShip->getLength())
                                ) || ( // Ship messurings shall be calculated
                                                 ($this->currShip->getWidth()  == 0)
                                        && ($this->currShip->getHeight() == 0)
                                        && ($this->currShip->getLength() == 0)
                                )
                        // The inserted part must be messured!
-                       ) && ($this->currPart->getWidth()  > 0)
-                               && ($this->currPart->getHeight() > 0)
-                               && ($this->currPart->getLength() > 0)
+                       ) && ($this->getCurrPart()->getWidth()  > 0)
+                               && ($this->getCurrPart()->getHeight() > 0)
+                               && ($this->getCurrPart()->getLength() > 0)
                );
        }
 
@@ -414,6 +414,15 @@ class BaseSimulator extends BaseFrameworkSystem {
                        throw new DimNotFoundInArrayException($this, self::EXCEPTION_DIMENSION_ARRAY_INVALID);
                }
        }
+
+       /**
+        * Getter for current part instance
+        *
+        * @return              $currPart       Instance of the current ship part object
+        */
+       public final function getCurrPart () {
+               return $this->currPart;
+       }
 }
 
 // [EOF]
index 287430201e4a2276ac03676e04100045bda86959..dd36ae6b192afb2b632a994ab569d3490f20f949 100644 (file)
@@ -53,7 +53,7 @@ class BaseConstruction extends BaseSimulator {
        }
 
        // Tiefgang entfernen
-       public function removeDraught () {
+       public final function removeDraught () {
                if (defined('DEBUG_CORE')) $this->getDebugInstance()->output(sprintf("[%s:] Tiefgang wird entfernt.<br />\n",
                        $this->__toString()
                ));
index ce8d9e4c348d24a1c569cf679a8b49872161a03b..a8ed3381a7ed24108c2dade300bd3b1ec54ee567 100644 (file)
@@ -90,7 +90,7 @@ class BaseDrive extends BaseSimulator {
                return $this->price;
        }
 
-       public function removePrice () {
+       public final function removePrice () {
                unset($this->price);
        }
 }
index f2096525ad42c7b603b953e49ad29255234f9800..9bb8b6e038572be8bff951f8e708ff0718787fe1 100644 (file)
@@ -66,7 +66,7 @@ class BaseShipPart extends BaseSimulator {
        }
 
        // Remove price
-       public function removePrice () {
+       public final function removePrice () {
                unset($this->price);
        }
 }
index 733f0c4851d0a9c698e722c75d84549b8699f6f5..5259ca29e3778df4b59ee356544188a6f3b3744e 100644 (file)
@@ -66,7 +66,7 @@ class BaseStructure extends BaseSimulator {
        }
 
        // Remove price
-       public function removePrice () {
+       public final function removePrice () {
                unset($this->price);
        }
 }
index d95cc979cdaa43716ceed87f557281d57188570a..7b41210d7292e2ea92f9d0a69ec8830ccd43cbf8 100644 (file)
@@ -71,36 +71,6 @@ class EconomyCabin extends BaseCabin implements TradeableItem, ConstructableShip
                return $ecoInstance;
        }
 
-       // Loesch-Methode fuer Anzahl Betten
-       public function removeNumBeds() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Betten gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numBeds);
-               parent::removeNumBeds();
-       }
-
-       // Loesch-Methode fuer Anzahl Kabinen
-       public function removeNumCabin() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Kabinen gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numCabin);
-               parent::removeNumCabin();
-       }
-
-       // Loesch-Methode fuer Anzahl Raeume
-       public function removeNumRooms() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl R&auml;ume gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numRooms);
-               parent::removeNumRooms();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index 7767ea38d922075e35cf8806bae072458c8fa3b8..ad0bc84ec9630575588bb82f0919f76ea4f5e390 100644 (file)
@@ -69,36 +69,6 @@ class LowCabin extends BaseCabin implements TradeableItem, ConstructableShipPart
                return $lowInstance;
        }
 
-       // Loesch-Methode fuer Anzahl Betten
-       public function removeNumBeds() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Betten gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numBeds);
-               parent::removeNumBeds();
-       }
-
-       // Loesch-Methode fuer Anzahl Kabinen
-       public function removeNumCabin() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Kabinen gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numCabin);
-               parent::removeNumCabin();
-       }
-
-       // Loesch-Methode fuer Anzahl Raeume
-       public function removeNumRooms() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl R&auml;ume gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numRooms);
-               parent::removeNumRooms();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index 6b1e5805fbf15e0cfcec07bf52520832c0e83633..95333fb61534ee13611955098afb5f568b81927a 100644 (file)
@@ -69,36 +69,6 @@ class LuxuryCabin extends BaseCabin implements TradeableItem, ConstructableShipP
                return $luxuryInstance;
        }
 
-       // Loesch-Methode fuer Anzahl Betten
-       public function removeNumBeds() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Betten gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numBeds);
-               parent::removeNumBeds();
-       }
-
-       // Loesch-Methode fuer Anzahl Kabinen
-       public function removeNumCabin() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Kabinen gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numCabin);
-               parent::removeNumCabin();
-       }
-
-       // Loesch-Methode fuer Anzahl Raeume
-       public function removeNumRooms() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl R&auml;ume gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numRooms);
-               parent::removeNumRooms();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index 3daabdabfd67db9dda3faa84d379b0e5ac6b5ea0..b4e5b74fbbc5030f252b68649e03e2410cb9c6a6 100644 (file)
@@ -66,36 +66,6 @@ class PremierCabin extends BaseCabin implements TradeableItem, ConstructableShip
                return $premierInstance;
        }
 
-       // Loesch-Methode fuer Anzahl Betten
-       public function removeNumBeds() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Betten gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numBeds);
-               parent::removeNumBeds();
-       }
-
-       // Loesch-Methode fuer Anzahl Kabinen
-       public function removeNumCabin() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Kabinen gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numCabin);
-               parent::removeNumCabin();
-       }
-
-       // Loesch-Methode fuer Anzahl Raeume
-       public function removeNumRooms() {
-               if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl R&auml;ume gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               unset($this->numRooms);
-               parent::removeNumRooms();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index e989b25209277f222166609f24b5b8fcee48750c..cf50ce16a54ed5b0fbe6f902229b12ff0ac2e628 100644 (file)
@@ -153,7 +153,7 @@ class BaseCabinStructure extends BaseStructure {
        }
 
        // Loesch-Methode fuer Anzahl Betten
-       public function removeNumBeds() {
+       public final function removeNumBeds() {
                if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Betten gel&ouml;scht.<br />\n",
                        __CLASS__,
                        __LINE__
@@ -162,7 +162,7 @@ class BaseCabinStructure extends BaseStructure {
        }
 
        // Loesch-Methode fuer Anzahl Kabinen
-       public function removeNumCabin() {
+       public final function removeNumCabin() {
                if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Kabinen gel&ouml;scht.<br />\n",
                        __CLASS__,
                        __LINE__
@@ -171,7 +171,7 @@ class BaseCabinStructure extends BaseStructure {
        }
 
        // Loesch-Methode fuer Anzahl Raeume
-       public function removeNumRooms() {
+       public final function removeNumRooms() {
                if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl R&auml;ume gel&ouml;scht.<br />\n",
                        __CLASS__,
                        __LINE__
index 2ba52a5a11f71e4d596dae9eee692e2ca0ec8c05..e9476731a0248a7e88917e7618dd7e82744e4288 100644 (file)
@@ -77,7 +77,7 @@ class BaseDeckStructure extends BaseStructure {
        }
 
        // Deckanzahl entfernen
-       public function removeNumDecks() {
+       public final function removeNumDecks() {
                if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Decks wurde gel&ouml;scht.<br />\n",
                        __CLASS__,
                        __LINE__
index 61aaee0e20173299a2d496fa12222f4b4c959d5d..ca4a9ddbcc7f42f82ad48252fe1660711b1db0ce 100644 (file)
@@ -67,15 +67,6 @@ class CarDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
                return $carInstance;
        }
 
-       // Deckanzahl entfernen
-       public function removeNumDecks() {
-               if ((defined('DEBUG_DECK')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Decks wurde gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               parent::removeNumDecks();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index 06f132a97430db21748b99fa677406553dd105f6..2c9bcbeced6c6a8d7aa6a4d64418a788296a89c7 100644 (file)
@@ -67,15 +67,6 @@ class TrainDeck extends BaseDeck implements TradeableItem, ConstructableShipPart
                return $trainInstance;
        }
 
-       // Deckanzahl entfernen
-       public function removeNumDecks() {
-               if ((defined('DEBUG_DECK')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Decks wurde gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               parent::removeNumDecks();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index ccbe596810d1d741d1ee6896442a180df4b7e91f..4f29d603472fa80cc80026849c9628be9600e390 100644 (file)
@@ -68,15 +68,6 @@ class TruckDeck extends BaseDeck implements TradeableItem, ConstructableShipPart
                return $truckInstance;
        }
 
-       // Deckanzahl entfernen
-       public function removeNumDecks() {
-               if ((defined('DEBUG_DECK')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Anzahl Decks wurde gel&ouml;scht.<br />\n",
-                       __CLASS__,
-                       __LINE__
-               ));
-               parent::removeNumDecks();
-       }
-
        // Overwritten method for tradeable items
        public function isTradeable () {
                return true;
index cc95918414a88b9b15e07deb361ed27896169054..1dfb7ad29b64e22b09bfec2f0dc0d4bcd0478b1f 100644 (file)
@@ -136,16 +136,16 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
        /**
         * Creates an instance of the class TemplateEngine and prepares it for usage
         *
-        * @param               $basePath               The local base path for all templates
-        * @param               $langInstance   An instance of LanguageSystem (default)
-        * @param               $ioInstance     An instance of FileIOHandler (default, middleware!)
+        * @param       $basePath               The local base path for all templates
+        * @param       $langInstance   An instance of LanguageSystem (default)
+        * @param       $ioInstance             An instance of FileIOHandler (default, middleware!)
         * @return      $tplInstance    An instance of TemplateEngine
         * @throws      BasePathIsEmptyException                If the provided $basePath is empty
         * @throws      InvalidBasePathStringException  If $basePath is no string
         * @throws      BasePathIsNoDirectoryException  If $basePath is no
-        *                                                                              directory or not found
+        *                                                                                      directory or not found
         * @throws      BasePathReadProtectedException  If $basePath is
-        *                                                                              read-protected
+        *                                                                                      read-protected
         */
        public final static function createTemplateEngine ($basePath, ManageableLanguage  $langInstance, FileIOHandler $ioInstance) {
                // Get a new instance
@@ -580,11 +580,11 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
        /**
         * Extract variables from a given raw data stream
         *
-        * @param               $rawData                The raw template data we shall analyze
+        * @param       $rawData        The raw template data we shall analyze
         * @return      void
         * @throws      InvalidTemplateVariableNameException    If a variable name
-        *                                                                                      in a template is
-        *                                                                                      invalid
+        *                                                                                                      in a template is
+        *                                                                                                      invalid
         */
        private function extractVariablesFromRawData ($rawData) {
                // Cast to string
@@ -776,6 +776,7 @@ class TemplateEngine extends BaseFrameworkSystem implements CompileableTemplate
                                $this->assignVariable($var, $varMatches[3][$key]);
                        } else {
                                // Non-string found so we need some deeper analysis...
+                               // @TODO Unfinished work or don't die here.
                                die("Deeper analysis not yet implemented!");
                        }
 
index 61e8c216ffe532bb1875c22423acadb39135cb48..79389f647d41688511137437c1472586e8c40455 100644 (file)
@@ -274,15 +274,17 @@ class ClassLoader {
 
                // Set new prefix (temporary!)
                $this->prefix = "config-";
+               $this->preLen = strlen($this->prefix);
 
                // Set base directory
-               $basePath = sprintf("%s/inc/config/", PATH);
+               $basePath = sprintf("%sinc/config/", PATH);
 
                // Load all classes from the config directory
                $this->loadClasses($basePath);
 
                // Set the prefix back
                $this->prefix = $oldPrefix;
+               $this->preLen = strlen($this->prefix);
        }
 }