generateUniqueId() and more useless/deprecated methods removed, code speed-up, link...
authorRoland Häder <roland@mxchange.org>
Tue, 5 Aug 2008 14:20:21 +0000 (14:20 +0000)
committerRoland Häder <roland@mxchange.org>
Tue, 5 Aug 2008 14:20:21 +0000 (14:20 +0000)
189 files changed:
.gitattributes
application/blog/class_ApplicationHelper.php
application/blog/main/class_
application/selector/class_ApplicationHelper.php
application/selector/class_ApplicationSelector.php
application/ship-simu/class_ApplicationHelper.php
application/ship-simu/config.php
application/ship-simu/exceptions/class_InvalidContractPartnerException.php
application/ship-simu/exceptions/class_ItemNotInPriceListException.php
application/ship-simu/exceptions/class_ItemNotTradeableException.php
application/ship-simu/main/actions/ship-simu/class_ShipSimuLoginAction.php
application/ship-simu/main/actions/ship-simu/class_ShipSimuProfileAction.php
application/ship-simu/main/actions/web/class_WebLoginCompanyAction.php
application/ship-simu/main/bank/class_MoneyBank.php
application/ship-simu/main/class_
application/ship-simu/main/class_BasePersonell.php
application/ship-simu/main/class_BaseSimulator.php
application/ship-simu/main/class_Merchant.php
application/ship-simu/main/class_WorksContract.php
application/ship-simu/main/commands/web/class_WebShipsimuGuestLoginCommand.php
application/ship-simu/main/commands/web/class_WebShipsimuProfileCommand.php
application/ship-simu/main/commands/web/class_WebShipsimuRegisterCommand.php
application/ship-simu/main/commands/web/class_WebShipsimuUserLoginCommand.php
application/ship-simu/main/companies/class_ShippingCompany.php
application/ship-simu/main/constructions/berths/class_Berth.php
application/ship-simu/main/constructions/class_BaseConstruction.php
application/ship-simu/main/constructions/docks/class_DryDock.php
application/ship-simu/main/constructions/harbors/class_Harbor.php
application/ship-simu/main/constructions/terminals/class_Terminal.php
application/ship-simu/main/constructions/yards/class_Shipyard.php
application/ship-simu/main/drives/class_BaseDrive.php
application/ship-simu/main/drives/motor/class_Motor.php
application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php
application/ship-simu/main/goverment/class_SimpleGoverment.php [deleted file]
application/ship-simu/main/goverment/class_SimplifiedGoverment.php [new file with mode: 0644]
application/ship-simu/main/login/class_ShipSimuGuestLogin.php
application/ship-simu/main/login/class_ShipSimuUserLogin.php
application/ship-simu/main/login/helper/class_ShipSimuLoginHelper.php
application/ship-simu/main/parts/class_BaseShipPart.php
application/ship-simu/main/parts/maschineroom/class_MaschineRoom.php
application/ship-simu/main/personell/class_SimulatorPersonell.php
application/ship-simu/main/personell/company/class_CompanyEmployee.php
application/ship-simu/main/registration/class_ShipSimuRegistration.php
application/ship-simu/main/ships/class_BaseShip.php
application/ship-simu/main/ships/passenger/class_PassengerShip.php
application/ship-simu/main/structures/class_BaseStructure.php
application/ship-simu/main/structures/extended/cabines/class_BaseCabin.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/class_BaseUpperStructure.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
application/ship-simu/main/structures/extended/decks/class_BaseDeck.php
application/ship-simu/main/structures/extended/upper/class_Bridge.php
application/ship-simu/main/user/class_ShipSimuBaseUser.php
application/ship-simu/main/user/extended/class_ShipSimuGuest.php
application/ship-simu/main/user/extended/class_ShipSimuMember.php
application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php
application/ship-simu/main/wrapper/class_UserGovermentDatabaseWrapper.php [new file with mode: 0644]
application/ship-simu/templates/de/code/action_login_company.ctp
db/gov_user/.htaccess [new file with mode: 0644]
inc/classes/exceptions/helper/class_NoGroupOpenedException.php [new file with mode: 0644]
inc/classes/exceptions/main/class_InvalidObjectException.php
inc/classes/main/actions/class_
inc/classes/main/actions/post_registration/class_LoginAfterRegistrationAction.php
inc/classes/main/actions/web/class_WebLoginLogoutAction.php
inc/classes/main/actions/web/class_WebLoginProfileAction.php
inc/classes/main/auth/class_CookieAuth.php
inc/classes/main/cache/class_MemoryCache.php
inc/classes/main/class_
inc/classes/main/class_BaseFrameworkSystem.php
inc/classes/main/commands/class_
inc/classes/main/commands/image/class_ImageCodeCaptchaCommand.php
inc/classes/main/commands/web/class_WebConfirmCommand.php
inc/classes/main/commands/web/class_WebDoFormCommand.php
inc/classes/main/commands/web/class_WebHomeCommand.php
inc/classes/main/commands/web/class_WebLoginAreaCommand.php
inc/classes/main/commands/web/class_WebLoginCommand.php
inc/classes/main/commands/web/class_WebLoginFailedCommand.php
inc/classes/main/commands/web/class_WebLogoutDoneCommand.php
inc/classes/main/commands/web/class_WebRegisterCommand.php
inc/classes/main/commands/web/class_WebResendLinkCommand.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/console/class_ConsoleTools.php
inc/classes/main/controller/captcha/class_ImageCodeCaptchaController.php
inc/classes/main/controller/class_
inc/classes/main/controller/form/class_WebDoFormController.php
inc/classes/main/controller/image/class_ImageDefaultController.php
inc/classes/main/controller/login/class_WebLoginAreaController.php
inc/classes/main/controller/web/class_WebConfirmController.php
inc/classes/main/controller/web/class_WebDefaultController.php
inc/classes/main/controller/web/class_WebDefaultNewsController.php
inc/classes/main/controller/web/class_WebLoginController.php
inc/classes/main/controller/web/class_WebLoginFailedController.php
inc/classes/main/controller/web/class_WebLogoutDoneController.php
inc/classes/main/controller/web/class_WebRegisterController.php
inc/classes/main/controller/web/class_WebStatusController.php [new file with mode: 0644]
inc/classes/main/criteria/class_DataSetCriteria.php
inc/classes/main/criteria/class_SearchCriteria.php
inc/classes/main/criteria/class_UpdateCriteria.php
inc/classes/main/crypto/class_CryptoHelper.php
inc/classes/main/database/class_
inc/classes/main/database/class_BaseDatabaseWrapper.php
inc/classes/main/database/databases/class_LocalFileDatabase.php
inc/classes/main/database/wrapper/class_NewsDatabaseWrapper.php
inc/classes/main/database/wrapper/class_UserDatabaseWrapper.php
inc/classes/main/database/wrapper/class_UserPointsDatabaseWrapper.php
inc/classes/main/debug/class_DebugConsoleOutput.php
inc/classes/main/debug/class_DebugErrorLogOutput.php
inc/classes/main/debug/class_DebugWebOutput.php
inc/classes/main/factories/cache/class_CacheFactory.php
inc/classes/main/factories/objects/class_ObjectFactory.php
inc/classes/main/factories/web/class_WebNewsFactory.php
inc/classes/main/filter/auth/class_UserAuthFilter.php
inc/classes/main/filter/change/class_EmailChangeFilter.php
inc/classes/main/filter/change/class_PasswordChangeFilter.php
inc/classes/main/filter/checkboxes/class_RulesAcceptedFilter.php
inc/classes/main/filter/class_
inc/classes/main/filter/class_FilterChain.php
inc/classes/main/filter/crypto/class_CaptchaEncryptFilter.php
inc/classes/main/filter/guest/class_UserNameIsGuestFilter.php
inc/classes/main/filter/news/class_NewsDownloadFilter.php
inc/classes/main/filter/news/class_NewsProcessFilter.php
inc/classes/main/filter/null/class_NullFilter.php
inc/classes/main/filter/update/class_UserStatusConfimedUpdateFilter.php
inc/classes/main/filter/update/class_UserUpdateFilter.php
inc/classes/main/filter/validator/class_EmailValidatorFilter.php
inc/classes/main/filter/validator/class_PasswordValidatorFilter.php
inc/classes/main/filter/validator/class_UserNameValidatorFilter.php
inc/classes/main/filter/verifier/class_AccountPasswordVerifierFilter.php
inc/classes/main/filter/verifier/class_ConfirmCodeVerifierFilter.php
inc/classes/main/filter/verifier/class_EmailValidatorFilter.php
inc/classes/main/filter/verifier/class_GraphicalCodeCaptchaVerifierFilter.php
inc/classes/main/filter/verifier/class_PasswordGuestVerifierFilter.php
inc/classes/main/filter/verifier/class_PasswordVerifierFilter.php
inc/classes/main/filter/verifier/class_UserGuestVerifierFilter.php
inc/classes/main/filter/verifier/class_UserNameVerifierFilter.php
inc/classes/main/filter/verifier/class_UserStatusVerifierFilter.php
inc/classes/main/filter/verifier/class_UserUnconfirmedVerifierFilter.php
inc/classes/main/helper/captcha/class_
inc/classes/main/helper/captcha/class_BaseCaptcha.php
inc/classes/main/helper/captcha/images/class_ImageHelper.php
inc/classes/main/helper/captcha/web/class_GraphicalCodeCaptcha.php
inc/classes/main/helper/class_BaseHelper.php
inc/classes/main/helper/web/blocks/class_WebBlockHelper.php
inc/classes/main/helper/web/forms/class_WebFormHelper.php
inc/classes/main/helper/web/links/class_WebLinkHelper.php
inc/classes/main/images/class_
inc/classes/main/images/extended/class_PngImage.php
inc/classes/main/io/class_FileIoStream.php
inc/classes/main/io/class_FrameworkDirectoryPointer.php
inc/classes/main/io/class_FrameworkFileInputPointer.php
inc/classes/main/io/class_FrameworkFileOutputPointer.php
inc/classes/main/language/class_LanguageSystem.php
inc/classes/main/mailer/class_
inc/classes/main/mailer/debug/class_DebugMailer.php
inc/classes/main/output/class_ConsoleOutput.php
inc/classes/main/output/class_WebOutput.php
inc/classes/main/points/class_UserPoints.php
inc/classes/main/reader/class_DefaultNewsReader.php
inc/classes/main/registry/class_Registry.php
inc/classes/main/request/class_HttpRequest.php
inc/classes/main/resolver/action/web/class_WebActionResolver.php
inc/classes/main/resolver/command/image/class_ImageCommandResolver.php
inc/classes/main/resolver/command/web/class_WebCommandResolver.php
inc/classes/main/resolver/controller/image/class_ImageControllerResolver.php
inc/classes/main/resolver/controller/web/class_WebControllerResolver.php
inc/classes/main/response/class_HttpResponse.php
inc/classes/main/response/class_ImageResponse.php
inc/classes/main/result/class_DatabaseResult.php
inc/classes/main/rng/class_RandomNumberGenerator.php
inc/classes/main/template/image/class_ImageTemplateEngine.php
inc/classes/main/template/mail/class_MailTemplateEngine.php
inc/classes/main/template/web/class_WebTemplateEngine.php
inc/classes/main/user/guest/class_Guest.php
inc/classes/main/user/member/class_Member.php
inc/classes/middleware/compressor/class_CompressorChannel.php
inc/classes/middleware/database/class_DatabaseConnection.php
inc/classes/middleware/debug/class_DebugMiddleware.php
inc/classes/middleware/io/class_FileIoHandler.php
inc/config.php
package.sh

index b3e20355e0580516659b8a4b8eac10781efdbc95..e66f03a8089fbc7e5a6f7a4b9a1ca5b41d48a3e1 100644 (file)
@@ -137,7 +137,7 @@ application/ship-simu/main/drives/motor/class_Motor.php -text
 application/ship-simu/main/factories/.htaccess -text
 application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php -text
 application/ship-simu/main/goverment/.htaccess -text
 application/ship-simu/main/factories/.htaccess -text
 application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php -text
 application/ship-simu/main/goverment/.htaccess -text
-application/ship-simu/main/goverment/class_SimpleGoverment.php -text
+application/ship-simu/main/goverment/class_SimplifiedGoverment.php -text
 application/ship-simu/main/login/.htaccess -text
 application/ship-simu/main/login/class_ShipSimuGuestLogin.php -text
 application/ship-simu/main/login/class_ShipSimuUserLogin.php -text
 application/ship-simu/main/login/.htaccess -text
 application/ship-simu/main/login/class_ShipSimuGuestLogin.php -text
 application/ship-simu/main/login/class_ShipSimuUserLogin.php -text
@@ -189,6 +189,7 @@ application/ship-simu/main/user/extended/class_ShipSimuGuest.php -text
 application/ship-simu/main/user/extended/class_ShipSimuMember.php -text
 application/ship-simu/main/wrapper/.htaccess -text
 application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php -text
 application/ship-simu/main/user/extended/class_ShipSimuMember.php -text
 application/ship-simu/main/wrapper/.htaccess -text
 application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php -text
+application/ship-simu/main/wrapper/class_UserGovermentDatabaseWrapper.php -text
 application/ship-simu/starter.php -text
 application/ship-simu/templates/.htaccess -text
 application/ship-simu/templates/de/.htaccess -text
 application/ship-simu/starter.php -text
 application/ship-simu/templates/.htaccess -text
 application/ship-simu/templates/de/.htaccess -text
@@ -225,6 +226,7 @@ application/ship-simu/templates/images/de/image/code_captcha.itp -text
 /clear-cache.sh -text
 db/.htaccess -text
 db/company_user/.htaccess -text
 /clear-cache.sh -text
 db/.htaccess -text
 db/company_user/.htaccess -text
+db/gov_user/.htaccess -text
 db/news/.htaccess -text
 db/user/.htaccess -text
 db/user_points/.htaccess -text
 db/news/.htaccess -text
 db/user/.htaccess -text
 db/user_points/.htaccess -text
@@ -280,6 +282,7 @@ inc/classes/exceptions/helper/class_FormClosedException.php -text
 inc/classes/exceptions/helper/class_FormGroupClosedException.php -text
 inc/classes/exceptions/helper/class_FormOpenedException.php -text
 inc/classes/exceptions/helper/class_InvalidFormNameException.php -text
 inc/classes/exceptions/helper/class_FormGroupClosedException.php -text
 inc/classes/exceptions/helper/class_FormOpenedException.php -text
 inc/classes/exceptions/helper/class_InvalidFormNameException.php -text
+inc/classes/exceptions/helper/class_NoGroupOpenedException.php -text
 inc/classes/exceptions/helper/class_UserInstanceMissingException.php -text
 inc/classes/exceptions/io/.htaccess -text
 inc/classes/exceptions/io/class_DirPointerNotOpenedException.php -text
 inc/classes/exceptions/helper/class_UserInstanceMissingException.php -text
 inc/classes/exceptions/io/.htaccess -text
 inc/classes/exceptions/io/class_DirPointerNotOpenedException.php -text
@@ -489,6 +492,7 @@ inc/classes/main/controller/web/class_WebLoginController.php -text
 inc/classes/main/controller/web/class_WebLoginFailedController.php -text
 inc/classes/main/controller/web/class_WebLogoutDoneController.php -text
 inc/classes/main/controller/web/class_WebRegisterController.php -text
 inc/classes/main/controller/web/class_WebLoginFailedController.php -text
 inc/classes/main/controller/web/class_WebLogoutDoneController.php -text
 inc/classes/main/controller/web/class_WebRegisterController.php -text
+inc/classes/main/controller/web/class_WebStatusController.php -text
 inc/classes/main/criteria/.htaccess -text
 inc/classes/main/criteria/class_DataSetCriteria.php -text
 inc/classes/main/criteria/class_SearchCriteria.php -text
 inc/classes/main/criteria/.htaccess -text
 inc/classes/main/criteria/class_DataSetCriteria.php -text
 inc/classes/main/criteria/class_SearchCriteria.php -text
index 99443173144f816443f93815a84b725cbcbc8017..0746faa6668d6ae21ebc5835f114db285438a39f 100644 (file)
@@ -79,14 +79,9 @@ class ApplicationHelper extends BaseFrameworkSystem implements ManageableApplica
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Application-Helper");
-
-               // Create an unique ID
-               $this->generateUniqueId();
-
                // Tidy up a little
                $this->removeSystemArray();
                // Tidy up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        /**
        }
 
        /**
index 4e1385b6ecba96ac1e5ce90532f21262dfe14fb6..df220046153bd50dd6734855eb89c02ce6062072 100644 (file)
@@ -31,12 +31,6 @@ class  extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index d7a8c204948c838856f91c42a54f5c053b159a33..aa297ccd41068a2b2bd17c879b97a74459ea59f1 100644 (file)
@@ -74,14 +74,9 @@ class ApplicationHelper extends BaseFrameworkSystem implements ManageableApplica
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Application-Helper");
-
-               // Create an unique ID
-               $this->generateUniqueId();
-
                // Tidy up a little
                $this->removeSystemArray();
                // Tidy up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        /**
        }
 
        /**
index 007550f6bf00bf07563835a5d2a61e5f36f4f2bb..ddae1d49ff7a45a1a90e3342658885c96d3760dd 100644 (file)
@@ -59,12 +59,6 @@ class ApplicationSelector extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Applikationswechsler");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Remove system array and thousand seperator
                $this->removeSystemArray();
                $this->removeNumberFormaters();
                // Remove system array and thousand seperator
                $this->removeSystemArray();
                $this->removeNumberFormaters();
index 1c86aa825304c0cbf6a3259a7331fa8d44f45e7b..43cac8875ee8dd3b00f605b940da6f9ce5ed83ba 100644 (file)
@@ -79,14 +79,9 @@ class ApplicationHelper extends BaseFrameworkSystem implements ManageableApplica
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Application-Helper");
-
-               // Create an unique ID
-               $this->generateUniqueId();
-
                // Tidy up a little
                $this->removeSystemArray();
                // Tidy up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        /**
        }
 
        /**
index 51e2695acef07ac2766b40e4b363961810b7173a..307310d91d5b0dad61cd436ccea3f95277a23d2c 100644 (file)
@@ -235,6 +235,9 @@ $cfg->setConfigEntry('company_db_wrapper_class', "CompanyDatabaseWrapper");
 // CFG: USER-POINTS-DB-WRAPPER-CLASS
 $cfg->setConfigEntry('user_points_db_wrapper_class', "UserPointsDatabaseWrapper");
 
 // CFG: USER-POINTS-DB-WRAPPER-CLASS
 $cfg->setConfigEntry('user_points_db_wrapper_class', "UserPointsDatabaseWrapper");
 
+// CFG: USER-GOVERMENT-WRAPPER
+$cfg->setConfigEntry('user_gov_wrapper_class', "UserGovermentDatabaseWrapper");
+
 // CFG EMAIl-TPL-RESEND-LINK
 $cfg->setConfigEntry('email_tpl_resend_link', "text");
 
 // CFG EMAIl-TPL-RESEND-LINK
 $cfg->setConfigEntry('email_tpl_resend_link', "text");
 
@@ -266,7 +269,7 @@ $cfg->setConfigEntry('write_applications_action_points', 10000);
 $cfg->setConfigEntry('user_ppints_class', "UserPoints");
 
 // CFG: GOVERMENT-CLASS
 $cfg->setConfigEntry('user_ppints_class', "UserPoints");
 
 // CFG: GOVERMENT-CLASS
-$cfg->setConfigEntry('goverment_class', "SimpleGoverment");
+$cfg->setConfigEntry('goverment_class', "SimplifiedGoverment");
 
 // CFG: BANK-CLASS
 $cfg->setConfigEntry('bank_class', "MoneyBank");
 
 // CFG: BANK-CLASS
 $cfg->setConfigEntry('bank_class', "MoneyBank");
index 394ced8dca190581f275e73747cbe0b38e9f238f..3bf55f058cba5d4382c901b980457edb472dfbe3 100644 (file)
@@ -24,9 +24,8 @@
 class InvalidContractPartnerException extends FrameworkException {
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
 class InvalidContractPartnerException extends FrameworkException {
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
-               $message = sprintf("[%s:] <span id=\"exception_reason\">%s</span> ist kein g&uuml;tiger Vertragspartner.",
-                       $class->__toString(),
-                       $class->getObjectDescription()
+               $message = sprintf("[%s:] Kein g&uuml;tiger Vertragspartner.",
+                       $class->__toString()
                );
 
                // Call parent constructor
                );
 
                // Call parent constructor
index 4f75ef6d2b00f8639635f15d9587faca2e16c125..798e18c3eb8abde625a42ec5bbea668f3e4b6a91 100644 (file)
@@ -24,9 +24,8 @@
 class ItemNotInPriceListException extends FrameworkException {
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
 class ItemNotInPriceListException extends FrameworkException {
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
-               $message = sprintf("[Merchant:] Preis f&uuml;r den Artikel <span id=\"exception_reason\">%s</span> <em><span id=\"exception_reason\">%s</span></em> nicht gefunden.",
-                       $class->__toString(),
-                       $class->getObjectDescription()
+               $message = sprintf("[Merchant:] Preis f&uuml;r den Artikel <span id=\"exception_reason\">%s</span> nicht gefunden.",
+                       $class->__toString()
                );
 
                // Call parent constructor
                );
 
                // Call parent constructor
index 2d031bcf6e32907f71f0ef9811a3ebff4d4fa88b..2344c06d8157b9a0bf7c62dfeed1baee6737519d 100644 (file)
@@ -24,9 +24,8 @@
 class ItemNotTradeableException extends FrameworkException {
        public function __construct (array $classArray, $code) {
                // Add a message around the missing class
 class ItemNotTradeableException extends FrameworkException {
        public function __construct (array $classArray, $code) {
                // Add a message around the missing class
-               $message = sprintf("[%s:] <span id=\"exception_reason\">%s</span> ist nicht handelbar!",
-                       $classArray[0]->__toString(),
-                       $classArray[1]->getObjectDescription()
+               $message = sprintf("[%s:] Object not tradeable.",
+                       $classArray[0]->__toString()
                );
 
                // Call parent constructor
                );
 
                // Call parent constructor
index 66a6878b5f36e0aa69149e08c471b1f6f03d4c37..26aa0e3fad6d82cf40e69b4c7e03f00b65b8d88c 100644 (file)
@@ -30,12 +30,6 @@ class ShipSimuLoginAction extends BaseAction implements PerformableAction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Login welcome action");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 997ba0d49a01e86fd1a25cc8281aae327275143c..6c4526035d02ecdcd2c0c139540ebf1461422c61 100644 (file)
@@ -30,12 +30,6 @@ class ShipSimuProfileAction extends BaseAction implements PerformableAction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Profile action");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 30c6376fe84385756c858b7b3beaadd3511c4009..9cce441c861195ec8b76eb44bff261d748ed36f5 100644 (file)
@@ -30,12 +30,6 @@ class WebLoginCompanyAction extends BaseAction implements Commandable, Registera
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Shipping comany action");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 043654973a256d18ae6a58d947cb57a089cd7fbb..d4430ffa83d906103b822c6611ae686c73b3d432 100644 (file)
@@ -31,14 +31,7 @@ class MoneyBank extends BaseFrameworkSystem implements Registerable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("A money bank class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                // Clean up a little
-               $this->removeNumberFormaters();
                $this->removeSystemArray();
        }
 
                $this->removeSystemArray();
        }
 
index 2d6541c3d4624b59394ffe2275517fb8c7d6b53f..634096c87e941bb448a7ff1867a14f28bfa68b40 100644 (file)
@@ -31,12 +31,6 @@ class ??? extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index a0baf636eaec11440ab52ac50f747e22e34526e4..12347679d962efde40f8e0f2934b134f93e75487 100644 (file)
@@ -52,8 +52,9 @@ class BasePersonell extends BaseFrameworkSystem implements Personellizer {
                // Call parent constructor
                parent::__construct($className);
 
                // Call parent constructor
                parent::__construct($className);
 
-               // Set description
-               $this->setObjectDescription("Personal");
+               // Tidy up a little
+               $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        // Remove min/max ages
        }
 
        // Remove min/max ages
index db7a1f2319e91d65ccf49540a059abda6e728bf6..63f9d53771152cc2a9f088da3db6ea71ad432704 100644 (file)
@@ -46,10 +46,9 @@ class BaseSimulator extends BaseFrameworkSystem {
                // Call highest constructor
                parent::__construct($className);
 
                // Call highest constructor
                parent::__construct($className);
 
-               // Set part description and class name
-               $this->setObjectDescription("Simulator-Basis-Einheit");
-
                // Clean up a little, dies sollte ganz zum Schluss erfolgen!
                // Clean up a little, dies sollte ganz zum Schluss erfolgen!
+               $this->removeSystemArray();
+               $this->removeNumberFormaters();
                $this->removeResizeFactorArray();
                $this->removeCurrPart();
                $this->removeCurrShip();
                $this->removeResizeFactorArray();
                $this->removeCurrPart();
                $this->removeCurrShip();
@@ -117,22 +116,8 @@ class BaseSimulator extends BaseFrameworkSystem {
                $this->currShip = $shipInstance;
                $this->currPart = $partInstance;
 
                $this->currShip = $shipInstance;
                $this->currPart = $partInstance;
 
-               if (defined('DEBUG_CORE')) $this->debugOutput(sprintf("[%s:] Maschinenraum mit Motor <strong>%s</strong> wird fuer das Schiff <strong>%s</strong> konstruiert.",
-                       $this->__toString(),
-                       $this->getCurrPart()->getObjectDescription(),
-                       $this->currShip->getShipName()
-               ));
-
                // Passt ueberhaupt das Schiffsteil in's Schiff?
                if ($this->isShipPartSizeValid()) {
                // Passt ueberhaupt das Schiffsteil in's Schiff?
                if ($this->isShipPartSizeValid()) {
-                       // Berechnungen fuer umliegendes Objekt anpassen
-                       if (defined('DEBUG_CORE')) $this->debugOutput(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> vom Typ <strong>%s</strong> passt in das Schiff <strong>%s</strong> hinein.",
-                               $this->__toString(),
-                               $this->getCurrPart()->getObjectDescription(),
-                               $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.)
                        // Muessen die Masse angepasst werden?
                        if ($this->isResizeFactorValid()) {
                                // Neue Angaben berechnen (wir lassen etwas Lust fuer Kabelbaeume, Roehren, Maschinisten, etc.)
@@ -143,11 +128,6 @@ class BaseSimulator extends BaseFrameworkSystem {
                                // Passt dies nun immer noch?
                                if ($this->isNewSizeValid()) {
                                        // Das passt auch, dann Werte setzen und Motor-Instanz merken
                                // Passt dies nun immer noch?
                                if ($this->isNewSizeValid()) {
                                        // Das passt auch, dann Werte setzen und Motor-Instanz merken
-                                       if (defined('DEBUG_CORE')) $this->debugOutput(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> passt in das Schiff <strong>%s</strong> hinein.",
-                                               $this->__toString(),
-                                               $this->getObjectDescription(),
-                                               $this->currShip->getShipName()
-                                       ));
                                        $this->setWidth($this->newWidth);
                                        $this->setHeight($this->newHeight);
                                        $this->setLength($this->newLength);
                                        $this->setWidth($this->newWidth);
                                        $this->setHeight($this->newHeight);
                                        $this->setLength($this->newLength);
@@ -171,12 +151,6 @@ class BaseSimulator extends BaseFrameworkSystem {
 
                        // Existiert ein Schiffsteil?
                        if (!is_null($this->currPart)) {
 
                        // Existiert ein Schiffsteil?
                        if (!is_null($this->currPart)) {
-                               // Debug-Meldung ausgeben
-                               if (defined('DEBUG_CORE')) $this->debugOutput(sprintf("[%s:] Schiffsteil <strong>%s</strong> gefunden.",
-                                       $this->getCurrPart()->realClass,
-                                       $this->getCurrPart()->getObjectDescription()
-                               ));
-
                                // Schiffsteil-Instanz setzen
                                $this->setPartInstance($this->currPart);
 
                                // Schiffsteil-Instanz setzen
                                $this->setPartInstance($this->currPart);
 
index 52f63c1d4ecea78efe6fa0c06e345985f96749eb..b0748e7fc890f15118506f73624758fb12523b4f 100644 (file)
@@ -36,12 +36,6 @@ class Merchant extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("H&auml;ndler");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeSystemArray();
        }
                // Clean up a little
                $this->removeSystemArray();
        }
@@ -108,16 +102,6 @@ class Merchant extends BaseFrameworkSystem {
                // Secure pricing
                $price = (float) $price;
 
                // Secure pricing
                $price = (float) $price;
 
-               // Debug message
-               if ((defined('DEBUG_MERCHANT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Der H&auml;ndler <strong>%s</strong> kann nun das Schiffsteil <strong>%s</strong> &quot;<strong>%s</strong>&quot; zu <strong>%s</strong> verkaufen.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getMerchantName(),
-                       $itemInstance->__toString(),
-                       $itemInstance->getObjectDescription(),
-                       $this->formatCurrency($price)
-               ));
-
                // Construct pricing item and add it to the list
                $this->priceList->append(array(
                        'item'  => $itemInstance,
                // Construct pricing item and add it to the list
                $this->priceList->append(array(
                        'item'  => $itemInstance,
index 4a6005911552cce971e9537011f4c59afa048d23..7f61096fc5a532879b97652195be0a38d939b722 100644 (file)
@@ -45,14 +45,9 @@ class WorksContract extends BaseFrameworkSystem implements SignableContract {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Bauvertrag");
-
-               // Unique-ID generieren
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeSystemArray();
                // Clean up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        // Neuen Bauvertrag generieren
        }
 
        // Neuen Bauvertrag generieren
@@ -64,15 +59,6 @@ class WorksContract extends BaseFrameworkSystem implements SignableContract {
                // Get new instance
                $contractInstance = new WorksContract();
 
                // Get new instance
                $contractInstance = new WorksContract();
 
-               // Debug-Meldung ausgeben
-               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $contractInstance->debugOutput(sprintf("[%s:%d] Neuer Bauvertrag wird f&uuml;r das Schiff <strong>%s</strong> mit der <strong>%s</strong> <strong>%s</strong> erstellt.",
-                       __CLASS__,
-                       __LINE__,
-                       $shipName,
-                       $partnerInstance->getObjectDescription(),
-                       $partnerInstance->getCompanyName()
-               ));
-
                // Schiffsnamen setzen
                $contractInstance->setShipName($shipName);
 
                // Schiffsnamen setzen
                $contractInstance->setShipName($shipName);
 
@@ -166,23 +152,8 @@ class WorksContract extends BaseFrameworkSystem implements SignableContract {
                // Get price for this item
                $price = $this->getMerchantInstance()->getPriceFromList($partInstance);
 
                // Get price for this item
                $price = $this->getMerchantInstance()->getPriceFromList($partInstance);
 
-               // Final debug message
-               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] <strong>%s</strong> kostet <strong>%s</strong>.",
-                       __CLASS__,
-                       __LINE__,
-                       $partInstance->getObjectDescription(),
-                       $this->getMerchantInstance()->formatCurrency($price)
-               ));
-
                // Add price
                $partInstance->setPrice($price);
                // Add price
                $partInstance->setPrice($price);
-
-               // Final debug message
-               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] <strong>%s</strong> wurde in den Bauvertrag aufgenommen.",
-                       __CLASS__,
-                       __LINE__,
-                       $partInstance->getObjectDescription()
-               ));
        }
 
        // Setter for contract partner
        }
 
        // Setter for contract partner
index b936f478e3b4f837b226c34b03eace71c431383d..b7f99246be5a3068a77d2ac580aba3271185786f 100644 (file)
@@ -31,12 +31,6 @@ class WebShipsimuGuestLoginCommand extends BaseCommand implements Commandable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("User login handling command for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 2493fdcec80cb1cac7934037eb88e535407e643b..ad5c6b8a91e79b234ac5adbd3bf456682588c9f6 100644 (file)
@@ -55,12 +55,6 @@ class WebShipsimuProfileCommand extends BaseCommand implements Commandable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Registration handling command for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 8ac3766749a63cf96217bdd1e1f8508ca437e26b..a6afca66befcfdcf1aaecca27fe326636c9f1cb9 100644 (file)
@@ -31,12 +31,6 @@ class WebShipsimuRegisterCommand extends BaseCommand implements Commandable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Registration handling command for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index de345a89dca41e31bd2c015b69c3e906f0ee0156..83ba7da6d383480f1740e9232971e7b5da88fad6 100644 (file)
@@ -31,12 +31,6 @@ class WebShipsimuUserLoginCommand extends BaseCommand implements Commandable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("User login handling command for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 971c578cf44974d5a7622d3d26f458f04ecdb46c..7a00527ffa33504c8600a871aca9d3e59df05ea1 100644 (file)
@@ -73,15 +73,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("A shipping company class");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
@@ -97,7 +88,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
 
                // Does the given user owns a company?
                if ($companyInstance->ifUserParticipatesInCompany($userInstance)) {
 
                // Does the given user owns a company?
                if ($companyInstance->ifUserParticipatesInCompany($userInstance)) {
-                       // Then do some nastly caching here but don't throw an exception
+                       // Then do some nasty caching here but don't throw an exception
                        // because then you will hurt our web helpers... :/
                        $companyInstance->partialStub("Don&#39;t throw exceptions here.");
                } // END - if
                        // because then you will hurt our web helpers... :/
                        $companyInstance->partialStub("Don&#39;t throw exceptions here.");
                } // END - if
@@ -345,7 +336,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
 
                        // Make this person employed and give him some money to work
                        $employee->setEmployed(true);
 
                        // Make this person employed and give him some money to work
                        $employee->setEmployed(true);
-                       $employee->setObjectDescription($dummy->getObjectDescription());
                        $employee->setRealClass($dummy->__toString());
                        $employee->increaseSalary((mt_rand(7, 14) * 100)); // Are 700 to 1400 EUR for the begin okay?
 
                        $employee->setRealClass($dummy->__toString());
                        $employee->increaseSalary((mt_rand(7, 14) * 100)); // Are 700 to 1400 EUR for the begin okay?
 
@@ -487,14 +477,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                        $shipType
                ));
 
                        $shipType
                ));
 
-               // Debug message
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> baut in allen Werften bald Schiffe vom Typ <strong>%s</strong>.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $shipInstance->getObjectDescription()
-               ));
-
                // Iterate shipyard list
                for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
                        // Get current element
                // Iterate shipyard list
                for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
                        // Get current element
@@ -519,13 +501,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
 
        // Validate the requested ship type with the company if they can construct it
        public function validateWorksContractShipType (SignableContract $contractInstance) {
 
        // Validate the requested ship type with the company if they can construct it
        public function validateWorksContractShipType (SignableContract $contractInstance) {
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> pr&uuml;ft den Bauauftrag der <strong>%s</strong>.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $contractInstance->getShipName()
-               ));
-
                // First get the ship type
                $shipInstance = $contractInstance->getShipInstance();
 
                // First get the ship type
                $shipInstance = $contractInstance->getShipInstance();
 
@@ -541,15 +516,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                // Get it's real class name
                $shipType = $shipInstance->__toString();
 
                // Get it's real class name
                $shipType = $shipInstance->__toString();
 
-               // Debug message
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> pr&uuml;ft, ob die <strong>%s</strong> (Typ:<strong>%s</strong>) gebaut werden kann.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $contractInstance->getShipName(),
-                       $shipInstance->getObjectDescription()
-               ));
-
                // Now check if the ship type is in any list and return the result
                return ($this->isShipTypeConstructable($shipType));
        }
                // Now check if the ship type is in any list and return the result
                return ($this->isShipTypeConstructable($shipType));
        }
@@ -608,13 +574,6 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
 
        // As a customer the shipping company can add new contracts
        public function addNewWorksContract (SignableContract $contractInstance) {
 
        // As a customer the shipping company can add new contracts
        public function addNewWorksContract (SignableContract $contractInstance) {
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> erstellt einen Bauauftrag f&uuml;r ein <strong>%s</strong> mit dem Namen <strong>%s</strong>.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $contractInstance->getShipInstance()->getObjectDescription(),
-                       $contractInstance->getShipInstance()->getShipName()
-               ));
                $this->contractList->append($contractInstance);
        }
 
                $this->contractList->append($contractInstance);
        }
 
index f0a55c1256d7a5c572aade2d853d3389c79747d7..1978df598ee14026b88f3ab3d16400b455e8694a 100644 (file)
@@ -32,12 +32,6 @@ class Berth extends BaseConstruction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Liegeplatz");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
        }
 }
 
        }
 }
 
index b1493e4fd854eb88d3dd2a61c19f00d4342ea67d..62275cb20c37201886c27153906914632940f24d 100644 (file)
@@ -29,12 +29,6 @@ class BaseConstruction extends BaseSimulator {
        protected function __construct ($className) {
                // Eltern-Konstrutor aufrufen
                parent::__construct($className);
        protected function __construct ($className) {
                // Eltern-Konstrutor aufrufen
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Namenlose Landkonstruktion");
-
-               // Clean up a little
-               $this->removeNumberFormaters();
        }
 }
 
        }
 }
 
index a8ce7e6a7828c81a0e04b8c8967a423ec17c7931..34984f0b2f4af401a0c940ae28dd862f983328b4 100644 (file)
@@ -29,12 +29,6 @@ class DryDock extends BaseConstruction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Trockendock");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
        }
 }
 
        }
 }
 
index 9cae1be691cea0e1872c00167caa65adb37861bc..011dc6c3bbc0f01444727ba6af7305471fcbf7ed 100644 (file)
@@ -38,16 +38,6 @@ class Harbor extends BaseConstruction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Hafen");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
-               $this->removePartInstance();
        }
 
        // Creates a harbor
        }
 
        // Creates a harbor
index 43c92dc98c643bd1eb0dbd6860428d37412ab8ea..8063f812365871453462459184f9ea5496d52f15 100644 (file)
@@ -29,12 +29,6 @@ class Terminal extends BaseConstruction {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Anlegebr&uuml;cke");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
        }
 }
 
        }
 }
 
index 474821a237f8118d0dc8dce20e5f5e94bc3d9488..36f85edce3d48aec95db8525a0f5d2cc70c82404 100644 (file)
@@ -49,15 +49,9 @@ class Shipyard extends BaseConstruction {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Werft");
-
                // Staff-Liste/Schiffstyp-Liste erzeugen
                $this->createStaffList();
                $this->createShipTypeList();
                // Staff-Liste/Schiffstyp-Liste erzeugen
                $this->createStaffList();
                $this->createShipTypeList();
-
-               // Generate unique ID number
-               $this->generateUniqueId();
        }
 
        // Create a shipyard and notify it about it's owner
        }
 
        // Create a shipyard and notify it about it's owner
index 0308f82b470a0b25ea4a130bf0a1244499bb857d..385a200672173d8e11c80ee6163695f3d2ec3083 100644 (file)
@@ -33,13 +33,6 @@ class BaseDrive extends BaseSimulator {
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Namenloser Antrieb");
-
-               // Clean up a little
-               $this->removeNumberFormaters();
-               $this->removePartInstance();
        }
 
        // Setter-Methode fuert PS-Zahl
        }
 
        // Setter-Methode fuert PS-Zahl
index 8f8b61f51404a34509d4bace8069bc6c0e000f72..c1ed35b1cdebee6c07cdd68da765c5e96ba3724f 100644 (file)
@@ -26,15 +26,6 @@ class Motor extends BaseDrive implements TradeableItem, ConstructableShipPart {
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Namenloser Motor");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Einen Motor erstellen
        }
 
        // Einen Motor erstellen
@@ -43,7 +34,6 @@ class Motor extends BaseDrive implements TradeableItem, ConstructableShipPart {
                $motorInstance = new Motor();
 
                // Beschreibung und Abmasse setzen
                $motorInstance = new Motor();
 
                // Beschreibung und Abmasse setzen
-               $motorInstance->setObjectDescription($descr);
                $motorInstance->setWidth($w);
                $motorInstance->setHeight($h);
                $motorInstance->setLength($l);
                $motorInstance->setWidth($w);
                $motorInstance->setHeight($h);
                $motorInstance->setLength($l);
index d2ecd37f79cefae1445af82537264e720586a4eb..f1c7919e945e8eff7e4d72b79e8a718327ba44c2 100644 (file)
@@ -31,12 +31,6 @@ class ShipSimuWebNewsFactory extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("News-Objektefabrik f&uuml;r Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
diff --git a/application/ship-simu/main/goverment/class_SimpleGoverment.php b/application/ship-simu/main/goverment/class_SimpleGoverment.php
deleted file mode 100644 (file)
index 68882be..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-<?php
-/**
- * A goverment class with simplified ways...
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @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
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-class SimpleGoverment extends BaseFrameworkSystem implements Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A class for simplified goverment");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeNumberFormaters();
-               $this->removeSystemArray();
-       }
-
-       /**
-        * Creates an instance of this goverment class by given user instance
-        *
-        * @param       $userInstance           The user instance
-        * @return      $govermentInstance      Instance of the prepared goverment instance
-        */
-       public final static function createSimpleGoverment (ManageableAccount $userInstance) {
-               // Get a new instance
-               $govermentInstance = new SimpleGoverment();
-
-               // Set the user instance
-               $govermentInstance->setUserInstance($userInstance);
-
-               // Return the prepared instance
-               return $govermentInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/goverment/class_SimplifiedGoverment.php b/application/ship-simu/main/goverment/class_SimplifiedGoverment.php
new file mode 100644 (file)
index 0000000..0f0c4ca
--- /dev/null
@@ -0,0 +1,94 @@
+<?php
+/**
+ * A goverment class with simplified ways...
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @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
+ * @todo               Find an interface for goverments
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+class SimplifiedGoverment extends BaseFrameworkSystem implements Registerable {
+       // Constants
+       const STATUS_STARTER_HELP = "STARTER_HELP";
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+
+               // Clean up a little
+               $this->removeSystemArray();
+               $this->removeNumberFormaters();
+       }
+
+       /**
+        * Creates an instance of this goverment class by given user instance
+        *
+        * @param       $userInstance           The user instance
+        * @return      $govermentInstance      Instance of the prepared goverment instance
+        */
+       public final static function createSimplifiedGoverment (ManageableAccount $userInstance) {
+               // Get a new instance
+               $govermentInstance = new SimplifiedGoverment();
+
+               // Set the user instance
+               $govermentInstance->setUserInstance($userInstance);
+
+               // Return the prepared instance
+               return $govermentInstance;
+       }
+
+       /**
+        * Checks wether the goverment has already payed a startup help to the
+        * current user
+        *
+        * @return      $alreadyPayed   Wether the goverment has already payed
+        */
+       public function ifGovermentAlreadyPayedStartupHelp () {
+               // Default is not payed
+               $alreadyPayed = false;
+
+               // Now get a search criteria and set the user's name as criteria
+               $criteriaInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+               $criteriaInstance->addCriteria('gov_uid', $this->getUserInstance()->getUserName());
+               $criteriaInstance->addCriteria('gov_activity_status', self::STATUS_STARTER_HELP);
+               $criteriaInstance->setLimit(1);
+
+               // Get a wrapper instance
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
+
+               // Get result back
+               $resultInstance = $wrapperInstance->doSelectByCriteria($criteriaInstance);
+
+               // Was the query fine?
+               if ($resultInstance->getAffectedRows() === 1) {
+                       // Entry found!
+                       $alreadyPayed = true;
+               } // END - if
+
+               // Return the result
+               return $alreadyPayed;
+       }
+}
+
+// [EOF]
+?>
index 24c44f65c270cfd6a0ddf03cfd0c4d8fdda750e6..ba7ac31f961fbd4d5e80f5cdb9d161dfcb36bc49 100644 (file)
@@ -36,12 +36,6 @@ class ShipSimuGuestLogin extends BaseFrameworkSystem implements LoginableUser {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Guest login for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index eced73d98f53ec54eb18aed803084eb5ec4fff30..e3540405507a7b177f90ac8765d7599648063e6e 100644 (file)
@@ -36,12 +36,6 @@ class ShipSimuUserLogin extends BaseFrameworkSystem implements LoginableUser {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Login for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 2f54e718ed07394ff5f6c56c9c55cdc473b1cdaa..c4c01b0a4c29a8659c1509d1edd7ee0364af9fa6 100644 (file)
@@ -46,12 +46,6 @@ class ShipSimuLoginHelper extends BaseLoginHelper implements HelpableLogin {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Login helper for Ship-Simu");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 8f3494136738f949e13669789afa3759883725a7..59ab43969e98c02d72284e9d877c238d80290e9d 100644 (file)
@@ -29,12 +29,6 @@ class BaseShipPart extends BaseSimulator {
        protected function __construct($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Beschreibung
-               $this->setObjectDescription("Schiffsteil");
-
-               // Clean up a little
-               $this->removeNumberFormaters();
        }
 
        // Setter for price
        }
 
        // Setter for price
index d332c5f9a364774e23499329becded88078fa13f..074f924ed54f65fd0538bd566acf4e50de218f9c 100644 (file)
@@ -27,14 +27,9 @@ class MaschineRoom extends BaseShipPart {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Maschinenraum");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeSystemArray();
                // Clean up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        // Maschinenraum erstellen
        }
 
        // Maschinenraum erstellen
index 91916e580b1d80d3237ffa5181a057be68476fbc..1569708a897b6e3dd97bb4bf5b4ba71fc0a5c606 100644 (file)
@@ -39,15 +39,6 @@ class SimulatorPersonell extends BasePersonell {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Simulationspersonal");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
-               // Clean-up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 52a4d241340452b9054a378fa4906de285470593..3aee0897c630ce56f5785cade62cd8db63d0ed58 100644 (file)
@@ -29,15 +29,6 @@ class CompanyEmployee extends SimulatorPersonell {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Firmenangestellte(r)");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Generate a specified amount of personell
        }
 
        // Generate a specified amount of personell
index 60dc559df5002e4c0f723736ca871ed09f49ce0d..a043056c6ad43ccb6755c404bd8135b0ed343012 100644 (file)
@@ -54,12 +54,6 @@ class ShipSimuRegistration extends BaseRegistration {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Ship-Simu registration class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index b72af8ade74f41ce909556f4085e0574c562a39c..bdebb6862d79fdb085ace13b79418d0db890d9d2 100644 (file)
@@ -42,15 +42,11 @@ class BaseShip extends BaseSimulator {
                // Call parent constructor
                parent::__construct($className);
 
                // Call parent constructor
                parent::__construct($className);
 
-               // Set object description
-               $this->setObjectDescription("Allgemeines Schiff");
-
                // Prepare array object for all structures
                $this->createStructuresArray();
 
                // Clean-up a little
                $this->removePartInstance();
                // Prepare array object for all structures
                $this->createStructuresArray();
 
                // Clean-up a little
                $this->removePartInstance();
-               $this->removeNumberFormaters();
        }
 
        // Array-Objekt anlegen
        }
 
        // Array-Objekt anlegen
@@ -127,14 +123,6 @@ class BaseShip extends BaseSimulator {
                // Instanz im Aufbauten-Array vermerken
                $this->structures->append($partInstance);
 
                // Instanz im Aufbauten-Array vermerken
                $this->structures->append($partInstance);
 
-               // Debug-Meldung ausgeben
-               if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat das Schiffsteil <strong>%s</strong> eingebaut bekommen.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getShipName(),
-                       $partInstance->getObjectDescription()
-               ));
-
                // Alles klar!
                return true;
        }
                // Alles klar!
                return true;
        }
index 39f50db78d00aadf707f3b685d5ce79d5bfcb1d7..8d71cd5ded7a04eee0776c1e914985224585a346 100644 (file)
@@ -28,14 +28,9 @@ class PassengerShip extends BaseShip implements ConstructableShip {
                // Eltern-Kontruktor aufrufen
                parent::__construct(__CLASS__);
 
                // Eltern-Kontruktor aufrufen
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Passagier-Schiff");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeSystemArray();
                // Clean up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        // Passagier-Schiff erstellen
        }
 
        // Passagier-Schiff erstellen
index ebbc3fea19166219990d98a049ef7e9b00b0953a..0fcb348eaee81add538d821294d58408f2922701 100644 (file)
@@ -29,12 +29,6 @@ class BaseStructure extends BaseSimulator {
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Schiffsstrukturen");
-
-               // Clean up a little
-               $this->removeNumberFormaters();
        }
 
        // Setter for price
        }
 
        // Setter for price
index e83b262a0099759c9046d3ce06226075fddd0dc2..9425afada3f3f2995693e64d5137a493291474b2 100644 (file)
@@ -27,8 +27,9 @@ class BaseCabin extends BaseCabinStructure {
                // Call parent constructor
                parent::__construct($className);
 
                // Call parent constructor
                parent::__construct($className);
 
-               // Set description
-               $this->setObjectDescription("Kabine");
+               // Clean up a little
+               $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 
        // Is this a cabin?
        }
 
        // Is this a cabin?
index 095162292c401b03af018eaa43bae1d0c4d92ca6..280f6f8586cb2dee1c3d0197b5585cc251b51109 100644 (file)
@@ -26,15 +26,6 @@ class EconomyCabin extends BaseCabin implements TradeableItem, ConstructableShip
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Economy-Class-Kabine");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Economy-Kabine erstellen
        }
 
        // Economy-Kabine erstellen
index 367882872adabdc92bf0aff757d69642c18253eb..ee562a3cbb9a4094435c15f607f67f9db2730f9c 100644 (file)
@@ -26,15 +26,6 @@ class LowCabin extends BaseCabin implements TradeableItem, ConstructableShipPart
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("2Star-Class-Kabine");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // 2-Sterne-Klasse erstellen
        }
 
        // 2-Sterne-Klasse erstellen
index 3f181d8adede2e5105074af7be407a1da17bcdd6..1b52c2f4844adf0f53818a6310927c5c9ab815ea 100644 (file)
@@ -26,15 +26,6 @@ class LuxuryCabin extends BaseCabin implements TradeableItem, ConstructableShipP
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Luxuskabine");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Eine Luxuskabine erstellen
        }
 
        // Eine Luxuskabine erstellen
index 5a06df024b601f39a075442c05b5be3ec321db9d..f0a414903fd6fdeea83f92404cdcdd406424cc65 100644 (file)
@@ -26,15 +26,6 @@ class PremierCabin extends BaseCabin implements TradeableItem, ConstructableShip
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Premier-Class-Kabine");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Premier-Kabine erstellen
        }
 
        // Premier-Kabine erstellen
index d0c0aaa8b0326484e08bf4df7e0ff028db2eeace..f8e992e9f796bb0580ae1c6e6de22809e1e59566 100644 (file)
@@ -36,20 +36,10 @@ class BaseCabinStructure extends BaseStructure {
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Kabinenstruktur");
        }
 
        // Kabine hinzufuegen
        public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $cabinInstance) {
        }
 
        // Kabine hinzufuegen
        public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $cabinInstance) {
-               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Kabine <strong>%s</strong> wird f&uuml;r das Schiff <strong>%s</strong> konstruiert.",
-                       __CLASS__,
-                       __LINE__,
-                       $cabinInstance->getObjectDescription(),
-                       $shipInstance->getShipName()
-               ));
-
                // Eltern-Methode aufrufen
                parent::addShipPartToShip ($shipInstance, $cabinInstance);
 
                // Eltern-Methode aufrufen
                parent::addShipPartToShip ($shipInstance, $cabinInstance);
 
@@ -65,14 +55,6 @@ class BaseCabinStructure extends BaseStructure {
 
                // Instanz setzen
                $this->setDeckInstance($cabinInstance);
 
                // Instanz setzen
                $this->setDeckInstance($cabinInstance);
-
-               // Einbaut-Meldung ausgeben
-               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Kabine <strong>%s</strong> wurde in das Schiff eingebaut.",
-                       __CLASS__,
-                       __LINE__,
-                       $cabinInstance->getObjectDescription(),
-                       $shipInstance->getShipName()
-               ));
        }
 
        // Wrapper fuer setDeckInstance->setPartInstance
        }
 
        // Wrapper fuer setDeckInstance->setPartInstance
index 371a004d7bc5a06317c3fe28a9c4bfd58302463b..4ed75bb0add3922e0f1a4455e3860d56f1a54e34 100644 (file)
@@ -29,33 +29,16 @@ class BaseDeckStructure extends BaseStructure {
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Deckstruktur");
        }
 
        // Deckstruktur dem Schiff hinzufuegen
        public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $deckInstance) {
        }
 
        // Deckstruktur dem Schiff hinzufuegen
        public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $deckInstance) {
-               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Deck <strong>%s</strong> wird f&uuml;r das Schiff <strong>%s</strong> konstruiert.",
-                       __CLASS__,
-                       __LINE__,
-                       $deckInstance->getObjectDescription(),
-                       $shipInstance->getShipName()
-               ));
-
                // Eltern-Methode aufrufen
                parent::addShipPartToShip($shipInstance, $deckInstance);
 
                // Andere Daten uebertragen und von der Quelle loeschen
                $this->setNumDecks($deckInstance->getNumDecks());
                $deckInstance->removeNumDecks();
                // Eltern-Methode aufrufen
                parent::addShipPartToShip($shipInstance, $deckInstance);
 
                // Andere Daten uebertragen und von der Quelle loeschen
                $this->setNumDecks($deckInstance->getNumDecks());
                $deckInstance->removeNumDecks();
-
-               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Deck <strong>%s</strong> wurde in das Schiff <strong>%s</strong> eingebaut.",
-                       __CLASS__,
-                       __LINE__,
-                       $deckInstance->getObjectDescription(),
-                       $shipInstance->getShipName()
-               ));
        }
 
        // Deckanzahl entfernen
        }
 
        // Deckanzahl entfernen
index 5b2f1edf4af53d71bc76232b11f88c90441e923b..a28601738c4214b406c2ffab9ae3108363c30707 100644 (file)
 class BaseUpperStructure extends BaseStructure {
        /**
         * Constructor for all super structures on a ship
 class BaseUpperStructure extends BaseStructure {
        /**
         * Constructor for all super structures on a ship
+        *
+        * @return      void
         */
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
         */
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Set description
-               $this->setObjectDescription("Aufbauten");
        }
 }
 
        }
 }
 
index 4f7163d16c7795201f783928b9a493527ab49beb..b9fb2bf5d69bc332151e94e19a899c3d4deb3db6 100644 (file)
@@ -26,15 +26,6 @@ class CarDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Autodeck");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // Autodeck erstellen
        }
 
        // Autodeck erstellen
index 5fb92ebbb2b70801a8af68c57979ac4d2a6f4d7b..059e5d0b4dbf579bb297eafc4dcab879f1dfc741 100644 (file)
@@ -26,15 +26,6 @@ class TrainDeck extends BaseDeck implements TradeableItem, ConstructableShipPart
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Zug-Deck");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // LKW-Deck erstellen
        }
 
        // LKW-Deck erstellen
index 75e342eb6b3f21075cdbdda9103a98636d7d6005..2da4fa45d3af5b27d8e11b52ca84786001d6f265 100644 (file)
@@ -27,15 +27,6 @@ class TruckDeck extends BaseDeck implements TradeableItem, ConstructableShipPart
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("LKW-Deck");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        // LKW-Deck erstellen
        }
 
        // LKW-Deck erstellen
index f806d6130faa84c496c24d974a743b6520b1c6e6..aef2d45414440320156b3ebc4a114cae133b4f05 100644 (file)
 class BaseDeck extends BaseDeckStructure {
        /**
         * Constructor for cargo decks in general
 class BaseDeck extends BaseDeckStructure {
        /**
         * Constructor for cargo decks in general
+        *
+        * @return      void
         */
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
 
         */
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
 
-               // Set description
-               $this->setObjectDescription("Allgemeines Deck");
+               // Clean up a little
+               $this->removeSystemArray();
+               $this->removeNumberFormaters();
        }
 }
 
        }
 }
 
index ae3ca7d2d470aed76ff9c4986933aa2be1394bd8..3ce1d00ff0d35626950a66e7640543f669ce1c74 100644 (file)
@@ -27,14 +27,9 @@ class Bridge extends BaseUpperStructure implements TradeableItem, ConstructableS
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Br&uuml;cke");
-
-               // Generate unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeSystemArray();
                // Clean up a little
                $this->removeSystemArray();
+               $this->removeNumberFormaters();
                $this->removePartInstance();
        }
 
                $this->removePartInstance();
        }
 
index 911e91eab370a57f27f497bda8da9854042339af..020d0350474def0827b4622c098a4b93de696e53 100644 (file)
@@ -42,14 +42,14 @@ class ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
                // Get max allowed companies to found
                $maxFound = $this->getConfigInstance()->readConfig('max_allowed_companies_found');
 
                // Get max allowed companies to found
                $maxFound = $this->getConfigInstance()->readConfig('max_allowed_companies_found');
 
-               // Get a company wrapper
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class');
-
                // Now get a search criteria and set the user's name as criteria
                $criteriaInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
                $criteriaInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
                $criteriaInstance->setLimit($maxFound);
 
                // Now get a search criteria and set the user's name as criteria
                $criteriaInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
                $criteriaInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
                $criteriaInstance->setLimit($maxFound);
 
+               // Get a company wrapper
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class');
+
                // Do the count-select by criteria
                $totalRows = $wrapperInstance->doSelectCountByCriteria($criteriaInstance);
 
                // Do the count-select by criteria
                $totalRows = $wrapperInstance->doSelectCountByCriteria($criteriaInstance);
 
@@ -83,7 +83,7 @@ class ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
                } // END - if
 
                // Just forward this request to the user points class
                } // END - if
 
                // Just forward this request to the user points class
-               $hasRequired = $pointsInstance->ifUserHasRequiredPoints ($action);
+               $hasRequired = $pointsInstance->ifUserHasRequiredPoints($action);
 
                // Return the result
                return $hasRequired;
 
                // Return the result
                return $hasRequired;
@@ -125,7 +125,7 @@ class ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
         *
         * @return      $bankLends      Wether the money bank is able to lend money
         */
         *
         * @return      $bankLends      Wether the money bank is able to lend money
         */
-       public function ifUserAllowTakeCreditsFromMoneyBank () {
+       public function ifUserAllowedTakeCreditsFromMoneyBank () {
                // Per default the money bank cannot pay
                $bankLends = false;
 
                // Per default the money bank cannot pay
                $bankLends = false;
 
@@ -142,10 +142,12 @@ class ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
                } // END - if
 
                // Does the money bank lend more money?
                } // END - if
 
                // Does the money bank lend more money?
+               /** UNFINISHED PART!
                if ($bankInstance->ifBankLendsMoreMoney()) {
                        // Okay, that they will do
                        $bankLends = true;
                } // END - if
                if ($bankInstance->ifBankLendsMoreMoney()) {
                        // Okay, that they will do
                        $bankLends = true;
                } // END - if
+               */
 
                // Return result
                return $bankLends;
 
                // Return result
                return $bankLends;
@@ -175,10 +177,12 @@ class ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
                } // END - if
 
                // Now check if the user has maximum credits
                } // END - if
 
                // Now check if the user has maximum credits
+               /** UNFINISHED PART!
                if ($bankInstance->ifUserHasMaxCredits()) {
                        // Yes, he does!
                        $hasMaxCredits = true;
                } // END - if
                if ($bankInstance->ifUserHasMaxCredits()) {
                        // Yes, he does!
                        $hasMaxCredits = true;
                } // END - if
+               */
 
                // Return the result
                return $hasMaxCredits;
 
                // Return the result
                return $hasMaxCredits;
index 839e2d7bfa0930b5aa6e8b0656661bf7e5fd0b36..69d7763552f0d72e506cd8bad8d2ad22b4ca6190 100644 (file)
@@ -33,18 +33,9 @@ class ShipSimuGuest extends ShipSimuBaseUser implements ManageableGuest {
         * @param       $className      Name of the class
         * @return      void
         */
         * @param       $className      Name of the class
         * @return      void
         */
-       protected function __construct ($className = "") {
-               // Is the class name empty? Then this is not a specialized user class
-               if (empty($className)) $className = __CLASS__;
-
+       protected function __construct ($className = __CLASS__) {
                // Call parent constructor
                parent::__construct($className);
                // Call parent constructor
                parent::__construct($className);
-
-               // Set part description
-               $this->setObjectDescription("Special ship-simu class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 25e76b7bbe54f7e861f30d11152f5b55d181501f..a44718c393345b6146ba0bc85ff8e8dac76d88dd 100644 (file)
@@ -28,18 +28,22 @@ class ShipSimuMember extends ShipSimuBaseUser implements ManageableMember {
         * @param       $className      Name of the class
         * @return      void
         */
         * @param       $className      Name of the class
         * @return      void
         */
-       protected function __construct ($className = "") {
-               // Is the class name empty? Then this is not a specialized user class
-               if (empty($className)) $className = __CLASS__;
-
+       protected function __construct ($className = __CLASS__) {
                // Call parent constructor
                parent::__construct($className);
                // Call parent constructor
                parent::__construct($className);
+       }
 
 
-               // Set part description
-               $this->setObjectDescription("Special member class for Ship-Simu");
+       /**
+        * Destructor for e.g. flushing pending updates to the database
+        *
+        * @return      void
+        */
+       public function __destruct () {
+               // Flush any updated entries to the database
+               $this->flushPendingUpdates();
 
 
-               // Create unique ID number
-               $this->generateUniqueId();
+               // Call parent destructor
+               parent::__destruct();
        }
 
        /**
        }
 
        /**
index 3f2ade62de02f73412f05700eef376130a5a0075..752e40999e19dc27d7fccb157e8ac8e8c4cb44c4 100644 (file)
@@ -39,12 +39,6 @@ class CompanyDatabaseWrapper extends BaseDatabaseWrapper {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A wrapper for database access to company data");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
diff --git a/application/ship-simu/main/wrapper/class_UserGovermentDatabaseWrapper.php b/application/ship-simu/main/wrapper/class_UserGovermentDatabaseWrapper.php
new file mode 100644 (file)
index 0000000..8b668c3
--- /dev/null
@@ -0,0 +1,56 @@
+<?php
+/**
+ * A wrapper for database access to goverment->user data
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @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
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+class UserGovermentDatabaseWrapper extends BaseDatabaseWrapper {
+       // Constants for database tables
+       const DB_TABLE_USER_GOVERMENT = "gov_user";
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this wrapper class
+        *
+        * @return      $wrapperInstance        An instance of this wrapper class
+        */
+       public final static function createUserGovermentDatabaseWrapper () {
+               // Create a new instance
+               $wrapperInstance = new UserGovermentDatabaseWrapper();
+
+               // Set (primary!) table name
+               $wrapperInstance->setTableName(self::DB_TABLE_USER_GOVERMENT);
+
+               // Return the instance
+               return $wrapperInstance;
+       }
+}
+
+// [EOF]
+?>
index 937cd448750d4da2b9962c7315158e52156d9ee1..584136f3e8becadbc0ad2e0213b130b325221300 100644 (file)
@@ -2,32 +2,72 @@
 // Get a link helper instance
 $linkInstance = WebLinkHelper::createWebLinkHelper($this, 'company_links', 'index.php?app=ship-simu&amp;page=login_area');
 
 // Get a link helper instance
 $linkInstance = WebLinkHelper::createWebLinkHelper($this, 'company_links', 'index.php?app=ship-simu&amp;page=login_area');
 
-// Preftech the user data
+// Prefetch the user data
 $linkInstance->prefetchValueInstance('user');
 
 $linkInstance->prefetchValueInstance('user');
 
+// Add link group for company founder
+$linkInstance->addLinkGroup('company_founder', "Vielleicht willst du eine virtuelle Reederei gr&uuml;nden, um dich virtuell selbstst&auml;ndig zu machen?");
+
 // Maximum of allowed companies reached?
 if ($linkInstance->getValueInstance()->ifUserCreatedMaximumAllowedCompanies()) {
 // Maximum of allowed companies reached?
 if ($linkInstance->getValueInstance()->ifUserCreatedMaximumAllowedCompanies()) {
-       // No more companies allowed to create
+       // No more companies allowed to found
+       $linkInstance->addLinkNote("Du hast zu viele Firmen gegr&uuml;ndet. Bitte denke &uuml;ber eine Fusion (Zusammenlegung) nach.");
 } elseif ($linkInstance->getValueInstance()->ifUserHasRequiredPoints('found_new_company')) {
        // Enough money to found company
 } elseif ($linkInstance->getValueInstance()->ifUserHasRequiredPoints('found_new_company')) {
        // Enough money to found company
-} elseif ($linkInstance->getValueInstance()->ifUserHasRequiredPoints('write_applications')) {
+       $linkInstance->addActionLink('company_found', "Gr&uuml;nde eine virtuelle Firma und mache dich (virtuell) selbstst&auml;ndig.");
+} else {
+       // No more money left for founding company so place link here to refill page/money bank
+       if ($linkInstance->getValueInstance()->ifUserAllowedTakeCreditsFromMoneyBank()) {
+               // Display link to money bank page
+               $linkInstance->addActionLink('moneybank', "Jetzt deinen Kredit tilgen.");
+       } elseif ($linkInstance->getValueInstance()->ifUserHasMaximumCreditsWithMoneyBank()) {
+               // Maximum credits reached which a money bank can lent
+               $linkInstance->addLinkNote("Die Bank kann dir kein Geld mehr leihen, bitte zahle es auch wieder zur&uuml;ck.");
+               $linkInstance->addActionLink('moneybank&amp;sub=payback_credits', "Jetzt deinen Kredit tilgen.");
+       } else {
+               // Money bank is closed!
+               $linkInstance->addLinkNote("Die Bank hat derzeit geschlossen. Bitte sp&auml;ter nochmal versuchen.");
+       }
+}
+
+// Add link group for goverment
+$linkInstance->addLinkGroup('goverment', "Bewerbe dich bei anderen Firmen und hole dir eine Starthilfe vom Staat ab wenn du nicht fl&uuml;ssig bist!");
+
+if ($linkInstance->getValueInstance()->ifUserHasRequiredPoints('write_applications')) {
        // Enough money to write applications to other companies
        // Enough money to write applications to other companies
+       $linkInstance->addActionLink('company_list', "Alle Firmen auflisten zum Bewerben.");
 } elseif ($linkInstance->getValueInstance()->ifGovermentPaysStartupHelp()) {
        // Display link to goverment for startup help
 } elseif ($linkInstance->getValueInstance()->ifGovermentPaysStartupHelp()) {
        // Display link to goverment for startup help
-} // END - if
+       $linkInstance->addActionLink('goverment&amp;sub=request&amp;request=startup_help', "Direkt zum Antragsformular f&uuml;r deine Starthilfe.");
+} else {
+       // Even goverment cannot help the gamer here
+       $linkInstance->addLinkNote("Leider kann dir der Staat nicht mehr weiterhelfen, dich zu bewerben, da du zu oft Starthilfen erhalten hast. Hier muss aber noch weiter am Spiel gearbeitet werden. :-)");
+}
+
+// Add link group for money bank
+$linkInstance->addLinkGroup('moneybank', "Leihe dir zu g&uuml;nstigen Zinsen virtuelles Geld aus, wenn du mehr brauchst!");
 
 
-if ($linkInstance->getValueInstance()->ifUserAllowTakeCreditsFromMoneyBank()) {
+if ($linkInstance->getValueInstance()->ifUserAllowedTakeCreditsFromMoneyBank()) {
        // Display link to money bank page
        // Display link to money bank page
+       $linkInstance->addActionLink('moneybank', "Jetzt deinen Kredit tilgen.");
 } elseif ($linkInstance->getValueInstance()->ifUserHasMaximumCreditsWithMoneyBank()) {
        // Maximum credits reached which a money bank can lent
 } elseif ($linkInstance->getValueInstance()->ifUserHasMaximumCreditsWithMoneyBank()) {
        // Maximum credits reached which a money bank can lent
+       $linkInstance->addLinkNote("Die Bank kann dir kein Geld mehr leihen, bitte zahle es auch wieder zur&uuml;ck.");
+       $linkInstance->addActionLink('moneybank&amp;sub=payback_credits', "Jetzt deinen Kredit tilgen.");
 } else {
        // Money bank is closed!
 } else {
        // Money bank is closed!
+       $linkInstance->addLinkNote("Die Bank hat derzeit geschlossen. Bitte sp&auml;ter nochmal versuchen.");
 }
 
 }
 
+// Add link group for refill page
+$linkInstance->addLinkGroup('refill_page', "Hole dir virtuelles Geld von uns zu fairen Preisen!");
+
 if ($linkInstance->ifRefillPageActive()) {
        // Display link to refill page
 if ($linkInstance->ifRefillPageActive()) {
        // Display link to refill page
+       $linkInstance->addActionLink('money_refill', "Jetzt dein virtuelles Geld aufladen.");
 } else {
        // Refill page not active
 } else {
        // Refill page not active
+       $linkInstance->addLinkNote("Das Aufladen ist derzeit nicht m&ouml;glich oder gest&ouml;rt und wurde von uns deaktiviert.");
 }
 
 // Flush content to the template
 }
 
 // Flush content to the template
@@ -35,14 +75,16 @@ $linkInstance->flushContent();
 
 // End of PHP commands
 ?>
 
 // End of PHP commands
 ?>
-<div class="table_header" id="list_company_header">
-       Auflistung der Reedereien, an denenen du dich beteiligst:
-</div>
+<div class="table_main" id="list_companies">
+       <div class="table_header">
+               Auflistung der Reedereien, an denenen du dich beteiligst:
+       </div>
 
 
-<div class="table_list">
-       {?company_list?}
-</div>
+       <div class="table_list">
+               {?company_list?}
+       </div>
 
 
-<div class="table_footer">
-       {?company_links?}
+       <div class="table_footer">
+               {?company_links?}
+       </div>
 </div>
 </div>
diff --git a/db/gov_user/.htaccess b/db/gov_user/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/inc/classes/exceptions/helper/class_NoGroupOpenedException.php b/inc/classes/exceptions/helper/class_NoGroupOpenedException.php
new file mode 100644 (file)
index 0000000..c650070
--- /dev/null
@@ -0,0 +1,46 @@
+<?php
+/**
+ * An exception thrown when a group was not opened before
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @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
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+class NoGroupOpenedException extends FrameworkException {
+       /**
+        * The constructor
+        *
+        * @param       $msgArray       Array containing exception data
+        * @param       $code           Code number for the exception
+        * @return      void
+        */
+       public function __construct (array $msgArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:%d] Group not opened before. Raw text follows: <span id=\"exception_reason\">%s</span>",
+                       $msgArray[0]->__toString(),
+                       $this->getLine(),
+                       $msgArray[1]
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
index dc6cd4e323cd6adf68f9497ef63775467612643d..7a002d4550397501105fb5a54065f277a1e51414 100644 (file)
@@ -31,10 +31,9 @@ class InvalidObjectException extends FrameworkException {
         */
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
         */
        public function __construct (FrameworkInterface $class, $code) {
                // Add a message around the missing class
-               $message = sprintf("[%s:%d] Objects of type <span id=\"exception_reason\">%s</span> are not allowed here.",
+               $message = sprintf("[%s:%d] Object is not allowed here.",
                        $class->__toString(),
                        $class->__toString(),
-                       $this->getLine(),
-                       $class->getObjectDescription()
+                       $this->getLine()
                );
 
                // Call parent constructor
                );
 
                // Call parent constructor
index 61e4cd297fb7f2cb63ae96a07995f819c80a5668..a34ccda2683cb856efe69cc1758a1251c78cce17 100644 (file)
@@ -30,12 +30,6 @@ class ???Action extends BaseAction implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c079c929cfb0acb05d30cca020af025ce609cc95..068090ed36a7bb800e6660a8c4c40bd34639c3bd 100644 (file)
@@ -30,12 +30,6 @@ class LoginAfterRegistrationAction extends BaseAction implements PerformableActi
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Post registration action for logging in");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 4e2d69e636e8da5de77b8f578039ed10b421f72b..bf655451753d91ec6b8777ea7e5475ef86f97700 100644 (file)
@@ -30,12 +30,6 @@ class WebLoginLogoutAction extends BaseAction implements Commandable, Registerab
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Logout action");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index e7410e4230a7c7f3f2dc3c8ca1a91e774cd71971..3ed47c0a8d062c6dcc1a762670463f5b1f401d04 100644 (file)
@@ -30,12 +30,6 @@ class WebLoginProfileAction extends BaseAction implements Commandable, Registera
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Web profile action");
-
-               // Generate unique key
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c20727f2f5c13c4b71c1c429a6a93f525aa8f16b..6ef55044a176f4f667632b065892f79c137b48ff 100644 (file)
@@ -31,12 +31,6 @@ class CookieAuth extends BaseFrameworkSystem implements Authorizeable, Registera
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Cookie-based login");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index dcf378362a6f5ac6ba954f5cba43c914d66bbba3..840519d37fb3523c5c1c8bbdc02d7b0448f8542d 100644 (file)
@@ -36,12 +36,6 @@ class MemoryCache extends BaseFrameworkSystem implements Cacheable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Memory cache");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 4e1385b6ecba96ac1e5ce90532f21262dfe14fb6..df220046153bd50dd6734855eb89c02ce6062072 100644 (file)
@@ -31,12 +31,6 @@ class  extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index e0716d7ade32f511558a1b5f28b25e56fd164c62..198280bd430a4044918eb05421f3f00b0e0e571a 100644 (file)
@@ -83,16 +83,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         */
        private $realClass      = "FrameworkSystem";
 
         */
        private $realClass      = "FrameworkSystem";
 
-       /**
-        * A human-readable description for this simulator part
-        */
-       private $objectDescription      = "Namenlose Framework-Einheit";
-
-       /**
-        * The unique ID string for identifying all type of classes
-        */
-       private $uniqueID = "";
-
        /**
         * Thousands seperator
         */
        /**
         * Thousands seperator
         */
@@ -218,9 +208,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                // Is this object already destroyed?
                if ($this->__toString() != 'DestructedObject') {
                        // Destroy all informations about this class but keep some text about it alive
                // Is this object already destroyed?
                if ($this->__toString() != 'DestructedObject') {
                        // Destroy all informations about this class but keep some text about it alive
-                       $this->setObjectDescription(sprintf("Removed object <em>%s</em>", $this->__toString()));
                        $this->setRealClass('DestructedObject');
                        $this->setRealClass('DestructedObject');
-                       $this->resetUniqueID();
                } elseif ((defined('DEBUG_DESTRUCTOR')) && (is_object($this->getDebugInstance()))) {
                        // Already destructed object
                        $this->debugOutput(sprintf("[%s:] The object <strong>%s</strong> is already destroyed.",
                } elseif ((defined('DEBUG_DESTRUCTOR')) && (is_object($this->getDebugInstance()))) {
                        // Already destructed object
                        $this->debugOutput(sprintf("[%s:] The object <strong>%s</strong> is already destroyed.",
@@ -563,172 +551,16 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                $this->realClass = $realClass;
        }
 
                $this->realClass = $realClass;
        }
 
-       /**
-        * Generate unique ID from a lot entropy
-        *
-        * @return      void
-        */
-       public final function generateUniqueId () {
-               // Is the id set for this class?
-               if (empty($this->uniqueID)) {
-
-                       // Correct missing class name
-                       $corrected = false;
-                       if ($this->__toString() == "") {
-                               $this->setRealClass(__CLASS__);
-                               $corrected = true;
-                       }
-
-                       // Cache datbase instance
-                       $db = $this->getDatabaseInstance();
-
-                       // Generate new id
-                       $tempID = false;
-                       while (true) {
-                               // Generate a unique ID number
-                               $tempID = $this->generateIdNumber();
-                               $isUsed = false;
-
-                               // Try to figure out if the ID number is not yet used
-                               try {
-                                       // Is this a registry?
-                                       if ($this->__toString() == "Registry") {
-                                               // Registry, then abort here
-                                               break;
-                                       } elseif (is_object($db)) {
-                                               $isUsed = $db->isUniqueIdUsed($tempID, true);
-                                       }
-                               } catch (FrameworkException $e) {
-                                       // Catches all and ignores all ;-)
-                               }
-
-                               if (
-                                       (
-                                               $tempID !== false
-                                       ) && (
-                                               (
-                                                       $db === null
-                                               ) || (
-                                                       (
-                                                               is_object($db)
-                                                       ) && (
-                                                               !$isUsed
-                                                       )
-                                               )
-                                       )
-                               ) {
-                                       // Abort the loop
-                                       break;
-                               }
-                       } // END - while
-
-                       // Apply the new ID
-                       $this->setUniqueID($tempID);
-
-                       // Revert maybe corrected class name
-                       if ($corrected) {
-                               $this->setRealClass("");
-                       }
-
-                       // Remove system classes if we are in a system class
-                       if ((isset($this->systemClasses)) && (in_array($this->__toString(), $this->systemClasses))) {
-                               // This may save some RAM...
-                               $this->removeSystemArray();
-                       }
-               }
-       }
-
-       /**
-        * Generates a new ID number for classes based from the class' real name,
-        * the description and some random data
-        *
-        * @return      $tempID The new (temporary) ID number
-        */
-       private final function generateIdNumber () {
-               return sprintf("%s@%s",
-                       $this->__toString(),
-                       md5(sprintf("%s:%s:%s:%s:%s:%s",
-                               $this->__toString(),
-                               $this->getObjectDescription(),
-                               time(),
-                               getenv('REMOTE_ADDR'),
-                               getenv('SERVER_ADDR'),
-                               mt_rand()
-                       ))
-               );
-       }
-
-       /**
-        * Setter for unique ID
-        *
-        * @param               $uniqueID               The newly generated unique ID number
-        * @return      void
-        */
-       private final function setUniqueID ($uniqueID) {
-               // Cast to string
-               $uniqueID = (string) $uniqueID;
-
-               // Set the ID number
-               $this->uniqueID = $uniqueID;
-       }
-
-       /**
-        * Getter for unique ID
-        *
-        * @return      $uniqueID               The unique ID of this class
-        */
-       public final function getUniqueID () {
-               return $this->uniqueID;
-       }
-
-       /**
-        * Resets or recreates the unique ID number
-        *
-        * @return      void
-        */
-       public final function resetUniqueID() {
-               // Sweet and simple... ;-)
-               $newUniqueID = $this->generateIdNumber();
-               $this->setUniqueID($newUniqueID);
-       }
-
-       /**
-        * Getter for simulator description
-        *
-        * @return      $objectDescription      The description of this simulation part
-        */
-       public final function getObjectDescription () {
-               return $this->objectDescription;
-       }
-
-       /**
-        * Setter for simulation part description
-        *
-        * @param               $objectDescription      The description as string for this simulation part
-        * @return      void
-        */
-       public final function setObjectDescription ($objectDescription) {
-               $this->objectDescription = (String) $objectDescription;
-       }
-
-       /**
-        * Validate if given object is the same as current
-        *
-        * @param       $object An object instance for comparison with this class
-        * @return      boolean The result of comparing both's unique ID
-        */
-       public final function equals (FrameworkInterface $object) {
-               return ($this->getUniqueID() == $object->getUniqueID());
-       }
-
        /**
         * Compare if both simulation part description and class name matches
         * (shall be enough)
         *
         * @param       $itemInstance   An object instance to an other class
         * @return      boolean                 The result of comparing class name simulation part description
        /**
         * Compare if both simulation part description and class name matches
         * (shall be enough)
         *
         * @param       $itemInstance   An object instance to an other class
         * @return      boolean                 The result of comparing class name simulation part description
+        * @deprecated
         */
        public function itemMatches ($itemInstance) {
         */
        public function itemMatches ($itemInstance) {
+               $this->partialStub("Deprecated!");
                return (
                        (
                                $this->__toString()   == $itemInstance->__toString()
                return (
                        (
                                $this->__toString()   == $itemInstance->__toString()
@@ -838,40 +670,6 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                unset($this->systemClasses);
        }
 
                unset($this->systemClasses);
        }
 
-       /**
-        * Create a file name and path name from the object's unique ID number.
-        * The left part of the ID shall always be a valid class name and the
-        * right part an ID number.
-        *
-        * @return      $pfn    The file name with a prepended path name
-        * @throws      NoArrayCreatedException         If explode() fails to create an array
-        * @throws      InvalidArrayCountException      If the array contains less or
-        *                                                                              more than two elements
-        */
-       public final function getPathFileNameFromObject () {
-               // Get the main object's unique ID. We use this as a path/filename combination
-               $pathFile = $this->getUniqueID();
-
-               // Split it up in path and file name
-               $pathFile = explode("@", $pathFile);
-
-               // Are there two elements? Index 0 is the path, 1 the file name + global extension
-               if (!is_array($pathFile)) {
-                       // No array found
-                       throw new NoArrayCreatedException(array($this, 'pathFile'), self::EXCEPTION_ARRAY_EXPECTED);
-               } elseif (count($pathFile) != 2) {
-                       // Invalid ID returned!
-                       throw new InvalidArrayCountException(array($this, 'pathFile', count($pathFile), 2), self::EXCEPTION_ARRAY_HAS_INVALID_COUNT);
-               }
-
-               // Auto-append missing trailing slash
-               $pathFile[0] = $this->addMissingTrailingSlash($pathFile[0]);
-
-               // Create the file name and return it
-               $pfn = ($pathFile[0] . $pathFile[1]);
-               return $pfn;
-       }
-
        /**
         * Appends a trailing slash to a string
         *
        /**
         * Appends a trailing slash to a string
         *
@@ -1089,11 +887,13 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
         * @return      $markedCode             Marked PHP code
         */
        public function markupCode ($phpCode) {
         * @return      $markedCode             Marked PHP code
         */
        public function markupCode ($phpCode) {
+               // Init marked code
+               $markedCode = "";
+
                // Get last error
                $errorArray = error_get_last();
 
                // Init the code with error message
                // Get last error
                $errorArray = error_get_last();
 
                // Init the code with error message
-               $markedCode = "";
                if (is_array($errorArray)) {
                        // Get error infos
                        $markedCode = sprintf("<div id=\"error_header\">File: <span id=\"error_data\">%s</span>, Line: <span id=\"error_data\">%s</span>, Message: <span id=\"error_data\">%s</span>, Type: <span id=\"error_data\">%s</span></div>",
                if (is_array($errorArray)) {
                        // Get error infos
                        $markedCode = sprintf("<div id=\"error_header\">File: <span id=\"error_data\">%s</span>, Line: <span id=\"error_data\">%s</span>, Message: <span id=\"error_data\">%s</span>, Type: <span id=\"error_data\">%s</span></div>",
@@ -1108,7 +908,7 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                foreach (explode("\n", $phpCode) as $lineNo=>$code) {
                        // Add line numbers
                        $markedCode .= sprintf("<span id=\"code_line\">%s</span>: %s\n",
                foreach (explode("\n", $phpCode) as $lineNo=>$code) {
                        // Add line numbers
                        $markedCode .= sprintf("<span id=\"code_line\">%s</span>: %s\n",
-                               ($lineNo+1),
+                               ($lineNo + 1),
                                htmlentities($code, ENT_QUOTES)
                        );
                } // END - foreach
                                htmlentities($code, ENT_QUOTES)
                        );
                } // END - foreach
@@ -1118,9 +918,9 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
        }
 
        /**
        }
 
        /**
-        * Filter a given timestamp to make it look more beatifull for web-based
-        * front-ends. If null is given a message id null_timestamp will be
-        * resolved and returned.
+        * Filter a given GMT timestamp (non Uni* stamp!) to make it look more
+        * beatiful for web-based front-ends. If null is given a message id
+        * null_timestamp will be resolved and returned.
         *
         * @param       $timestamp      Timestamp to prepare (filter) for display
         * @return      $readable       A readable timestamp
         *
         * @param       $timestamp      Timestamp to prepare (filter) for display
         * @return      $readable       A readable timestamp
@@ -1134,7 +934,28 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                        // Get a message string
                        $readable = $this->getLanguageInstance()->getMessage('null_timestamp');
                } else {
                        // Get a message string
                        $readable = $this->getLanguageInstance()->getMessage('null_timestamp');
                } else {
-                       $this->partialStub("Do further analysis on timestamp {$timestamp}.");
+                       switch ($this->getLanguageInstance()->getLanguageCode()) {
+                               case "de": // German format is a bit different to default
+                                       // Split the GMT stamp up
+                                       $dateTime = explode(" ", $timestamp);
+                                       $dateArray = explode("-", $dateTime[0]);
+                                       $timeArray = explode(":", $dateTime[1]);
+
+                                       // Construct the timestamp
+                                       $readable = sprintf($this->getConfigInstance()->readConfig('german_date_time'),
+                                               $dateArray[0],
+                                               $dateArray[1],
+                                               $dateArray[2],
+                                               $timeArray[0],
+                                               $timeArray[1],
+                                               $timeArray[2]
+                                       );
+                                       break;
+
+                               default: // Default is pass-through
+                                       $readable = $timestamp;
+                                       break;
+                       }
                }
 
                // Return the stamp
                }
 
                // Return the stamp
index ec58ecdeba7d5eccaca81f9496d22eab461e23e5..cac39ce2b959b3a7c020dde5bf03f6a457bc9655 100644 (file)
@@ -30,15 +30,6 @@ class ???Command extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 1ece666e970440e723579c5b32c74204c28356d7..8c6794d3d310db7ad9ad7c5a13550e61699b19c5 100644 (file)
@@ -30,15 +30,6 @@ class ImageCodeCaptchaCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 5bfa866e8e71ea53e1d7f8036e35009e06dc44b2..db15067cc0e8306c3f37da4ab7f06aa5f8074f81 100644 (file)
@@ -30,15 +30,6 @@ class WebConfirmCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for confirmation link handling");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 03a63679c4686023194295a6b51c9dc94d41c937..d34e16f3221d068e2008de1851befc10d1409ae0 100644 (file)
@@ -30,15 +30,6 @@ class WebDoFormCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for handling forms on a centralized place");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 577968e7b555be68e0fb2cac1a93932f4dfc3735..14a7a9c6ff69029d31875c0b292b043753500d7c 100644 (file)
@@ -30,15 +30,6 @@ class WebHomeCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the &quot;home&quot; page");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index eae34135c4e0c9e443716f64626a451a9e1ab9b4..9f2c1cfa3390a2cf116b93569e205328ba2aabf3 100644 (file)
@@ -35,15 +35,6 @@ class WebLoginAreaCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the &quot;login area&quot; page");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 6dbb59e13490bed387a7957a1480add2961b2c25..e02e2b5b8435dd1c0cec7e121cd9b3d2a9b7c918 100644 (file)
@@ -30,15 +30,6 @@ class WebLoginCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the login form page");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index a60bb8e86db291dbc719a2a29b6817e63e9ac0d3..9981133487d64b8cb2a9485617bb03694ee1104e 100644 (file)
@@ -30,15 +30,6 @@ class WebLoginFailedCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the &quot;login failed&quot; page");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 73dd4d6b172c91e759f989971d09a7da7dc941d1..15ecb706881634d80a72fa310b4d8adbb9271ad4 100644 (file)
@@ -30,15 +30,6 @@ class WebLogoutDoneCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the &quot;logout done&quot; page");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 5b4d0b11dbcf247ec35ae3bd4f45dcb36f965c12..42f9379bb4d80ffc97131c4919a59006b40b1528 100644 (file)
@@ -30,15 +30,6 @@ class WebRegisterCommand extends BaseCommand implements Commandable, Registerabl
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for the registration form");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 3c69b344461c6e3900cdf58d663fd12ac7996db0..c6ba2a6c825fae30852167d326c488bc1f075ff4 100644 (file)
@@ -30,15 +30,6 @@ class WebResendLinkCommand extends BaseCommand implements Commandable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set special description
-               $this->setObjectDescription("Command for resending confirmation link");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 6fe5d5cbf8135cb111781439c5e875aeeab4d2e0..50a4bad2136717d9fa130c4bd32e206654563f73 100644 (file)
@@ -30,12 +30,6 @@ class Bzip2Compressor extends BaseFrameworkSystem implements Compressor {
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("BZIP2 compressor");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index d2e7577cb6f01b7714584c70b6fb7e4edf59d987..b4a30253bd7052e8bc5fc231d84647186f280bf9 100644 (file)
@@ -30,12 +30,6 @@ class GzipCompressor extends BaseFrameworkSystem implements Compressor {
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("GZIP compressor");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 8e5bbd91d14091b51d8ba07ffd760c1217872713..24128bc3b739e042656a673ea55b6a12a63e3771 100644 (file)
@@ -30,12 +30,6 @@ class NullCompressor extends BaseFrameworkSystem implements Compressor {
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Null compressor");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 80433e3da9be18d988c6104fff677f84d5d9e706..3b49f721685f3ce64e13ab9121f8d76eda3fba0f 100644 (file)
@@ -30,12 +30,6 @@ class ConsoleTools extends BaseFrameworkSystem {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("General console tools");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index f6ca911704f59cf0b9f916c080b3a7f062eefade..e84fca7a34d20cf73021acb3064d66d5229ebdde 100644 (file)
@@ -30,12 +30,6 @@ class ImageCodeCaptchaController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 34c80ff7488616df5daa5fa18a7b64903fe0c1a0..a6cea16e326509a7dfe78c2385ed676b8340ce96 100644 (file)
@@ -30,12 +30,6 @@ class ???Controller extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index a995bd200878d029fc15c34fc9651f1cbb84f527..e760492fcbfa4b8dd3addb09320826f256836f5b 100644 (file)
@@ -30,12 +30,6 @@ class WebDoFormController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Controller for handling forms");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index ccd458e136f199700e8b9c2bbfe8f0247e704c2f..689cee43ca0bc90ffa11470b9cfeb935c44b81aa 100644 (file)
@@ -30,15 +30,6 @@ class ImageDefaultController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Default image controller");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
-               // Clean up a little
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 7914e2e27492d370587b9fb9f5ef425d70b673d8..1a1900c3692c141fe04fb1a5ddb224542a84135f 100644 (file)
@@ -30,12 +30,6 @@ class WebLoginAreaController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Default controller with news");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 975d518964ec24b2a0dfc8064ff75474824965cb..64c845d01911ae57930e40b38cb2d92d62633ea0 100644 (file)
@@ -30,12 +30,6 @@ class WebConfirmController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Controller for confirmation link handling");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 2e9ac3f4a95bc43bbf95660c78dc6ca57e29857d..37cf3d9e710d18b6e13c5925174bc4575b477ef6 100644 (file)
@@ -31,12 +31,6 @@ class WebDefaultController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Default controller for all other web requests");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 5475572c3ddd6ede871168ac30ade3fdd04e59ef..1f6c0cc28a69f3988f70f1bfb5904464b9f56fd3 100644 (file)
@@ -30,12 +30,6 @@ class WebDefaultNewsController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Default controller with news");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 4b10387b1d2bd61d9ed93e18802d569d3f84f79b..f4ce05334afb2020b4fe2dfc74de7cffa7f3b83b 100644 (file)
@@ -31,12 +31,6 @@ class WebLoginController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Controller for login form");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index ca49d8903f90b1a320016156302f699c2a027652..5b39ab0f2219942e39fbdcff69e91eed17acedad 100644 (file)
@@ -30,12 +30,6 @@ class WebLoginFailedController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Login failed controller");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 061354ad309861d099c434c8332ac41354468bf1..58058b1066b0571d0e6b806b2798ee8f4c851e27 100644 (file)
@@ -30,12 +30,6 @@ class WebLogoutDoneController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Controller for login form");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index bcbd69e232442e12e8f786703e2602b67402bbbb..c848c472202d6f2db20b147d99e3b6f3678836b0 100644 (file)
@@ -30,12 +30,6 @@ class WebRegisterController extends BaseController implements Controller {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Controller for register form");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
diff --git a/inc/classes/main/controller/web/class_WebStatusController.php b/inc/classes/main/controller/web/class_WebStatusController.php
new file mode 100644 (file)
index 0000000..843e05c
--- /dev/null
@@ -0,0 +1,76 @@
+<?php
+/**
+ * Controller for changing user status
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @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
+ * @todo               This controller shall still provide some headlines for sidebars
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+class WebStatusController extends BaseController implements Controller {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @param       $resolverInstance               An instance of a command resolver class
+        * @return      $controllerInstance             A prepared instance of this class
+        */
+       public final static function createWebStatusController (CommandResolver $resolverInstance) {
+               // Create the instance
+               $controllerInstance = new WebStatusController();
+
+               // Set the command resolver
+               $controllerInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $controllerInstance;
+       }
+
+       /**
+        * Handles the given request and response
+        *
+        * @param       $requestInstance        An instance of a request class
+        * @param       $responseInstance       An instance of a response class
+        * @return      void
+        */
+       public function handleRequest (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get the command instance
+               $commandInstance = $this->getResolverInstance()->resolveCommandByRequest($requestInstance);
+
+               // This request was valid! :-D
+               $requestInstance->requestIsValid();
+
+               // Execute the command
+               $commandInstance->execute($requestInstance, $responseInstance);
+
+               // Flush the response out
+               $responseInstance->flushBuffer();
+       }
+}
+
+// [EOF]
+?>
index 61bdb32596e628db6a0b8aac6b1f237ff1329558..34715c52a9b784d3c97f6d8f1c2f7ce37cabe4f2 100644 (file)
@@ -52,12 +52,6 @@ class DataSetCriteria extends BaseFrameworkSystem implements StoreableCriteria {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Storeable data set for databases");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index d6e2c1ce01ba7dbae6952d9194128f9bba952736..b9f27db7b08859e83633d6ee3bec2ed3e0765f52 100644 (file)
@@ -48,12 +48,6 @@ class SearchCriteria extends BaseFrameworkSystem implements LocalSearchCriteria
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Search criteria class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index c5ba2ed114b19f3904daf2ea94258185f2116bca..af3f6a5775ca261405bdd0d3c160a874a6da4df2 100644 (file)
@@ -48,12 +48,6 @@ class UpdateCriteria extends BaseFrameworkSystem implements LocalUpdateCriteria
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Update criteria class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 4583bd7de738db4794f39589d912af7202e322e6..2ebafd8ed9c9dfdeffcda10ef4473645e620ccbc 100644 (file)
@@ -50,12 +50,6 @@ class CryptoHelper extends BaseFrameworkSystem implements Cryptable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Cryptographical helper");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index c97202d72ebb524a7346383aa4493509e0cfa8e4..1fdbd071bf1e365b33bb526669ecac4d98965a92 100644 (file)
@@ -32,12 +32,6 @@ class  extends BaseDatabaseFrontend {
                // Call parent constructor
                parent::__construct($class);
 
                // Call parent constructor
                parent::__construct($class);
 
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 7a4ee57fb57328259956521f7d56f01d14028c21..e406938b42fb4f025ec3a7b0d163888cbfef289a 100644 (file)
@@ -101,6 +101,29 @@ class BaseDatabaseWrapper extends BaseFrameworkSystem {
                return $resultInstance;
        }
 
                return $resultInstance;
        }
 
+       /**
+        * Count the numbers of rows we shall receive
+        *
+        * @param       $criteriaInstance       An instance of a Criteria class
+        * @return      $numRows                        Numbers of rows of database entries
+        */
+       public function doSelectCountByCriteria (Criteria $criteriaInstance) {
+               // Total numbers is zero by default
+               $numRows = 0;
+
+               // Get the result from above method
+               $resultInstance = $this->doSelectByCriteria($criteriaInstance);
+
+               // Was that query fine?
+               if ($resultInstance->ifStatusIsOkay()) {
+                       // Then get the number of rows
+                       $numRows = $resultInstance->getAffectedRows();
+               } // END - if
+
+               // Return the result
+               return $numRows;
+       }
+
        /**
         * Setter for table name
         *
        /**
         * Setter for table name
         *
index 60fb4d32011cb16527f8f225dbb822a57f62d0ac..69ce662f9e4055ae034a006259ff6bafaa027007 100644 (file)
@@ -80,13 +80,8 @@ class LocalFileDatabase extends BaseDatabaseFrontend implements DatabaseFrontend
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Class for local file databases");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
                // Clean up a little
                // Clean up a little
+               $this->removeNumberFormaters();
                $this->removeSystemArray();
        }
 
                $this->removeSystemArray();
        }
 
index f3753f3d43d8d01b84bcb71930c847c50919f961..9a87e6a701c79e3e949d56dcf881c8678311d105 100644 (file)
@@ -33,12 +33,6 @@ class NewsDatabaseWrapper extends BaseDatabaseWrapper {
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Database wrapper for news objects");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 0669cb8caf3c5186e1f403a66b4c042a71f2d67d..1bbbf0315c7365b83e2233e92c47c2ecb12c7466 100644 (file)
@@ -42,12 +42,6 @@ class UserDatabaseWrapper extends BaseDatabaseWrapper {
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Database wrapper for user objects");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c5490d3524dc2f0198fd749c532ea7a6b9573893..0a8af18ed5b338316b5c9868bd3bc088e8339f31 100644 (file)
@@ -33,12 +33,6 @@ class UserPointsDatabaseWrapper extends BaseDatabaseWrapper {
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Database wrapper for user points objects");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 2d3305dbdf1d5926d9e558cc1ac8aa6697515d1c..b9db256800dea703a3c677aafa3f0a7c9f281099 100644 (file)
@@ -30,12 +30,6 @@ class DebugConsoleOutput extends BaseFrameworkSystem implements Debugger, Output
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Debug output for the console");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index d20093a7139c97184a8cc970274b3c1efa734242..0d30d4f5be642f31e33ff3000bcfc1b93f6ab971 100644 (file)
@@ -30,12 +30,6 @@ class DebugErrorLogOutput extends BaseFrameworkSystem implements Debugger, Outpu
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Debug output to error_log()");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 353ccacbe486fa3b0f120ddb8d65aa448fd4b44a..268738a7a1ef4928ffc148f0eab7aaa42233a631 100644 (file)
@@ -30,12 +30,6 @@ class DebugWebOutput extends BaseFrameworkSystem implements Debugger, OutputStre
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Debug output for webpages");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 94c037d18bbd0d5735569cf607530e6d1f2b1905..2938b8742f16a316106052c35c45d885a7e9f328 100644 (file)
@@ -35,12 +35,6 @@ class CacheFactory extends BaseFactory {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set object description
-               $this->setObjectDescription("Factory for cache objects");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 984bd257bb6f1abdfcb22828aebbbe4e19a4c165..06c73d89c4e1e09a9143743ffdca642cbac5db8a 100644 (file)
@@ -35,12 +35,6 @@ class ObjectFactory extends BaseFactory {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set object description
-               $this->setObjectDescription("Simple generic object factory");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index b90492214128a2c469c4be0b2f31c765e7156b8c..d7307ec37279af64146de0f4867c6879fcea606b 100644 (file)
@@ -35,12 +35,6 @@ class WebNewsFactory extends BaseFactory {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Factory for webpages with news");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 5c871cd1c3938dd3fe294b7e79d930092dd9172e..b08d0c2b8df659c5d601d4db0e4051a3daba740d 100644 (file)
@@ -38,12 +38,6 @@ class UserAuthFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A user authorization filter");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c427fd69633bc195978385f53697802ce3baeedc..e64c2f1fad5ac9720fc4558c7ca890cfddd96803 100644 (file)
@@ -30,12 +30,6 @@ class EmailChangeFilter extends BaseFrameworkSystem implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for email changes");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index fd3988062f25f6f038f06e52f7e707850a4cde6b..078d2944f921408f94520582d5a5b9ad5703208b 100644 (file)
@@ -30,12 +30,6 @@ class PasswordChangeFilter extends BaseFrameworkSystem implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for password change");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 434586b87350258e59103415d5060f7815d38776..85e945e8bc66da5ee0a643a49f8a31904069a8ef 100644 (file)
@@ -32,12 +32,6 @@ class RulesAcceptedFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for checking if rules where accepted");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 78cfb6b8af830a2994207cb03cf06cfe7351b499..9027c5d1858caef511146b44342092b26c8d8e69 100644 (file)
@@ -31,12 +31,6 @@ class ???Filter extends BaseFrameworkSystem implements Filterable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("A concrete filter");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 79441bd7755cef58bd4a8065756cfd32b103aa1e..b3825dabd733d4aa7e5b5afa4e71fff909a13e50 100644 (file)
@@ -36,12 +36,6 @@ class FilterChain extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("A filter chain class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 8ddbd163a1d04e1734bdc4611085069e0215073a..b399a8917ccef5358e2fbf19385c17942dee14c5 100644 (file)
@@ -30,12 +30,6 @@ class CaptchaEncryptFilter extends BaseFrameworkSystem implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for checking encryption data");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index f6b1c33783ed480b619d988831848690949f8e8b..fc11b737f34b588f5a5fd6209ed456a66c7b8585 100644 (file)
@@ -31,12 +31,6 @@ class UserNameIsGuestFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for checking if username is the reserved guest login");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 7ec79d8d491aa8b225eb8549129da95b65f82030..1b57940f231d49d3523c212655fc6f7678ec96d3 100644 (file)
@@ -32,12 +32,6 @@ class NewsDownloadFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for downloading news");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 5bec3523f0189e25a9eca22abb173fce66bfeb7e..76ebf3df5f49b8a6a54c41fde1e3ddc4f305e0a2 100644 (file)
@@ -31,12 +31,6 @@ class NewsProcessFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for processing news");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 10a8536f23320ac1ee881bdfd23d8d446747d0e9..9b145bab808fad9b901e87b63a3dc3283c68d3e6 100644 (file)
@@ -31,12 +31,6 @@ class NullFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A null filter");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c6da66e3cdc2a738d3f91191a6e9387a13a06e53..7e301484ca5dca78e7eebd2cdb46dd5f8f5af4aa 100644 (file)
@@ -30,12 +30,6 @@ class UserStatusConfimedUpdateFilter extends BaseFrameworkSystem implements Filt
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("User status 'confirmed' update filter");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index e1549281d4d3df4c05746c0aca1e309fc79edf2e..be0c9a8bf7f74cd5cee0f919c68c55728c87f99d 100644 (file)
@@ -31,12 +31,6 @@ class UserUpdateFilter extends BaseFrameworkSystem implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("User update filter");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 23dff14121a7c6401cd874283094a503cd575e55..feb819e9915d0741da16188e6e58354017e3317d 100644 (file)
@@ -33,12 +33,6 @@ class EmailValidatorFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for Email validation");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index f8981e49e49771425c166e82bbb11198699c5390..8944f35886976861c65ac6e5f6cadc19320d2cb8 100644 (file)
@@ -31,12 +31,6 @@ class PasswordValidatorFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for Password validation");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 4150d2ceed5d19499729fcfae3390195c5da2ce6..522e77a82b426052be9ebf3f55ed3433edcede99 100644 (file)
@@ -33,12 +33,6 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for username validation");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index f28d1817ee3b633ddbf03f6386c06d6919cef66c..eab77bdeaa0fe50df4273a147f1c257aff079313 100644 (file)
@@ -31,12 +31,6 @@ class AccountPasswordVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for account password verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index e681df4ecd087682fe6d36c93ab3706bba6cd8fc..98fc1e67ce0a66798950b822aa1d221270048441 100644 (file)
@@ -30,12 +30,6 @@ class ConfirmCodeVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for confirmation code verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 23dff14121a7c6401cd874283094a503cd575e55..feb819e9915d0741da16188e6e58354017e3317d 100644 (file)
@@ -33,12 +33,6 @@ class EmailValidatorFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for Email validation");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index a43393269862239bc1057bd4cbbb3ce2c6d3957d..8bb65a44d39fdeb2c7fd0b319a2284c4f20a53e7 100644 (file)
@@ -30,12 +30,6 @@ class GraphicalCodeCaptchaVerifierFilter extends BaseFilter implements Filterabl
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for verifying graphical code CAPTCHAs");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index a6b6ca7df1a8ccaa9d4d541057375ed07ff5acdb..f2a15202e6eb80429601595f4e737e93f14052ea 100644 (file)
@@ -31,12 +31,6 @@ class PasswordGuestVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for password verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 1b576dae533b6f6f265eb46f47f36edd3cb1b621..0bd5ccebac88dda533130de8ab6a2bcc290b70e7 100644 (file)
@@ -31,12 +31,6 @@ class PasswordVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for password verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index c223af9a81c4281d81b1977dd46d1a038660de12..839b1eb96536330476500fdf9dedde17f0e5e056 100644 (file)
@@ -33,12 +33,6 @@ class UserGuestVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for username verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index da4791c7ea217d2099ee37a4ee8e93fc87768ef4..7d0bde9e05b283eb83d8a17957b4fd780b187903 100644 (file)
@@ -33,12 +33,6 @@ class UserNameVerifierFilter extends BaseFilter implements Filterable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for username verification");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 3b8fe727770c98143c0ec21f2a6ebf96a4a674d0..79e0aceb2b48efec86154b404258b188afdb0803 100644 (file)
@@ -30,12 +30,6 @@ class UserStatusVerifierFilter extends BaseFrameworkSystem implements Filterable
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for email changes");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index b2fc520700b255764b283ac7512a866dadc2e713..e36fa389882b2162e18ed3ea70ef82403ab0fc73 100644 (file)
@@ -30,12 +30,6 @@ class UserUnconfirmedVerifierFilter extends BaseFrameworkSystem implements Filte
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A filter for checking if the user account is unconfirmed");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 81a4bbbf6a157d538b27957ea4243cb5371e7dd0..758b205654be953a29596e013bd46751e9a04c29 100644 (file)
@@ -30,12 +30,6 @@ class ???Captcha extends BaseCaptcha implements SolveableCaptcha {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A solveable CAPTCHA");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 50efc1ae88260bb8dffae901aef41ce915fa740a..8cb138ef92ce5f20e50c4b2895e9c1011f5e247a 100644 (file)
@@ -41,10 +41,6 @@ class BaseCaptcha extends BaseHelper {
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
        protected function __construct ($className) {
                // Call parent constructor
                parent::__construct($className);
-
-               // Clean up a little
-               $this->removeNumberFormaters();
-               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index a29f5a19aba95cc1da3af4374863c623314a8384..0b5a76f03f45a4ecfee238f4bdab3d75b6d32a53 100644 (file)
@@ -78,9 +78,6 @@ class ImageHelper extends BaseCaptcha implements HelpableTemplate {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A image helper class");
        }
 
        /**
        }
 
        /**
index 3734bbc7647534577d10008da35c7c3f045756d9..37a206ca4b3d5ea836eb3f3548fd3ee999ef4dd0 100644 (file)
@@ -40,12 +40,6 @@ class GraphicalCodeCaptcha extends BaseCaptcha implements SolveableCaptcha {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A solveable graphical code CAPTCHA");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 94f48fbbc3a4171d2dd0bf878ca84b165237110e..ad0c6ca6d42179c529a133336103271039b7c6b2 100644 (file)
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
  */
 class BaseHelper extends BaseFrameworkSystem {
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
  */
 class BaseHelper extends BaseFrameworkSystem {
+       /**
+        * Instance to the class which provides field values
+        */
+       private $valueInstance = null;
+
        /**
         * Rendered content created by the helper class
         */
        private $content = "";
 
        /**
        /**
         * Rendered content created by the helper class
         */
        private $content = "";
 
        /**
-        * Instance to the class which provides field values
+        * Wether the group is opened or not
         */
         */
-       private $valueInstance = null;
+       private $groupOpened = false;
+
+       /**
+        * Wether the sub group is opened or not
+        */
+       private $subGroupOpened = false;
+
+       /**
+        * Name of the group
+        */
+       private $groupName = "";
+
+       /**
+        * Name of the sub group
+        */
+       private $subGroupId = "";
+
+       /**
+        * Previously opened group
+        */
+       private $previousGroupId = "";
+
+       /**
+        * Previously opened sub group
+        */
+       private $previousSubGroupId = "";
 
        // Exception constants
        const EXCEPTION_XML_PARSER_ERROR  = 0x1e0;
        const EXCEPTION_XML_NODE_UNKNOWN  = 0x1e1;
        const EXCEPTION_XML_NODE_MISMATCH = 0x1e2;
 
        // Exception constants
        const EXCEPTION_XML_PARSER_ERROR  = 0x1e0;
        const EXCEPTION_XML_NODE_UNKNOWN  = 0x1e1;
        const EXCEPTION_XML_NODE_MISMATCH = 0x1e2;
+       const EXCEPTION_GROUP_NOT_OPENED  = 0x1e3;
 
        /**
         * Protected constructor
 
        /**
         * Protected constructor
@@ -59,7 +90,7 @@ class BaseHelper extends BaseFrameworkSystem {
         * @return      void
         */
        protected final function addContent ($newContent) {
         * @return      void
         */
        protected final function addContent ($newContent) {
-               $this->content .= (string) trim($newContent)."\r\n";
+               $this->content .= (string) trim($newContent) . "\r\n";
        }
 
        /**
        }
 
        /**
@@ -82,7 +113,7 @@ class BaseHelper extends BaseFrameworkSystem {
                $fieldValue = $this->getValueField($fieldName);
 
                // Assign it with a template variable
                $fieldValue = $this->getValueField($fieldName);
 
                // Assign it with a template variable
-               $this->getTemplateInstance()->assignVariable("block_" . $fieldName, $fieldValue);
+               $this->getTemplateInstance()->assignVariable('block_' . $fieldName, $fieldValue);
        }
 
        /**
        }
 
        /**
@@ -99,10 +130,10 @@ class BaseHelper extends BaseFrameworkSystem {
                $fieldValue = $this->getValueField($fieldName);
 
                // Now filter it through the value through the filter method
                $fieldValue = $this->getValueField($fieldName);
 
                // Now filter it through the value through the filter method
-               $filteredValue = call_user_func_array(array($this, "doFilter" . $this->convertToClassName($filterMethod)), array($fieldValue));
+               $filteredValue = call_user_func_array(array($this, 'doFilter' . $this->convertToClassName($filterMethod)), array($fieldValue));
 
                // Assign it with a template variable
 
                // Assign it with a template variable
-               $this->getTemplateInstance()->assignVariable("block_" . $fieldName, $filteredValue);
+               $this->getTemplateInstance()->assignVariable('block_' . $fieldName, $filteredValue);
        }
 
        /**
        }
 
        /**
@@ -161,6 +192,64 @@ class BaseHelper extends BaseFrameworkSystem {
        public final function getValueInstance () {
                return $this->valueInstance;
        }
        public final function getValueInstance () {
                return $this->valueInstance;
        }
+
+       /**
+        * Check wether a group was opened previously
+        *
+        * @return      $groupOpened    Wether any group was opened before
+        */
+       protected final function ifGroupOpenedPreviously () {
+               $groupOpened = (!empty($this->previousGroupId));
+               return $groupOpened;
+       }
+
+       /**
+        * Check wether a group was opened previously
+        *
+        * @return      $subGroupOpened         Wether any group was opened before
+        */
+       protected final function ifSubGroupOpenedPreviously () {
+               $subGroupOpened = (!empty($this->previousSubGroupId));
+               return $subGroupOpened;
+       }
+
+       /**
+        * Getter for previous group id
+        *
+        * @return      $previousGroupId        Id of previously opened group
+        */
+       protected final function getPreviousGroupId () {
+               return $this->previousGroupId;
+       }
+
+       /**
+        * Setter for previous group id
+        *
+        * @param       $previousGroupId        Id of previously opened group
+        * @return      void
+        */
+       protected final function setPreviousGroupId ($previousGroupId) {
+               $this->previousGroupId = (string) $previousGroupId;
+       }
+
+       /**
+        * Getter for previous sub group id
+        *
+        * @return      $previousSubGroupId     Id of previously opened sub group
+        */
+       protected final function getPreviousSubGroupId () {
+               return $this->previousSubGroupId;
+       }
+
+       /**
+        * Setter for previous sub group id
+        *
+        * @param       $previousSubGroupId     Id of previously opened sub group
+        * @return      void
+        */
+       protected final function setPreviousSubGroupId ($previousSubGroupId) {
+               $this->previousSubGroupId = (string) $previousSubGroupId;
+       }
 }
 
 // [EOF]
 }
 
 // [EOF]
index 5f1c43bfd19c71564782177db203f36b26b85fa7..48b32d838d02ca70e5b485f0c0aa9509a125b6f6 100644 (file)
@@ -35,9 +35,6 @@ class WebBlockHelper extends BaseWebHelper implements HelpableTemplate {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A helper for generating web blocks");
        }
 
        /**
        }
 
        /**
index 12c01b8d72e9acd4c6389a77c6039f3a9a1b66ed..d167768878bed59912c5e98324eb994ace2167f8 100644 (file)
@@ -33,26 +33,6 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         */
        private $formName = "";
 
         */
        private $formName = "";
 
-       /**
-        * Wether the group is opened or not
-        */
-       private $groupOpened = false;
-
-       /**
-        * Wether the sub group is opened or not
-        */
-       private $subGroupOpened = false;
-
-       /**
-        * Name of the group
-        */
-       private $groupName = "";
-
-       /**
-        * Name of the sub group
-        */
-       private $subGroupName = "";
-
        /**
         * Wether form tag is enabled (default: true)
         */
        /**
         * Wether form tag is enabled (default: true)
         */
@@ -72,12 +52,6 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Helper class for HTML forms");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
@@ -104,6 +78,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
 
                // Set form name
                $helperInstance->setFormName($formName);
 
                // Set form name
                $helperInstance->setFormName($formName);
+
                // A form-less field may say "false" here...
                if ($withForm === true) {
                        // Create the form
                // A form-less field may say "false" here...
                if ($withForm === true) {
                        // Create the form
@@ -162,7 +137,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                        $this->addInputHiddenField('form', $this->getFormName());
 
                        // Is a group open?
                        $this->addInputHiddenField('form', $this->getFormName());
 
                        // Is a group open?
-                       if ($this->groupOpened === true) {
+                       if ($this->ifGroupOpenedPreviously()) {
                                // Then automatically close it here
                                $this->addFormGroup();
                        } // END - if
                                // Then automatically close it here
                                $this->addFormGroup();
                        } // END - if
@@ -221,8 +196,8 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         * Add a password input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
         * Add a password input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
-        * @param       $fieldName                      Input field name
-        * @param       $fieldValue                     Input default value (default: empty)
+        * @param       $fieldName              Input field name
+        * @param       $fieldValue             Input default value (default: empty)
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
@@ -248,8 +223,8 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         * Add a hidden input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
         * Add a hidden input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
-        * @param       $fieldName                      Input field name
-        * @param       $fieldValue                     Input default value (default: empty)
+        * @param       $fieldName              Input field name
+        * @param       $fieldValue             Input default value (default: empty)
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
@@ -305,8 +280,8 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         * Add a checkbox input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
         * Add a checkbox input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
-        * @param       $fieldName                      Input field name
-        * @param       $fieldChecked           Wether the field is checked (defaut: checked)
+        * @param       $fieldName              Input field name
+        * @param       $fieldChecked   Wether the field is checked (defaut: checked)
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
@@ -361,7 +336,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         * Add a reset input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
         * Add a reset input tag to the form or throw an exception if it is not
         * yet opened. The field's name will be set as id.
         *
-        * @param       $buttonText                     Text displayed on the button
+        * @param       $buttonText             Text displayed on the button
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
         * @return      void
         * @throws      FormClosedException             If the form is not yet opened
         */
@@ -386,30 +361,30 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
        /**
         * Add a form group or close an already opened and open a new one
         *
        /**
         * Add a form group or close an already opened and open a new one
         *
-        * @param       $groupName      Name of the group or last opened if empty
+        * @param       $groupId        Name of the group or last opened if empty
         * @param       $groupText      Text including HTML to show above this group
         * @return      void
         * @throws      FormClosedException             If no form has been opened before
         * @param       $groupText      Text including HTML to show above this group
         * @return      void
         * @throws      FormClosedException             If no form has been opened before
-        * @throws      EmptyVariableException  If $groupName is not set
+        * @throws      EmptyVariableException  If $groupId is not set
         */
         */
-       public function addFormGroup ($groupName = "", $groupText = "") {
+       public function addFormGroup ($groupId = "", $groupText = "") {
                // Is a form opened?
                if (($this->formOpened === false) && ($this->formEnabled === true)) {
                        // Throw exception here
                // Is a form opened?
                if (($this->formOpened === false) && ($this->formEnabled === true)) {
                        // Throw exception here
-                       throw new FormClosedException(array($this, $groupName), self::EXCEPTION_CLOSED_FORM);
+                       throw new FormClosedException(array($this, $groupId), self::EXCEPTION_CLOSED_FORM);
                } // END - if
 
                // At least the group name should be set
                } // END - if
 
                // At least the group name should be set
-               if ((empty($groupName)) && ($this->groupOpened === false)) {
+               if ((empty($groupId)) && (!$this->ifGroupOpenedPreviously())) {
                        // Throw exception here
                        // Throw exception here
-                       throw new EmptyVariableException(array($this, 'groupName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
-               } elseif (empty($groupName)) {
+                       throw new EmptyVariableException(array($this, 'groupId'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
+               } elseif (empty($groupId)) {
                        // Close the last opened
                        // Close the last opened
-                       $groupName = $this->groupName;
+                       $groupId = $this->getPreviousGroupId();
                }
 
                // Same group to open?
                }
 
                // Same group to open?
-               if (($this->groupOpened === false) && ($groupName == $this->groupName)) {
+               if ((!$this->ifGroupOpenedPreviously()) && ($groupId == $this->getPreviousGroupId())) {
                        // Abort here silently
                        return false;
                } // END - if
                        // Abort here silently
                        return false;
                } // END - if
@@ -418,7 +393,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                $content = "    </div>\n</div><!-- Group - CLOSE //-->";
 
                // Is this group opened?
                $content = "    </div>\n</div><!-- Group - CLOSE //-->";
 
                // Is this group opened?
-               if ($this->groupOpened === false) {
+               if (!$this->ifGroupOpenedPreviously()) {
                        // Begin the div/span blocks
                        $content = sprintf("<!-- Group %s - OPEN //-->
 <div class=\"group_box\" id=\"%s_group_box\">
                        // Begin the div/span blocks
                        $content = sprintf("<!-- Group %s - OPEN //-->
 <div class=\"group_box\" id=\"%s_group_box\">
@@ -426,35 +401,28 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                %s
        </span>
        <div class=\"group_field\" id=\"%s_group_field\">",
                %s
        </span>
        <div class=\"group_field\" id=\"%s_group_field\">",
-                               $groupName,
-                               $groupName,
-                               $groupName,
+                               $groupId,
+                               $groupId,
+                               $groupId,
                                $groupText,
                                $groupText,
-                               $groupName
+                               $groupId
                        );
 
                        );
 
-                       // Add the content
-                       $this->addContent($content);
-
                        // Switch the state
                        // Switch the state
-                       $this->groupName = $groupName;
-                       $this->groupOpened = true;
+                       $this->openGroupByIdContent($groupId, $content);
                } else {
                        // Is a sub group opened?
                } else {
                        // Is a sub group opened?
-                       if ($this->subGroupOpened === true) {
+                       if ($this->ifSubGroupOpenedPreviously()) {
                                // Close it here
                                $this->addFormSubGroup();
                        } // END - if
 
                                // Close it here
                                $this->addFormSubGroup();
                        } // END - if
 
-                       // Add the content
-                       $this->addContent($content);
-
                        // Switch the state
                        // Switch the state
-                       $this->groupOpened = false;
+                       $this->closePreviousGroupByContent($content);
 
                        // All call it again if the group name is not empty
 
                        // All call it again if the group name is not empty
-                       if (!empty($groupName)) {
-                               $this->addFormGroup($groupName, $groupText);
+                       if (!empty($groupId)) {
+                               $this->addFormGroup($groupId, $groupText);
                        } // END - if
                }
        }
                        } // END - if
                }
        }
@@ -464,30 +432,30 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
         * throws an exception if no group has been opened before or if the sub
         * group name is empty.
         *
         * throws an exception if no group has been opened before or if the sub
         * group name is empty.
         *
-        * @param       $subGroupName   Name of the group or last opened if empty
+        * @param       $subGroupId             Name of the group or last opened if empty
         * @param       $subGroupText   Text including HTML to show above this group
         * @return      void
         * @param       $subGroupText   Text including HTML to show above this group
         * @return      void
-        * @throws      FormGroupClosedException        If no group has been opened before
-        * @throws      EmptyVariableException          If $subGroupName is not set
+        * @throws      FormFormClosedException         If no group has been opened before
+        * @throws      EmptyVariableException          If $subGroupId is not set
         */
         */
-       public function addFormSubGroup ($subGroupName = "", $subGroupText = "") {
+       public function addFormSubGroup ($subGroupId = "", $subGroupText = "") {
                // Is a group opened?
                // Is a group opened?
-               if ($this->groupOpened === false) {
+               if (!$this->ifGroupOpenedPreviously()) {
                        // Throw exception here
                        // Throw exception here
-                       throw new FormGroupClosedException(array($this, $subGroupName), self::EXCEPTION_UNEXPECTED_CLOSED_GROUP);
+                       throw new FormFormClosedException(array($this, $subGroupId), self::EXCEPTION_UNEXPECTED_CLOSED_GROUP);
                } // END - if
 
                // At least the sub group name should be set
                } // END - if
 
                // At least the sub group name should be set
-               if ((empty($subGroupName)) && ($this->subGroupOpened === false)) {
+               if ((empty($subGroupId)) && (!$this->ifSubGroupOpenedPreviously())) {
                        // Throw exception here
                        // Throw exception here
-                       throw new EmptyVariableException(array($this, 'groupName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
-               } elseif (empty($subGroupName)) {
+                       throw new EmptyVariableException(array($this, 'subGroupId'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
+               } elseif (empty($subGroupId)) {
                        // Close the last opened
                        // Close the last opened
-                       $subGroupName = $this->subGroupName;
+                       $subGroupId = $this->getSubGroupId();
                }
 
                // Same sub group to open?
                }
 
                // Same sub group to open?
-               if (($this->subGroupOpened === false) && ($subGroupName == $this->subGroupName)) {
+               if ((!$this->ifSubGroupOpenedPreviously()) && ($subGroupId == $this->getSubGroupId())) {
                        // Abort here silently
                        return false;
                } // END - if
                        // Abort here silently
                        return false;
                } // END - if
@@ -496,7 +464,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                $content = "    </div>\n</div><!-- Sub group- CLOSE //-->";
 
                // Is this group opened?
                $content = "    </div>\n</div><!-- Sub group- CLOSE //-->";
 
                // Is this group opened?
-               if ($this->subGroupOpened === false) {
+               if (!$this->ifSubGroupOpenedPreviously()) {
                        // Begin the span block
                        $content = sprintf("<!-- Sub group %s - OPEN //-->
 <div class=\"subgroup_box\" id=\"%s_subgroup_box\">
                        // Begin the span block
                        $content = sprintf("<!-- Sub group %s - OPEN //-->
 <div class=\"subgroup_box\" id=\"%s_subgroup_box\">
@@ -504,29 +472,22 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                %s
        </span>
        <div class=\"subgroup_field\" id=\"%s_subgroup_field\">",
                %s
        </span>
        <div class=\"subgroup_field\" id=\"%s_subgroup_field\">",
-                               $subGroupName,
-                               $subGroupName,
-                               $subGroupName,
+                               $subGroupId,
+                               $subGroupId,
+                               $subGroupId,
                                $subGroupText,
                                $subGroupText,
-                               $subGroupName
+                               $subGroupId
                        );
 
                        );
 
-                       // Add the content
-                       $this->addContent($content);
-
                        // Switch the state and remeber the name
                        // Switch the state and remeber the name
-                       $this->subGroupOpened = true;
-                       $this->subGroupName = $subGroupName;
+                       $this->openSubGroupByIdContent($subGroupId, $content);
                } else {
                } else {
-                       // Add the content
-                       $this->addContent($content);
-
                        // Switch the state
                        // Switch the state
-                       $this->subGroupOpened = false;
+                       $this->closePreviousSubGroupByContent($content);
 
                        // All call it again if sub group name is not empty
 
                        // All call it again if sub group name is not empty
-                       if (!empty($subGroupName)) {
-                               $this->addFormSubGroup($subGroupName, $subGroupText);
+                       if (!empty($subGroupId)) {
+                               $this->addFormSubGroup($subGroupId, $subGroupText);
                        } // END - if
                }
        }
                        } // END - if
                }
        }
@@ -549,7 +510,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
 
                // Set the block type
                $block = "div";
 
                // Set the block type
                $block = "div";
-               if ($this->groupOpened === true) $block = "span";
+               if ($this->ifGroupOpenedPreviously()) $block = "span";
 
                // Generate the content
                $inputContent = sprintf("       <%s id=\"%s_text\">
 
                // Generate the content
                $inputContent = sprintf("       <%s id=\"%s_text\">
@@ -582,7 +543,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                } // END - if
 
                // Is a group open?
                } // END - if
 
                // Is a group open?
-               if ($this->groupOpened === true) {
+               if ($this->ifGroupOpenedPreviously()) {
                        // Then automatically close it here
                        $this->addFormGroup();
                } // END - if
                        // Then automatically close it here
                        $this->addFormGroup();
                } // END - if
@@ -629,7 +590,7 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                $extraInstance = Registry::getRegistry()->getInstance('extra');
 
                // Get a configured instance
                $extraInstance = Registry::getRegistry()->getInstance('extra');
 
                // Get a configured instance
-               $captchaInstance = ObjectFactory::createObjectByConfiguredName($this->getFormName()."_captcha", array($this, $extraInstance));
+               $captchaInstance = ObjectFactory::createObjectByConfiguredName($this->getFormName().'_captcha', array($this, $extraInstance));
 
                // Initiate the CAPTCHA
                $captchaInstance->initiateCaptcha();
 
                // Initiate the CAPTCHA
                $captchaInstance->initiateCaptcha();
@@ -693,10 +654,10 @@ class WebFormHelper extends BaseWebHelper implements HelpableTemplate {
                        // Close the form automatically
                        $this->addFormTag();
                } elseif ($this->formEnabled === false) {
                        // Close the form automatically
                        $this->addFormTag();
                } elseif ($this->formEnabled === false) {
-                       if ($this->subGroupOpened === true) {
+                       if ($this->ifSubGroupOpenedPreviously()) {
                                // Close sub group
                                $this->addFormSubGroup();
                                // Close sub group
                                $this->addFormSubGroup();
-                       } elseif ($this->groupOpened === true) {
+                       } elseif ($this->ifGroupOpenedPreviously()) {
                                // Close group
                                $this->addFormGroup();
                        }
                                // Close group
                                $this->addFormGroup();
                        }
index 4121cd2a2cdce5f9c0f9eb74e39e1292b2168292..f90636757aacf41bc76772cb20c107b02b9a6a69 100644 (file)
@@ -35,9 +35,6 @@ class WebLinkHelper extends BaseWebHelper implements HelpableTemplate {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A helper for generating web links");
        }
 
        /**
        }
 
        /**
@@ -84,9 +81,45 @@ class WebLinkHelper extends BaseWebHelper implements HelpableTemplate {
         * Flush the content out,e g. to a template variable
         *
         * @return      void
         * Flush the content out,e g. to a template variable
         *
         * @return      void
+        * @todo        Completely unimplemented
         */
        public function flushContent () {
         */
        public function flushContent () {
-               $this->partialStub("Please implement this method.");
+               // Needed to be implemented!
+       }
+
+       /**
+        * Adds a link group (like the form group is) with some raw language to the
+        * helper.
+        *
+        * @param       $groupId        Id string of the group
+        * @param       $groupText      Text for this group to add
+        * @return      void
+        */
+       public function addLinkGroup ($groupId, $groupText) {
+               // Is a group with that name open?
+               if ($this->ifGroupIsOpened($groupId)) {
+                       // Then close it here
+                       $this->closeGroupById($groupId);
+               } else {
+                       // Open the new group
+                       $this->openGroupByIdText($groupId, $groupText);
+               }
+       }
+
+       /**
+        * Adds text (note) to the previously opened group or throws an exception
+        * if no previous group was opened.
+        *
+        * @param       $groupNote      Note to be added to a group
+        * @return      void
+        * @throws      NoGroupOpenedException  If no previous group was opened
+        */
+       public function addLinkNote ($groupNote) {
+               // Check if a previous group was opened
+               if (!$this->ifGroupOpenedPreviously()) {
+                       // No group was opened before!
+                       throw new NoGroupOpenedException(array($this, $groupNote), self::EXCEPTION_GROUP_NOT_OPENED);
+               }
        }
 }
 
        }
 }
 
index 989f5462e877b04e1fc7a2de374427f4d0515801..69b410054e73403edbc46d507696a7bbae8d75d8 100644 (file)
@@ -30,12 +30,6 @@ class ???Image extends BaseImage {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index fe282253895abfcb0f98cc8eddea9e33da511a34..f8ee28b8f5b3a28f6d6c982edc5f7e78cdc3aa0b 100644 (file)
@@ -30,12 +30,6 @@ class PngImage extends BaseImage {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("PNG image");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 4c97338ac60a5f130c8ac3f202425d709602db23..7e257be47de862745dc7ce7ca2d6d3f1e557183e 100644 (file)
@@ -29,12 +29,6 @@ class FileIoStream extends BaseFrameworkSystem implements FileInputStreamer, Fil
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Universal file I/O stream system");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
                // Clean-up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean-up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index fbfebc0906153eedb8dde6a8ec6cf9b46febb11f..e19b0675bee732ca2deb47affbe8f8990404a4e6 100644 (file)
@@ -39,14 +39,9 @@ class FrameworkDirectoryPointer extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Helper for handling directories");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
                // Clean-up a little
                $this->removeNumberFormaters();
                // Clean-up a little
                $this->removeNumberFormaters();
+               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 4cefaaf34d222bbbdba43e81e885890d14526001..172c02f700c366475b4d51eb89a53c1c5ef180aa 100644 (file)
@@ -41,14 +41,9 @@ class FrameworkFileInputPointer extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Handler for reading from files");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
                // Clean-up a little
                $this->removeNumberFormaters();
                // Clean-up a little
                $this->removeNumberFormaters();
+               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index e1964503322e8c50c3451da2d28b4e052b452307..37c2285ead758a95e3dbebcd3e8cc3c167c754f5 100644 (file)
@@ -39,14 +39,9 @@ class FrameworkFileOutputPointer extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Handler for writing to files");
-
-               // Create unique ID
-               $this->generateUniqueId();
-
                // Clean-up a little
                $this->removeNumberFormaters();
                // Clean-up a little
                $this->removeNumberFormaters();
+               $this->removeSystemArray();
        }
 
        /**
        }
 
        /**
index 491f5fda40e44dfdcb0a8527a5919a817d00809c..befccdb1414a132c9a7dbc30dc3a8efef6617cb6 100644 (file)
@@ -52,12 +52,6 @@ class LanguageSystem extends BaseFrameworkSystem implements ManageableLanguage {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Language sub-system");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index d1bbd5383dff221648605a43fec6dc99ec726f67..b3181c54a00df763c9c0a91356bd6bc7b0b2208a 100644 (file)
@@ -30,12 +30,6 @@ class ???Mailer extends BaseMailer implements DeliverableMail {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 171c56514a333cd69e68ad7de13a12bcfe878a63..ffc3fc6ea81bd5eb17ff5fdfcc81e5108771f222 100644 (file)
@@ -31,12 +31,6 @@ class DebugMailer extends BaseMailer implements DeliverableMail {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("A mailer for debugging purposes");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index ff2ad10cfad4f6a8fe867a39bdbe82ccfa3ad4f5..b1cae5c408f77eee0c7816b72f768ed2720f54c0 100644 (file)
@@ -41,12 +41,6 @@ class ConsoleOutput extends BaseFrameworkSystem implements OutputStreamer {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Console output class");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index d6419cf87f49338569d26fd17ee50977f5b7d70e..7a508058ddd1cc90acd210e9b8f0f82b80cbf612 100644 (file)
@@ -36,12 +36,6 @@ class WebOutput extends BaseFrameworkSystem implements OutputStreamer, Registera
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Class for web output e.g. XHTML code");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 7a2aa2010fdbe07fd815929b9ae2362b17d9c53b..6a9d88f172e03ff9b98df8b7c989b9833cc22264 100644 (file)
@@ -31,12 +31,6 @@ class UserPoints extends BaseFrameworkSystem implements Registerable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Class for handling user points");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index ef423cac72df886729d4751082c8b8a24a61c48f..4e5dbb10573b4548d617b4100cdf478ec3c19811 100644 (file)
@@ -31,12 +31,6 @@ class DefaultNewsReader extends BaseFrameworkSystem implements ReadableNews, Reg
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Default news reader");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index f7d385fb62efc6c60b8a6c701dcdba56bca9d648..2ca0382d328a447891e68a4ff7295ef6606bed2a 100644 (file)
@@ -46,12 +46,6 @@ class Registry extends BaseFrameworkSystem implements Register {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Registry class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 31047925e7f1243561a428a5e39824af27974486..a046f185c689e055a03a777f26e0cd3a566659fb 100644 (file)
@@ -43,12 +43,6 @@ class HttpRequest extends BaseFrameworkSystem implements Requestable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("HTTP request");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 664f1f07d417249769b3e3c33b403e4c4cfccfdc..83f5ddd772dd573c3b2e6389debaf90079ea36ca 100644 (file)
@@ -36,12 +36,6 @@ class WebActionResolver extends BaseActionResolver implements ActionResolver {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Resolver for local web actions");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Set prefix to "Web"
                $this->setActionPrefix("Web");
        }
                // Set prefix to "Web"
                $this->setActionPrefix("Web");
        }
index 0bb1dd51048fdbf3a146e2e9cd38b73ea6aa79c4..ed8492c75ae8ba49e57021a1f755f053b97e8be4 100644 (file)
@@ -36,12 +36,6 @@ class ImageCommandResolver extends BaseCommandResolver implements CommandResolve
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Resolver for local image commands");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Set prefix to "Image"
                $this->setCommandPrefix("Image");
        }
                // Set prefix to "Image"
                $this->setCommandPrefix("Image");
        }
index 7b3388ab6f0a593a02fd07a07735ea02cd19b785..165d2f788cf2c1251fc2e2d4614b8c9639931606 100644 (file)
@@ -36,12 +36,6 @@ class WebCommandResolver extends BaseCommandResolver implements CommandResolver
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Resolver for local web commands");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Set prefix to "Web"
                $this->setCommandPrefix("Web");
        }
                // Set prefix to "Web"
                $this->setCommandPrefix("Web");
        }
index c10a4c6513b14a91e5325fe038896306a16b16f6..157a98c60f5f16fc1bb040b1d6d024c184cb9526 100644 (file)
@@ -41,12 +41,6 @@ class ImageControllerResolver extends BaseControllerResolver implements Controll
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Resolver for local web controllers");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Set prefix to "Image"
                $this->setControllerPrefix("Image");
        }
                // Set prefix to "Image"
                $this->setControllerPrefix("Image");
        }
index a2f11e2e7ef2dd5c313cda5b8f380367538197c3..2446e6dc776b885ea3d370ff63c77b7cecb1cb79 100644 (file)
@@ -41,12 +41,6 @@ class WebControllerResolver extends BaseControllerResolver implements Controller
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Resolver for local web controllers");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Set prefix to "Web"
                $this->setControllerPrefix("Web");
        }
                // Set prefix to "Web"
                $this->setControllerPrefix("Web");
        }
index 6882981c605b086087fc4671a81357691905c590..869d358a49acbb44537dbaf09325b7afbdfd3471 100644 (file)
@@ -64,12 +64,6 @@ class HttpResponse extends BaseFrameworkSystem implements Responseable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("HTTP response");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 7112907b855771d521da1e465aed5681d0c946e9..2329af7f3931eb038edc2eee04ddc4fcaa709b41 100644 (file)
@@ -64,12 +64,6 @@ class ImageResponse extends BaseFrameworkSystem implements Responseable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("HTTP response");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
index 45412dc90f34ea45191e114f2bc7c906dca755c9..694f13aca7bb5e9f28e18a05b3ebc4ae591a095a 100644 (file)
@@ -60,12 +60,6 @@ class DatabaseResult extends BaseFrameworkSystem implements SearchableResult, Up
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set part description
-               $this->setObjectDescription("Database result");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
@@ -129,14 +123,11 @@ class DatabaseResult extends BaseFrameworkSystem implements SearchableResult, Up
                $nextValid = false;
 
                // Is the result valid?
                $nextValid = false;
 
                // Is the result valid?
-               if ($this->resultArray['status'] === "ok") {
-                       // The status is fine so let's have a look for the next entry
-                       if ($this->valid()) {
-                               // Next entry found, so count one up and cache it
-                               $this->currentPos++;
-                               $this->currentRow = $this->resultArray['rows'][$this->currentPos];
-                               $nextValid = true;
-                       } // END - if
+               if ($this->valid()) {
+                       // Next entry found, so count one up and cache it
+                       $this->currentPos++;
+                       $this->currentRow = $this->resultArray['rows'][$this->currentPos];
+                       $nextValid = true;
                } // END - if
 
                // Return the result
                } // END - if
 
                // Return the result
@@ -189,7 +180,7 @@ class DatabaseResult extends BaseFrameworkSystem implements SearchableResult, Up
                $isValid = false;
 
                // Check if 
                $isValid = false;
 
                // Check if 
-               if ((isset($this->resultArray['rows'][($this->currentPos + 1)])) && (isset($this->resultArray['rows'][0]))) {
+               if (($this->ifStatusIsOkay()) && (isset($this->resultArray['rows'][($this->currentPos + 1)])) && (isset($this->resultArray['rows'][0]))) {
                        // All fine!
                        $isValid = true;
                } // END - if
                        // All fine!
                        $isValid = true;
                } // END - if
@@ -198,6 +189,15 @@ class DatabaseResult extends BaseFrameworkSystem implements SearchableResult, Up
                return $isValid;
        }
 
                return $isValid;
        }
 
+       /**
+        * Determines wether the status of the query was fine ("ok")
+        *
+        * @return      $ifStatusOkay   Wether the status of the query was okay
+        */
+       public function ifStatusIsOkay () {
+               return ((isset($this->resultArray['status'])) && ($this->resultArray['status'] === "ok"));
+       }
+
        /**
         * Gets the current key of iteration
         *
        /**
         * Gets the current key of iteration
         *
index 89a887d81309c6db41a2dfb00752feb5bbed6667..93ba3988ed0ae28fa27f7aca7beec7b64a592724 100644 (file)
@@ -57,12 +57,6 @@ class RandomNumberGenerator extends BaseFrameworkSystem {
                // Call parent constructor
                parent::__construct($className);
 
                // Call parent constructor
                parent::__construct($className);
 
-               // Set part description
-               $this->setObjectDescription("Standard random number generator");
-
-               // Create unique ID number
-               $this->generateUniqueId();
-
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
                // Clean up a little
                $this->removeNumberFormaters();
                $this->removeSystemArray();
@@ -115,7 +109,7 @@ class RandomNumberGenerator extends BaseFrameworkSystem {
                // Yet-another fixed salt. This is not dependend on server software or date
                if ($extraInstance instanceof FrameworkInterface) {
                        // With extra instance information
                // Yet-another fixed salt. This is not dependend on server software or date
                if ($extraInstance instanceof FrameworkInterface) {
                        // With extra instance information
-                       $this->fixedSalt = sha1($serverIp . ":" . $extraInstance->__toString() . ":" . serialize($this->getDatabaseInstance()->getConnectionData()) . ":" . $extraInstance->getObjectDescription());
+                       $this->fixedSalt = sha1($serverIp . ":" . $extraInstance->__toString() . ":" . serialize($this->getDatabaseInstance()->getConnectionData()));
                } else {
                        // Without extra information
                        $this->fixedSalt = sha1($serverIp . ":" . serialize($this->getDatabaseInstance()->getConnectionData()));
                } else {
                        // Without extra information
                        $this->fixedSalt = sha1($serverIp . ":" . serialize($this->getDatabaseInstance()->getConnectionData()));
index eeb62edd5a5a65e5ce156fb88297d06b8fb4abe0..210002ffe9dd04119b6b200b532a4d112c857b70 100644 (file)
@@ -50,12 +50,6 @@ class ImageTemplateEngine extends BaseTemplateEngine implements CompileableTempl
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Image template engine");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 84a24f4a62af9dd6c8efb6f22d5e65b0d74764b1..948dd60970e27126234a89831d2c69e9becc98bf 100644 (file)
@@ -50,12 +50,6 @@ class MailTemplateEngine extends BaseTemplateEngine implements CompileableTempla
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Mail template engine");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index f4cb42ea42c924892e7f3709789483db9659afab..d166f9f0191ca14e0ccfbe2b43711a16ad6c9348 100644 (file)
@@ -31,12 +31,6 @@ class WebTemplateEngine extends BaseTemplateEngine implements CompileableTemplat
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Web template engine");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 7aed6242d28329d7caee420b25cfb4dc61cd5d7d..84405dc47a9ba8fcb7daf77d6eb579b1c1eb71bf 100644 (file)
@@ -35,12 +35,6 @@ class Guest extends BaseUser implements ManageableGuest, Registerable {
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Generic guest class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index b523f50c79a19d8058215d5882f8f2c9cb37a274..cdb98c1b9220add8880531b429f3375176ab8b01 100644 (file)
@@ -30,12 +30,6 @@ class Member extends BaseUser implements ManageableMember, Registerable, Updatea
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set part description
-               $this->setObjectDescription("Generic user class");
-
-               // Create unique ID number
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 4f02144798f1cc97a2ba3a128b553b646187b3e5..266cf6facd10b54b5bc1f88a78ab0f7b4011529d 100644 (file)
@@ -35,12 +35,6 @@ class CompressorChannel extends BaseMiddleware implements Registerable {
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
        protected function __construct () {
                // Call parent constructor!
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Komprimierungshandler");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        /**
        }
 
        /**
index 736ece5e8cbb3ac68138c290dedbbb759f62e487..1d9fe9b43e45671eb24ed75597b79d134debb52a 100644 (file)
@@ -46,12 +46,6 @@ class DatabaseConnection extends BaseMiddleware implements DatabaseConnector, Re
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
        protected function __construct() {
                // Call parent constructor
                parent::__construct(__CLASS__);
-
-               // Set description
-               $this->setObjectDescription("Datenbank-Mittelschicht");
-
-               // Create an unique ID
-               $this->generateUniqueId();
        }
 
        // Create new database connection layer
        }
 
        // Create new database connection layer
index 6e53821ea045fb23f9530588ebe4dd45bbf55ee3..8ee7e08375efffb416b7efe98c3d13ea235b8134 100644 (file)
@@ -43,12 +43,6 @@ class DebugMiddleware extends BaseMiddleware implements Registerable {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Debug-Ausgabe-Instance");
-
-               // Create an unique ID
-               $this->generateUniqueId();
-
                // Set own instance
                self::$thisInstance = $this;
        }
                // Set own instance
                self::$thisInstance = $this;
        }
index f1d85e65261431281b8439738d7177385961e151..db5797907f85a8dfb43ebcbfc649ebbb5dd0abc0 100644 (file)
@@ -47,12 +47,6 @@ class FileIoHandler extends BaseMiddleware {
                // Call parent constructor
                parent::__construct(__CLASS__);
 
                // Call parent constructor
                parent::__construct(__CLASS__);
 
-               // Set description
-               $this->setObjectDescription("Datei-Ein-/Ausgabe-Handler");
-
-               // Create an unique ID
-               $this->generateUniqueId();
-
                // Set own instance
                self::$thisInstance = $this;
        }
                // Set own instance
                self::$thisInstance = $this;
        }
index e49f94b9bce342cbd9d0bc08ef0eea70db42c380..4c739507448a53cf20f9560a624a52a63c294fa8 100644 (file)
@@ -284,5 +284,8 @@ $cfg->setConfigEntry('crypt_fixed_salt', "N");
 // CFG: DB-UPDATE-PRIMARY-FORCED
 $cfg->setConfigEntry('db_update_primary_forced', "Y");
 
 // CFG: DB-UPDATE-PRIMARY-FORCED
 $cfg->setConfigEntry('db_update_primary_forced', "Y");
 
+// CFG: GERMAN-DATE-TIME
+$cfg->setConfigEntry('german_date_time', "%3\$s.%2\$s.%1\$s, %4\$s:%5\$s:%6\$s");
+
 // [EOF]
 ?>
 // [EOF]
 ?>
index 4dc471418f4d6f54023527eb275a972fe3cc1c5b..ec1462d389ee52ab96017d35db3c8a11b3095352 100755 (executable)
@@ -1,12 +1,11 @@
 #!/bin/sh
 
 #!/bin/sh
 
-echo "$0: Cleaning up..."
-rm -f shipsimu_dev*.zip
+sh ./clear-cache.sh
 
 echo "$0: Packaging..."
 zip -9 shipsimu_dev.zip docs/* Doxyfile *.php *.sh > /dev/null 2>&1
 zip -9r shipsimu_dev.zip application/ db/ devel/ Doxyfile inc/ templates/ tests/ > /dev/null 2>&1
 
 echo "$0: Packaging..."
 zip -9 shipsimu_dev.zip docs/* Doxyfile *.php *.sh > /dev/null 2>&1
 zip -9r shipsimu_dev.zip application/ db/ devel/ Doxyfile inc/ templates/ tests/ > /dev/null 2>&1
-zip -d shipsimu_dev.zip docs/warn.log db/user/*.serialized templates/images/_cache/*.png application/ship-simu/templates/images/_cache/*.png > /dev/null 2>&1
+zip -d shipsimu_dev.zip docs/warn.log db/*/*.serialized > /dev/null 2>&1
 
 echo "$0: Renaming..."
 mv shipsimu_dev.zip shipsimu_dev_`date +%Y%m%d_%H%M%S`.zip
 
 echo "$0: Renaming..."
 mv shipsimu_dev.zip shipsimu_dev_`date +%Y%m%d_%H%M%S`.zip