From 86553167136d11d44e1d938e964134c038785e3e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sat, 21 Jun 2008 14:39:45 +0000 Subject: [PATCH] Type-hints fixed, header docs fixed, exceptions deprecated --- application/selector/loader.php | 1 - .../class_ContractAllreadySignedException.php | 3 --- .../class_EmptyStructuresListException.php | 2 +- .../class_InvalidContractPartnerException.php | 2 +- .../class_InvalidIDFormatException.php | 2 +- .../class_ItemNotInPriceListException.php | 2 +- .../class_NoShipyardsConstructedException.php | 2 +- ...s_PersonellListAlreadyCreatedException.php | 2 +- ...class_TotalPriceNotCalculatedException.php | 2 +- application/ship-simu/loader.php | 6 ++--- .../ship-simu/main/class_BasePersonell.php | 4 ++-- .../ship-simu/main/class_BaseSimulator.php | 4 ++-- .../constructions/class_BaseConstruction.php | 4 ++-- .../ship-simu/main/drives/class_BaseDrive.php | 4 ++-- .../main/parts/class_BaseShipPart.php | 4 ++-- .../ship-simu/main/ships/class_BaseShip.php | 11 ++------- .../main/structures/class_BaseStructure.php | 4 ++-- .../extended/cabines/class_BaseCabin.php | 4 ++-- .../extended/class_BaseCabinStructure.php | 4 ++-- .../extended/class_BaseDeckStructure.php | 4 ++-- .../extended/class_BaseUpperStructure.php | 4 ++-- .../extended/decks/class_BaseDeck.php | 4 ++-- inc/classes.php | 14 +++++------ .../class_ContainerItemIsNoArrayException.php | 9 +++---- .../class_ContainerItemIsNullException.php | 9 +++---- .../class_ContainerMaybeDamagedException.php | 9 +++---- .../class_SavePathIsEmptyException.php | 8 +++---- .../helper/class_FormOpenedException.php | 10 ++++---- .../helper/class_InvalidFormNameException.php | 8 +++---- ...lass_InvalidDirectoryResourceException.php | 18 ++++++-------- .../io/class_PathIsEmptyException.php | 18 ++++++-------- ...ass_InvalidLanguagePathStringException.php | 12 +++++----- .../class_LanguagePathIsEmptyException.php | 8 +++---- ...ass_LanguagePathIsNoDirectoryException.php | 10 ++++---- ...ass_LanguagePathReadProtectedException.php | 12 +++++----- .../class_MissingFileIoHandlerException.php | 6 ++--- .../class_MissingLanguageHandlerException.php | 6 ++--- .../main/class_ClassMismatchException.php | 6 ++--- .../class_ConfigEntryIsEmptyException.php | 4 ++-- .../class_ConfigEntryNotFoundException.php | 5 +--- .../class_DimNotFoundInArrayException.php | 8 +++---- .../main/class_ExceptionNotFoundException.php | 9 +++---- .../main/class_InvalidObjectException.php | 8 +++---- .../class_MissingArrayElementsException.php | 9 +++---- .../main/class_MissingMethodException.php | 10 ++++---- .../main/class_NullPointerException.php | 8 +++---- ...ss_ResponseHeadersAlreadySentException.php | 6 ++--- .../class_BasePathIsEmptyException.php | 8 +++---- .../class_BasePathIsNoDirectoryException.php | 10 ++++---- .../class_BasePathReadProtectedException.php | 10 ++++---- .../class_InvalidBasePathStringException.php | 12 +++++----- ...ass_UnsupportedTemplateEngineException.php | 8 +++---- .../main/class_BaseFrameworkSystem.php | 24 ++++++++++--------- .../main/commands/class_BaseCommand.php | 5 ++-- .../main/controller/class_BaseController.php | 5 ++-- .../database/class_BaseDatabaseFrontend.php | 5 ++-- .../main/factories/class_BaseFactory.php | 6 ++--- .../action/class_BaseActionResolver.php | 1 + .../command/class_BaseCommandResolver.php | 1 + inc/classes/main/user/class_Guest.php | 7 +++--- inc/classes/main/user/class_User.php | 7 +++--- .../middleware/class_BaseMiddleware.php | 5 ++-- .../compressor/class_CompressorChannel.php | 4 ++-- 63 files changed, 205 insertions(+), 222 deletions(-) diff --git a/application/selector/loader.php b/application/selector/loader.php index f11a33a..bb5c293 100644 --- a/application/selector/loader.php +++ b/application/selector/loader.php @@ -29,7 +29,6 @@ ClassLoader::getInstance()->loadClasses(sprintf("%s/%s/", $cfg->readConfig('appl // Clean up the global namespace unset($lowerClasses); -unset($class); // [EOF] ?> diff --git a/application/ship-simu/exceptions/class_ContractAllreadySignedException.php b/application/ship-simu/exceptions/class_ContractAllreadySignedException.php index 76890e9..7919222 100644 --- a/application/ship-simu/exceptions/class_ContractAllreadySignedException.php +++ b/application/ship-simu/exceptions/class_ContractAllreadySignedException.php @@ -23,9 +23,6 @@ */ class ContractAllreadySignedException extends FrameworkException { public function __construct (array $classArray, $code) { - // Cast the array - $classArray = (array) $classArray; - // Add a message around the missing class $message = sprintf("[%s:] Die Vertragsparteien %s und %s haben den Vertrag bereits unterzeichnet!", $classArray[0]->__toString(), diff --git a/application/ship-simu/exceptions/class_EmptyStructuresListException.php b/application/ship-simu/exceptions/class_EmptyStructuresListException.php index 14d0051..31284fc 100644 --- a/application/ship-simu/exceptions/class_EmptyStructuresListException.php +++ b/application/ship-simu/exceptions/class_EmptyStructuresListException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class EmptyStructuresListException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:] Die Strukturen-Liste ist leer.", $class->__toString() diff --git a/application/ship-simu/exceptions/class_InvalidContractPartnerException.php b/application/ship-simu/exceptions/class_InvalidContractPartnerException.php index af8f472..db363ae 100644 --- a/application/ship-simu/exceptions/class_InvalidContractPartnerException.php +++ b/application/ship-simu/exceptions/class_InvalidContractPartnerException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class InvalidContractPartnerException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:] %s ist kein gütiger Vertragspartner.", $class->__toString(), diff --git a/application/ship-simu/exceptions/class_InvalidIDFormatException.php b/application/ship-simu/exceptions/class_InvalidIDFormatException.php index 2187d24..d3103d7 100644 --- a/application/ship-simu/exceptions/class_InvalidIDFormatException.php +++ b/application/ship-simu/exceptions/class_InvalidIDFormatException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class InvalidIDFormatException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:] Ungültige ID-Nummer übergeben.", $class->__toString() diff --git a/application/ship-simu/exceptions/class_ItemNotInPriceListException.php b/application/ship-simu/exceptions/class_ItemNotInPriceListException.php index ecadfa7..2785fa5 100644 --- a/application/ship-simu/exceptions/class_ItemNotInPriceListException.php +++ b/application/ship-simu/exceptions/class_ItemNotInPriceListException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class ItemNotInPriceListException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[Merchant:] Preis für den Artikel %s %s nicht gefunden.", $class->__toString(), diff --git a/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php b/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php index 4ef7d2e..410f04c 100644 --- a/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php +++ b/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class NoShipyardsConstructedException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { if (is_object($class)) { // Add a message around the missing class $message = sprintf("[%s:] Keine Werften gefunden!", diff --git a/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php b/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php index 88ae2a1..d625336 100644 --- a/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php +++ b/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class PersonellListAlreadyCreatedException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:] Die interne Crew-Liste wurde bereits initialisiert.", $class->__toString() diff --git a/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php b/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php index 2d1b313..3bc3a80 100644 --- a/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php +++ b/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php @@ -22,7 +22,7 @@ * along with this program. If not, see . */ class TotalPriceNotCalculatedException extends FrameworkException { - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:] Gesamtpreis ist nicht ermittelbar.", $class->__toString() diff --git a/application/ship-simu/loader.php b/application/ship-simu/loader.php index e18c749..b608720 100644 --- a/application/ship-simu/loader.php +++ b/application/ship-simu/loader.php @@ -26,14 +26,14 @@ $cfg = FrameworkConfiguration::getInstance(); // Load all classes for the application -foreach ($lowerClasses as $class) { +foreach ($lowerClasses as $className) { // Load the application classes - ClassLoader::getInstance()->loadClasses(sprintf("%s/%s/%s", $cfg->readConfig('application_path'), $cfg->readConfig('app_name'), $class)); + ClassLoader::getInstance()->loadClasses(sprintf("%s/%s/%s", $cfg->readConfig('application_path'), $cfg->readConfig('app_name'), $className)); } // END - if // Clean up the global namespace unset($lowerClasses); -unset($class); +unset($className); // [EOF] ?> diff --git a/application/ship-simu/main/class_BasePersonell.php b/application/ship-simu/main/class_BasePersonell.php index 888061c..65df945 100644 --- a/application/ship-simu/main/class_BasePersonell.php +++ b/application/ship-simu/main/class_BasePersonell.php @@ -48,9 +48,9 @@ class BasePersonell extends BaseFrameworkSystem implements Personellizer { private $salary = 0.00; // Constructor - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Personal"); diff --git a/application/ship-simu/main/class_BaseSimulator.php b/application/ship-simu/main/class_BaseSimulator.php index c31a8d0..ffdbc66 100644 --- a/application/ship-simu/main/class_BaseSimulator.php +++ b/application/ship-simu/main/class_BaseSimulator.php @@ -42,9 +42,9 @@ class BaseSimulator extends BaseFrameworkSystem { ); // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Call highest constructor - parent::__construct($class); + parent::__construct($className); // Set part description and class name $this->setObjectDescription("Simulator-Basis-Einheit"); diff --git a/application/ship-simu/main/constructions/class_BaseConstruction.php b/application/ship-simu/main/constructions/class_BaseConstruction.php index 3a82a8d..44b1286 100644 --- a/application/ship-simu/main/constructions/class_BaseConstruction.php +++ b/application/ship-simu/main/constructions/class_BaseConstruction.php @@ -26,9 +26,9 @@ class BaseConstruction extends BaseSimulator { private $draught = 0; // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Eltern-Konstrutor aufrufen - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Namenlose Landkonstruktion"); diff --git a/application/ship-simu/main/drives/class_BaseDrive.php b/application/ship-simu/main/drives/class_BaseDrive.php index dfb0bbf..4891d73 100644 --- a/application/ship-simu/main/drives/class_BaseDrive.php +++ b/application/ship-simu/main/drives/class_BaseDrive.php @@ -30,9 +30,9 @@ class BaseDrive extends BaseSimulator { private $numCams = 0; // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Namenloser Antrieb"); diff --git a/application/ship-simu/main/parts/class_BaseShipPart.php b/application/ship-simu/main/parts/class_BaseShipPart.php index 07ecd92..014b4cb 100644 --- a/application/ship-simu/main/parts/class_BaseShipPart.php +++ b/application/ship-simu/main/parts/class_BaseShipPart.php @@ -26,9 +26,9 @@ class BaseShipPart extends BaseSimulator { private $price = 0.00; // Konstruktor - protected function __construct($class) { + protected function __construct($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Beschreibung $this->setObjectDescription("Schiffsteil"); diff --git a/application/ship-simu/main/ships/class_BaseShip.php b/application/ship-simu/main/ships/class_BaseShip.php index c047627..18d2eb8 100644 --- a/application/ship-simu/main/ships/class_BaseShip.php +++ b/application/ship-simu/main/ships/class_BaseShip.php @@ -38,9 +38,9 @@ class BaseShip extends BaseSimulator { private $structures = null; // Namenloses Ship generieren - protected function __construct($class) { + protected function __construct($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set object description $this->setObjectDescription("Allgemeines Schiff"); @@ -122,13 +122,6 @@ class BaseShip extends BaseSimulator { $e->getMessage() )); return false; - } catch (ExceptionNotFoundException $e) { - if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Eine Exception wurde nicht gefunden. Details: %s
\n", - __CLASS__, - __LINE__, - $e->getMessage() - )); - return false; } // Instanz im Aufbauten-Array vermerken diff --git a/application/ship-simu/main/structures/class_BaseStructure.php b/application/ship-simu/main/structures/class_BaseStructure.php index 6b157d9..acac198 100644 --- a/application/ship-simu/main/structures/class_BaseStructure.php +++ b/application/ship-simu/main/structures/class_BaseStructure.php @@ -26,9 +26,9 @@ class BaseStructure extends BaseSimulator { private $price = 0.00; // Konstruktor (hier keine Exceptions aendern!) - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Schiffsstrukturen"); diff --git a/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php b/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php index f12b984..83e5bc5 100644 --- a/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php +++ b/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php @@ -23,9 +23,9 @@ */ class BaseCabin extends BaseCabinStructure { // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Kabine"); diff --git a/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php b/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php index cda085b..918f66e 100644 --- a/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php +++ b/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php @@ -33,9 +33,9 @@ class BaseCabinStructure extends BaseStructure { private $numBeds = 0; // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Kabinenstruktur"); diff --git a/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php b/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php index 05cba44..60ec1c7 100644 --- a/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php +++ b/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php @@ -26,9 +26,9 @@ class BaseDeckStructure extends BaseStructure { private $numDecks = 0; // Konstruktor - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Deckstruktur"); diff --git a/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php b/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php index 2a6eef8..8fed2e4 100644 --- a/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php +++ b/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php @@ -25,9 +25,9 @@ class BaseUpperStructure extends BaseStructure { /** * Constructor for all super structures on a ship */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Aufbauten"); diff --git a/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php b/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php index 7d564cc..69cc91c 100644 --- a/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php +++ b/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php @@ -25,9 +25,9 @@ class BaseDeck extends BaseDeckStructure { /** * Constructor for cargo decks in general */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set description $this->setObjectDescription("Allgemeines Deck"); diff --git a/inc/classes.php b/inc/classes.php index 1c52372..c37f405 100644 --- a/inc/classes.php +++ b/inc/classes.php @@ -30,32 +30,32 @@ $lowerClasses = array( ); // Load all classes -foreach ($lowerClasses as $class) { +foreach ($lowerClasses as $className) { // Try to load the framework classes try { - ClassLoader::getInstance()->loadClasses(sprintf("inc/classes/%s/", $class)); + ClassLoader::getInstance()->loadClasses(sprintf("inc/classes/%s/", $className)); } catch (PathIsNoDirectoryException $e) { ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path %s for the follwing reason: %s", - $class + $className )); } catch (PathIsEmptyException $e) { ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path %s for the follwing reason: %s", - $class + $className )); } catch (PathReadProtectedException $e) { ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path %s for the follwing reason: %s", - $class + $className )); } catch (DirPointerNotOpenedException $e) { ApplicationEntryPoint::app_die(sprintf("[Main:] Could not load framework classes from path %s for the follwing reason: %s", - $class + $className )); } } // Clean up the global namespace unset($lowerClasses[3]); // Applications shall not have any middleware -unset($class); +unset($className); ////// Until here the framework classes are loaded ////// diff --git a/inc/classes/exceptions/container/class_ContainerItemIsNoArrayException.php b/inc/classes/exceptions/container/class_ContainerItemIsNoArrayException.php index 0622052..6eb0f05 100644 --- a/inc/classes/exceptions/container/class_ContainerItemIsNoArrayException.php +++ b/inc/classes/exceptions/container/class_ContainerItemIsNoArrayException.php @@ -7,6 +7,7 @@ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org + * @deprecated * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,13 +26,13 @@ class ContainerItemIsNoArrayException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Ein Container-Item ist kein Array.", + $message = sprintf("[%s:%d] A container item is not an array.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/container/class_ContainerItemIsNullException.php b/inc/classes/exceptions/container/class_ContainerItemIsNullException.php index 05334ed..9780abe 100644 --- a/inc/classes/exceptions/container/class_ContainerItemIsNullException.php +++ b/inc/classes/exceptions/container/class_ContainerItemIsNullException.php @@ -7,6 +7,7 @@ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org + * @deprecated * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,13 +26,13 @@ class ContainerItemIsNullException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Ein Container-Item ist auf null gesetzt.", + $message = sprintf("[%s:%d] A container item is null.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/container/class_ContainerMaybeDamagedException.php b/inc/classes/exceptions/container/class_ContainerMaybeDamagedException.php index 33232c0..ec4539b 100644 --- a/inc/classes/exceptions/container/class_ContainerMaybeDamagedException.php +++ b/inc/classes/exceptions/container/class_ContainerMaybeDamagedException.php @@ -7,6 +7,7 @@ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org + * @deprecated * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,13 +26,13 @@ class ContainerMaybeDamagedException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Ein Container ist möglicherweise beschädigt.", + $message = sprintf("[%s:%d] A container is possibly damaged.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/database/local_file/class_SavePathIsEmptyException.php b/inc/classes/exceptions/database/local_file/class_SavePathIsEmptyException.php index d9de2ee..56c7ff8 100644 --- a/inc/classes/exceptions/database/local_file/class_SavePathIsEmptyException.php +++ b/inc/classes/exceptions/database/local_file/class_SavePathIsEmptyException.php @@ -25,13 +25,13 @@ class SavePathIsEmptyException extends DatabaseException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Der Speicherpfad ist leer.", + $message = sprintf("[%s:%d] Save path is empty.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/helper/class_FormOpenedException.php b/inc/classes/exceptions/helper/class_FormOpenedException.php index c2aafbd..48662ae 100644 --- a/inc/classes/exceptions/helper/class_FormOpenedException.php +++ b/inc/classes/exceptions/helper/class_FormOpenedException.php @@ -26,16 +26,16 @@ class FormOpenedException extends FrameworkException { /** * The constructor * - * @param $class Class throwing the exception - * @param $code Code number for the exception + * @param $helperInstance Class throwing the exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (BaseHelper $helperInstance, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Form is not yet closed. Close it with method %s::addFormTag() and add no parameters.", - $class->__toString(), + $helperInstance->__toString(), $this->getLine(), - $class->__toString() + $helperInstance->__toString() ); // Call parent constructor diff --git a/inc/classes/exceptions/helper/class_InvalidFormNameException.php b/inc/classes/exceptions/helper/class_InvalidFormNameException.php index 00c36a2..f6bab92 100644 --- a/inc/classes/exceptions/helper/class_InvalidFormNameException.php +++ b/inc/classes/exceptions/helper/class_InvalidFormNameException.php @@ -25,14 +25,14 @@ class InvalidFormNameException extends FrameworkException { /** * The constructor * - * @param $class Class throwing the exception - * @param $code Code number for the exception + * @param $helperInstance Class throwing the exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (BaseHelper $helperInstance, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Form name not set.", - $class->__toString(), + $helperInstance->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/io/class_InvalidDirectoryResourceException.php b/inc/classes/exceptions/io/class_InvalidDirectoryResourceException.php index 2dbe65c..d5f40f2 100644 --- a/inc/classes/exceptions/io/class_InvalidDirectoryResourceException.php +++ b/inc/classes/exceptions/io/class_InvalidDirectoryResourceException.php @@ -25,20 +25,16 @@ class InvalidDirectoryResourceException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - if (is_null($class)) { - $message = "[???:] Ungütige Verzeichnis-Resource."; - } elseif (is_object($class)) { - $message = sprintf("[%s:%d] Ungütige Verzeichnis-Resource.", - $class->__toString(), - $this->getLine() - ); - } + $message = sprintf("[%s:%d] Has an invalid directory resource.", + $class->__toString(), + $this->getLine() + ); // Call parent constructor parent::__construct($message, $code); diff --git a/inc/classes/exceptions/io/class_PathIsEmptyException.php b/inc/classes/exceptions/io/class_PathIsEmptyException.php index b8a2868..77e402e 100644 --- a/inc/classes/exceptions/io/class_PathIsEmptyException.php +++ b/inc/classes/exceptions/io/class_PathIsEmptyException.php @@ -25,20 +25,16 @@ class PathIsEmptyException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - if (is_null($class)) { - $message = "[???:] Der Verzeichnisname ist leer."; - } elseif (is_object($class)) { - $message = sprintf("[%s:%d] Der Verzeichnisname ist leer.", - $class->__toString(), - $this->getLine() - ); - } + $message = sprintf("[%s:%d] Directory path is empty.", + $class->__toString(), + $this->getLine() + ); // Call parent constructor parent::__construct($message, $code); diff --git a/inc/classes/exceptions/language/class_InvalidLanguagePathStringException.php b/inc/classes/exceptions/language/class_InvalidLanguagePathStringException.php index 3775bc4..c49fb28 100644 --- a/inc/classes/exceptions/language/class_InvalidLanguagePathStringException.php +++ b/inc/classes/exceptions/language/class_InvalidLanguagePathStringException.php @@ -25,16 +25,16 @@ class InvalidLanguagePathStringException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array holding exception data + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] %s ist keine Zeichenkette!", - $class[0]->__toString(), + $message = sprintf("[%s:%d] %s is not a string with path!", + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/language/class_LanguagePathIsEmptyException.php b/inc/classes/exceptions/language/class_LanguagePathIsEmptyException.php index cd38561..89695ae 100644 --- a/inc/classes/exceptions/language/class_LanguagePathIsEmptyException.php +++ b/inc/classes/exceptions/language/class_LanguagePathIsEmptyException.php @@ -25,13 +25,13 @@ class LanguagePathIsEmptyException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Der Sprachen-Basispfad ist leer.", + $message = sprintf("[%s:%d] Language base path is empty.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/language/class_LanguagePathIsNoDirectoryException.php b/inc/classes/exceptions/language/class_LanguagePathIsNoDirectoryException.php index f735d59..2e94516 100644 --- a/inc/classes/exceptions/language/class_LanguagePathIsNoDirectoryException.php +++ b/inc/classes/exceptions/language/class_LanguagePathIsNoDirectoryException.php @@ -25,16 +25,16 @@ class LanguagePathIsNoDirectoryException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array holding exception data + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Der Sprach-Basispfad %s existiert nicht oder ist eine Datei!", - $class[0]->__toString(), + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/language/class_LanguagePathReadProtectedException.php b/inc/classes/exceptions/language/class_LanguagePathReadProtectedException.php index b67c797..743409a 100644 --- a/inc/classes/exceptions/language/class_LanguagePathReadProtectedException.php +++ b/inc/classes/exceptions/language/class_LanguagePathReadProtectedException.php @@ -25,16 +25,16 @@ class LanguagePathReadProtectedException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Array holding exception data + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Der Sprach-Basispfad %s ist lesegeschützt! Bitte Zugriffsrechte (CHMOD) ändern.", - $class[0]->__toString(), + $message = sprintf("[%s:%d] Base language path %s is read-protected. Please change access rights (CHMOD).", + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/language/class_MissingFileIoHandlerException.php b/inc/classes/exceptions/language/class_MissingFileIoHandlerException.php index ea92f6d..ad3b50a 100644 --- a/inc/classes/exceptions/language/class_MissingFileIoHandlerException.php +++ b/inc/classes/exceptions/language/class_MissingFileIoHandlerException.php @@ -25,11 +25,11 @@ class MissingFileIoHandlerException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] File i/o sub-system not initialized!", $class->__toString(), diff --git a/inc/classes/exceptions/language/class_MissingLanguageHandlerException.php b/inc/classes/exceptions/language/class_MissingLanguageHandlerException.php index 9511e21..a909a50 100644 --- a/inc/classes/exceptions/language/class_MissingLanguageHandlerException.php +++ b/inc/classes/exceptions/language/class_MissingLanguageHandlerException.php @@ -25,11 +25,11 @@ class MissingLanguageHandlerException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Language sub-system not initialized!", $class->__toString(), diff --git a/inc/classes/exceptions/main/class_ClassMismatchException.php b/inc/classes/exceptions/main/class_ClassMismatchException.php index a2f009b..9ea58f7 100644 --- a/inc/classes/exceptions/main/class_ClassMismatchException.php +++ b/inc/classes/exceptions/main/class_ClassMismatchException.php @@ -25,13 +25,13 @@ class ClassMismatchException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array holding the exception informations + * @param $code Code number for the exception * @return void */ public function __construct (array $classArray, $code) { // Add a message around the missing class - $message = sprintf("Die Klasse %s ist ungleich %s.", + $message = sprintf("The class %s does not match class %s.", $classArray[0], $classArray[1] ); diff --git a/inc/classes/exceptions/main/class_ConfigEntryIsEmptyException.php b/inc/classes/exceptions/main/class_ConfigEntryIsEmptyException.php index f441ef4..d0ce8d9 100644 --- a/inc/classes/exceptions/main/class_ConfigEntryIsEmptyException.php +++ b/inc/classes/exceptions/main/class_ConfigEntryIsEmptyException.php @@ -25,8 +25,8 @@ class ConfigEntryIsEmptyException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ public function __construct (FrameworkConfiguration $class, $code) { diff --git a/inc/classes/exceptions/main/class_ConfigEntryNotFoundException.php b/inc/classes/exceptions/main/class_ConfigEntryNotFoundException.php index 88a3461..324e991 100644 --- a/inc/classes/exceptions/main/class_ConfigEntryNotFoundException.php +++ b/inc/classes/exceptions/main/class_ConfigEntryNotFoundException.php @@ -25,14 +25,11 @@ class ConfigEntryNotFoundException extends FrameworkException { /** * The constructor * - * @param $classArray Array with class + * @param $classArray Array with exception data * @param $code Code number for the exception * @return void */ public function __construct (array $classArray, $code) { - // Cast the array - $classArray = (array) $classArray; - // Add a message around the missing class $message = sprintf("[%s:%d] Configuration entry %s not found.", $classArray[0], diff --git a/inc/classes/exceptions/main/class_DimNotFoundInArrayException.php b/inc/classes/exceptions/main/class_DimNotFoundInArrayException.php index 7205bfc..74bd7c2 100644 --- a/inc/classes/exceptions/main/class_DimNotFoundInArrayException.php +++ b/inc/classes/exceptions/main/class_DimNotFoundInArrayException.php @@ -25,14 +25,14 @@ class DimNotFoundInArrayException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing the exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { if (is_object($class)) { // Add a message around the missing class - $message = sprintf("[%s:%d] Abmasse konnten nicht extrahiert werden!", + $message = sprintf("[%s:%d] Dimensions not found in array, array is invalid!", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/main/class_ExceptionNotFoundException.php b/inc/classes/exceptions/main/class_ExceptionNotFoundException.php index a523700..524cfea 100644 --- a/inc/classes/exceptions/main/class_ExceptionNotFoundException.php +++ b/inc/classes/exceptions/main/class_ExceptionNotFoundException.php @@ -25,16 +25,13 @@ class ExceptionNotFoundException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array with exception data + * @param $code Code number for the exception * @return void */ public function __construct (array $classArray, $code) { - // Cast the array - $classArray = (array) $classArray; - // Add a message around the missing class - $message = sprintf("[%s:%d] Exception %s nicht gefunden.", + $message = sprintf("[%s:%d] Exception %s not found.", $classArray[0], $this->getLine(), $classArray[1] diff --git a/inc/classes/exceptions/main/class_InvalidObjectException.php b/inc/classes/exceptions/main/class_InvalidObjectException.php index 9d643a0..094302c 100644 --- a/inc/classes/exceptions/main/class_InvalidObjectException.php +++ b/inc/classes/exceptions/main/class_InvalidObjectException.php @@ -25,13 +25,13 @@ class InvalidObjectException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing the exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Objekte sind nicht erlaubt. (Objekt: %s)", + $message = sprintf("[%s:%d] Objects are not allowed here. (Object: %s)", $class->__toString(), $this->getLine(), $class->getObjectDescription() diff --git a/inc/classes/exceptions/main/class_MissingArrayElementsException.php b/inc/classes/exceptions/main/class_MissingArrayElementsException.php index 1c93060..6868bd8 100644 --- a/inc/classes/exceptions/main/class_MissingArrayElementsException.php +++ b/inc/classes/exceptions/main/class_MissingArrayElementsException.php @@ -25,14 +25,11 @@ class MissingArrayElementsException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array with exception data + * @param $code Code number for the exception * @return void */ public function __construct (array $classArray, $code) { - // Cast the array - $classArray = (array) $classArray; - // Extract all elements $elements = ""; if ((isset($classArray[2])) && (is_array($classArray[2]))) { @@ -44,7 +41,7 @@ class MissingArrayElementsException extends FrameworkException { } // Add a message around the missing class - $message = sprintf("[%s:%d] Das Array %s() keine Elemente %s auf!", + $message = sprintf("[%s:%d] Array %s() Does not have these elements: %s", $classArray[0]->__toString(), $this->getLine(), $classArray[1], diff --git a/inc/classes/exceptions/main/class_MissingMethodException.php b/inc/classes/exceptions/main/class_MissingMethodException.php index 65eb60d..c51e1f5 100644 --- a/inc/classes/exceptions/main/class_MissingMethodException.php +++ b/inc/classes/exceptions/main/class_MissingMethodException.php @@ -7,6 +7,7 @@ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org + * @deprecated * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,16 +26,13 @@ class MissingMethodException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $classArray Array holding the exception data + * @param $code Code number for the exception * @return void */ public function __construct (array $classArray, $code) { - // Cast the array - $classArray = (array) $classArray; - // Add a message around the missing class - $message = sprintf("[%s:%d] Weisst keine Methode %s() auf!", + $message = sprintf("[%s:%d] This class has no method %s()!", $classArray[0]->__toString(), $this->getLine(), $classArray[1] diff --git a/inc/classes/exceptions/main/class_NullPointerException.php b/inc/classes/exceptions/main/class_NullPointerException.php index 42ed410..b3cb0c7 100644 --- a/inc/classes/exceptions/main/class_NullPointerException.php +++ b/inc/classes/exceptions/main/class_NullPointerException.php @@ -25,13 +25,13 @@ class NullPointerException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Eine Instanz/Pointer ist auf null gesetzt.", + $message = sprintf("[%s:%d] An object instance is set to null.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/main/class_ResponseHeadersAlreadySentException.php b/inc/classes/exceptions/main/class_ResponseHeadersAlreadySentException.php index 16e36e1..e4b16b4 100644 --- a/inc/classes/exceptions/main/class_ResponseHeadersAlreadySentException.php +++ b/inc/classes/exceptions/main/class_ResponseHeadersAlreadySentException.php @@ -25,11 +25,11 @@ class ResponseHeadersAlreadySentException extends FrameworkException { /** * The constructor * - * @param $message Message from the exception - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Headers are already sent!", $class->__toString(), diff --git a/inc/classes/exceptions/template/class_BasePathIsEmptyException.php b/inc/classes/exceptions/template/class_BasePathIsEmptyException.php index 78dd857..432078b 100644 --- a/inc/classes/exceptions/template/class_BasePathIsEmptyException.php +++ b/inc/classes/exceptions/template/class_BasePathIsEmptyException.php @@ -25,13 +25,13 @@ class BasePathIsEmptyException extends FrameworkException { /** * The constructor * - * @param $class An array holding our informations - * @param $code Code number for the exception + * @param $class Class throwing this exception + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] Der Template-Basispfad ist leer.", + $message = sprintf("[%s:%d] Template path is empty.", $class->__toString(), $this->getLine() ); diff --git a/inc/classes/exceptions/template/class_BasePathIsNoDirectoryException.php b/inc/classes/exceptions/template/class_BasePathIsNoDirectoryException.php index f286d2b..22e4254 100644 --- a/inc/classes/exceptions/template/class_BasePathIsNoDirectoryException.php +++ b/inc/classes/exceptions/template/class_BasePathIsNoDirectoryException.php @@ -25,16 +25,16 @@ class BasePathIsNoDirectoryException extends FrameworkException { /** * The constructor * - * @param $class An array holding our informations - * @param $code Code number for the exception + * @param $classArray An array holding our informations + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Der Template-Basispfad %s existiert nicht oder ist eine Datei!", - $class[0]->__toString(), + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/template/class_BasePathReadProtectedException.php b/inc/classes/exceptions/template/class_BasePathReadProtectedException.php index f5105b4..1bfbac5 100644 --- a/inc/classes/exceptions/template/class_BasePathReadProtectedException.php +++ b/inc/classes/exceptions/template/class_BasePathReadProtectedException.php @@ -25,16 +25,16 @@ class BasePathReadProtectedException extends FrameworkException { /** * The constructor * - * @param $class An array holding our informations - * @param $code Code number for the exception + * @param $classArray An array holding our informations + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class $message = sprintf("[%s:%d] Der Template-Basispfad %s ist lesegeschützt! Bitte Zugriffsrechte (CHMOD) ändern.", - $class[0]->__toString(), + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/template/class_InvalidBasePathStringException.php b/inc/classes/exceptions/template/class_InvalidBasePathStringException.php index 9a2dbcf..9b1ce48 100644 --- a/inc/classes/exceptions/template/class_InvalidBasePathStringException.php +++ b/inc/classes/exceptions/template/class_InvalidBasePathStringException.php @@ -25,16 +25,16 @@ class InvalidBasePathStringException extends FrameworkException { /** * The constructor * - * @param $class An array holding our informations - * @param $code Code number for the exception + * @param $classArray Array holding exception data + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (array $classArray, $code) { // Add a message around the missing class - $message = sprintf("[%s:%d] %s ist keine Zeichenkette!", - $class[0]->__toString(), + $message = sprintf("[%s:%d] %s is not a string with a base path!", + $classArray[0]->__toString(), $this->getLine(), - $class[1] + $classArray[1] ); // Call parent constructor diff --git a/inc/classes/exceptions/template/class_UnsupportedTemplateEngineException.php b/inc/classes/exceptions/template/class_UnsupportedTemplateEngineException.php index 46d1519..596fb5b 100644 --- a/inc/classes/exceptions/template/class_UnsupportedTemplateEngineException.php +++ b/inc/classes/exceptions/template/class_UnsupportedTemplateEngineException.php @@ -25,13 +25,13 @@ class UnsupportedTemplateEngineException extends FrameworkException { /** * The constructor * - * @param $class An array holding our informations - * @param $code Code number for the exception + * @param $class Class throwing this class + * @param $code Code number for the exception * @return void */ - public function __construct (BaseFrameworkSystem $class, $code) { + public function __construct (FrameworkInterface $class, $code) { // Add a message around the missing class - $message = sprintf("Template-Engine %s wird nicht unterstützt.", + $message = sprintf("Template-Engine %s not (yet) supported.", $class->__toString() ); diff --git a/inc/classes/main/class_BaseFrameworkSystem.php b/inc/classes/main/class_BaseFrameworkSystem.php index 48d9e3a..7a738d6 100644 --- a/inc/classes/main/class_BaseFrameworkSystem.php +++ b/inc/classes/main/class_BaseFrameworkSystem.php @@ -176,16 +176,17 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { /** * Private super constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class) { + protected function __construct ($className) { // Set real class - $this->setRealClass($class); + $this->setRealClass($className); // Initialize the class if the registry is there if ((class_exists('Registry')) && (Registry::isInitialized() === false)) { $this->initInstance(); - } + } // END - if } /** @@ -201,7 +202,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { $this->getDebugInstance()->output(sprintf("[%s:] Das Objekt %s wird zerstört.
\n", __CLASS__, $this->__toString() )); - } + } // END - if // Destroy all informations about this class but keep some text about it alive $this->setObjectDescription(sprintf("Entferntes Objekt %s", $this->__toString())); @@ -270,6 +271,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { $argsString = sprintf("!INVALID:%s!", $args); } + // Output stub message $this->getDebugInstance()->output(sprintf("[%s::%s] Stub! Args: %s", $this->__toString(), $methodName, @@ -687,10 +689,10 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { /** * Validate if given object is the same as current * - * @param $object An object instance for comparison with this class + * @param $object An object instance for comparison with this class * @return boolean The result of comparing both's unique ID */ - public final function equals ($object) { + public final function equals (FrameworkInterface $object) { return ($this->getUniqueID() == $object->getUniqueID()); } @@ -698,8 +700,8 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { * Compare if both simulation part description and class name matches * (shall be enougth) * - * @param $itemInstance An object instance to an other class - * @return boolean The result of comparing class name simulation part description + * @param $itemInstance An object instance to an other class + * @return boolean The result of comparing class name simulation part description */ public function itemMatches ($itemInstance) { return ( @@ -714,11 +716,11 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { /** * Compare class name of this and given class name * - * @param $class The class name as string from the other class + * @param $className The class name as string from the other class * @return boolean The result of comparing both class names */ - public final function isClass ($class) { - return ($this->__toString() == $class); + public final function isClass ($className) { + return ($this->__toString() == $className); } /** diff --git a/inc/classes/main/commands/class_BaseCommand.php b/inc/classes/main/commands/class_BaseCommand.php index 505d8ad..ac8db97 100644 --- a/inc/classes/main/commands/class_BaseCommand.php +++ b/inc/classes/main/commands/class_BaseCommand.php @@ -30,11 +30,12 @@ class BaseCommand extends BaseFrameworkSystem { /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); } /** diff --git a/inc/classes/main/controller/class_BaseController.php b/inc/classes/main/controller/class_BaseController.php index b2951f5..1686f42 100644 --- a/inc/classes/main/controller/class_BaseController.php +++ b/inc/classes/main/controller/class_BaseController.php @@ -37,11 +37,12 @@ class BaseController extends BaseFrameworkSystem implements Registerable { /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Clean up a little $this->removeNumberFormaters(); diff --git a/inc/classes/main/database/class_BaseDatabaseFrontend.php b/inc/classes/main/database/class_BaseDatabaseFrontend.php index 56041e6..c53fb4e 100644 --- a/inc/classes/main/database/class_BaseDatabaseFrontend.php +++ b/inc/classes/main/database/class_BaseDatabaseFrontend.php @@ -34,11 +34,12 @@ abstract class BaseDatabaseFrontend extends BaseFrameworkSystem implements Datab /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct($class) { + protected function __construct($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Clean up a little $this->removeNumberFormaters(); diff --git a/inc/classes/main/factories/class_BaseFactory.php b/inc/classes/main/factories/class_BaseFactory.php index 68a856d..1ba8f84 100644 --- a/inc/classes/main/factories/class_BaseFactory.php +++ b/inc/classes/main/factories/class_BaseFactory.php @@ -30,12 +30,12 @@ class BaseFactory extends BaseFrameworkSystem { /** * Protected constructor * - * @param $class Name of the real class (not BaseFactory) + * @param $className Name of the real class (not BaseFactory) * @return void */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Clean up a little $this->removeNumberFormaters(); diff --git a/inc/classes/main/resolver/action/class_BaseActionResolver.php b/inc/classes/main/resolver/action/class_BaseActionResolver.php index 2de5ec7..83aa964 100644 --- a/inc/classes/main/resolver/action/class_BaseActionResolver.php +++ b/inc/classes/main/resolver/action/class_BaseActionResolver.php @@ -35,6 +35,7 @@ class BaseActionResolver extends BaseResolver { /** * Protected constructor * + * @param $className Name of the class * @return void */ protected function __construct ($className) { diff --git a/inc/classes/main/resolver/command/class_BaseCommandResolver.php b/inc/classes/main/resolver/command/class_BaseCommandResolver.php index 34ccf71..4ad1d3e 100644 --- a/inc/classes/main/resolver/command/class_BaseCommandResolver.php +++ b/inc/classes/main/resolver/command/class_BaseCommandResolver.php @@ -40,6 +40,7 @@ class BaseCommandResolver extends BaseResolver { /** * Protected constructor * + * @param $className Name of the class * @return void */ protected function __construct ($className) { diff --git a/inc/classes/main/user/class_Guest.php b/inc/classes/main/user/class_Guest.php index c5ea225..d07317a 100644 --- a/inc/classes/main/user/class_Guest.php +++ b/inc/classes/main/user/class_Guest.php @@ -45,14 +45,15 @@ class Guest extends BaseFrameworkSystem implements ManageableUser, Registerable /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class = "") { + protected function __construct ($className = "") { // Is the class name empty? Then this is not a specialized user class - if (empty($class)) $class = __CLASS__; + if (empty($className)) $className = __CLASS__; // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set part description $this->setObjectDescription("Generic user class"); diff --git a/inc/classes/main/user/class_User.php b/inc/classes/main/user/class_User.php index 6e9d8f7..3bc8388 100644 --- a/inc/classes/main/user/class_User.php +++ b/inc/classes/main/user/class_User.php @@ -45,14 +45,15 @@ class User extends BaseFrameworkSystem implements ManageableUser, Registerable { /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class = "") { + protected function __construct ($className = "") { // Is the class name empty? Then this is not a specialized user class - if (empty($class)) $class = __CLASS__; + if (empty($className)) $className = __CLASS__; // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Set part description $this->setObjectDescription("Generic user class"); diff --git a/inc/classes/middleware/class_BaseMiddleware.php b/inc/classes/middleware/class_BaseMiddleware.php index 472aa8b..79e1d0c 100644 --- a/inc/classes/middleware/class_BaseMiddleware.php +++ b/inc/classes/middleware/class_BaseMiddleware.php @@ -25,11 +25,12 @@ class BaseMiddleware extends BaseFrameworkSystem { /** * Protected constructor * + * @param $className Name of the class * @return void */ - protected function __construct ($class) { + protected function __construct ($className) { // Call parent constructor - parent::__construct($class); + parent::__construct($className); // Clean up a little $this->removeNumberFormaters(); diff --git a/inc/classes/middleware/compressor/class_CompressorChannel.php b/inc/classes/middleware/compressor/class_CompressorChannel.php index 3465380..2981804 100644 --- a/inc/classes/middleware/compressor/class_CompressorChannel.php +++ b/inc/classes/middleware/compressor/class_CompressorChannel.php @@ -71,10 +71,10 @@ class CompressorChannel extends BaseMiddleware implements Registerable { // Get the compressor's name. That's why you must name // your files like your classes and also that's why you // must keep on class in one file. - $class = substr($dir, 6, -4); + $className = substr($dir, 6, -4); // Get an instance from our object factory - $tempInstance = ObjectFactory::createObjectByName($class); + $tempInstance = ObjectFactory::createObjectByName($className); // Set the compressor $cInstance->setCompressor($tempInstance); -- 2.39.2