]> git.mxchange.org Git - shipsimu.git/commitdiff
Renamed 'ship-simu' to 'shipsimu' + added 'core' and symlink to core/inc
authorRoland Haeder <roland@mxchange.org>
Sun, 22 Mar 2015 20:21:22 +0000 (21:21 +0100)
committerRoland Haeder <roland@mxchange.org>
Sun, 22 Mar 2015 20:21:22 +0000 (21:21 +0100)
Signed-off-by: Roland Haeder <roland@mxchange.org>
655 files changed:
.gitmodules [new file with mode: 0644]
application/ship-simu/.htaccess [deleted file]
application/ship-simu/admin/.htaccess [deleted file]
application/ship-simu/class_ApplicationHelper.php [deleted file]
application/ship-simu/config.php [deleted file]
application/ship-simu/data.php [deleted file]
application/ship-simu/debug.php [deleted file]
application/ship-simu/exceptions.php [deleted file]
application/ship-simu/exceptions/.htaccess [deleted file]
application/ship-simu/exceptions/class_BirthdayInvalidException.php [deleted file]
application/ship-simu/exceptions/class_CabinShipMismatchException.php [deleted file]
application/ship-simu/exceptions/class_ContractAllreadySignedException.php [deleted file]
application/ship-simu/exceptions/class_ContractPartnerMismatchException.php [deleted file]
application/ship-simu/exceptions/class_DeckShipMismatchException.php [deleted file]
application/ship-simu/exceptions/class_EmptyStructuresListException.php [deleted file]
application/ship-simu/exceptions/class_InvalidContractPartnerException.php [deleted file]
application/ship-simu/exceptions/class_InvalidIDFormatException.php [deleted file]
application/ship-simu/exceptions/class_ItemNotInPriceListException.php [deleted file]
application/ship-simu/exceptions/class_ItemNotTradeableException.php [deleted file]
application/ship-simu/exceptions/class_MissingSimulatorIdException.php [deleted file]
application/ship-simu/exceptions/class_MotorShipMismatchException.php [deleted file]
application/ship-simu/exceptions/class_NoShippingCompanyOwnedException.php [deleted file]
application/ship-simu/exceptions/class_NoShipyardsConstructedException.php [deleted file]
application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php [deleted file]
application/ship-simu/exceptions/class_RoomShipMismatchException.php [deleted file]
application/ship-simu/exceptions/class_ShipNotConstructedException.php [deleted file]
application/ship-simu/exceptions/class_ShipPartNotConstructableException.php [deleted file]
application/ship-simu/exceptions/class_StructureShipMismatchException.php [deleted file]
application/ship-simu/exceptions/class_StructuresOutOfBoundsException.php [deleted file]
application/ship-simu/exceptions/class_ToMuchEmployeesException.php [deleted file]
application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php [deleted file]
application/ship-simu/exceptions/class_UnsupportedLimitationPartException.php [deleted file]
application/ship-simu/exceptions/class_WrongGenderSpecifiedException.php [deleted file]
application/ship-simu/init.php [deleted file]
application/ship-simu/interfaces/.htaccess [deleted file]
application/ship-simu/interfaces/class_BookableAccount.php [deleted file]
application/ship-simu/interfaces/class_ConstructableShip.php [deleted file]
application/ship-simu/interfaces/class_ConstructableShipPart.php [deleted file]
application/ship-simu/interfaces/class_ContractPartner.php [deleted file]
application/ship-simu/interfaces/class_Customer.php [deleted file]
application/ship-simu/interfaces/class_Personellizer.php [deleted file]
application/ship-simu/interfaces/class_SignableContract.php [deleted file]
application/ship-simu/interfaces/class_TradeableItem.php [deleted file]
application/ship-simu/loader.php [deleted file]
application/ship-simu/main/.htaccess [deleted file]
application/ship-simu/main/actions/.htaccess [deleted file]
application/ship-simu/main/actions/class_ [deleted file]
application/ship-simu/main/actions/class_BaseShipSimuAction.php [deleted file]
application/ship-simu/main/actions/ship-simu/.htaccess [deleted file]
application/ship-simu/main/actions/ship-simu/class_ShipSimuLoginAction.php [deleted file]
application/ship-simu/main/actions/ship-simu/class_ShipSimuProfileAction.php [deleted file]
application/ship-simu/main/actions/web/.htaccess [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLogin [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginCompanyAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginLogoutAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginProfileAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginRefillAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php [deleted file]
application/ship-simu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php [deleted file]
application/ship-simu/main/bank/.htaccess [deleted file]
application/ship-simu/main/bank/class_BaseBank.php [deleted file]
application/ship-simu/main/bank/money/class_MoneyBank.php [deleted file]
application/ship-simu/main/class_ [deleted file]
application/ship-simu/main/class_BasePersonell.php [deleted file]
application/ship-simu/main/class_BaseSimulator.php [deleted file]
application/ship-simu/main/class_Merchant.php [deleted file]
application/ship-simu/main/class_WorksContract.php [deleted file]
application/ship-simu/main/commands/.htaccess [deleted file]
application/ship-simu/main/commands/web/.htaccess [deleted file]
application/ship-simu/main/commands/web/class_WebShipsimuGuestLoginCommand.php [deleted file]
application/ship-simu/main/commands/web/class_WebShipsimuProfileCommand.php [deleted file]
application/ship-simu/main/commands/web/class_WebShipsimuRefillCommand.php [deleted file]
application/ship-simu/main/commands/web/class_WebShipsimuRegisterCommand.php [deleted file]
application/ship-simu/main/commands/web/class_WebShipsimuUserLoginCommand.php [deleted file]
application/ship-simu/main/commands/web/company/.htaccess [deleted file]
application/ship-simu/main/commands/web/company/class_WebShipSimuCompanyCommand.php [deleted file]
application/ship-simu/main/commands/web/government/.htaccess [deleted file]
application/ship-simu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php [deleted file]
application/ship-simu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php [deleted file]
application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php [deleted file]
application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php [deleted file]
application/ship-simu/main/companies/.htaccess [deleted file]
application/ship-simu/main/companies/class_ShippingCompany.php [deleted file]
application/ship-simu/main/constructions/.htaccess [deleted file]
application/ship-simu/main/constructions/berths/.htaccess [deleted file]
application/ship-simu/main/constructions/berths/class_Berth.php [deleted file]
application/ship-simu/main/constructions/class_BaseConstruction.php [deleted file]
application/ship-simu/main/constructions/docks/.htaccess [deleted file]
application/ship-simu/main/constructions/docks/class_DryDock.php [deleted file]
application/ship-simu/main/constructions/harbors/.htaccess [deleted file]
application/ship-simu/main/constructions/harbors/class_Harbor.php [deleted file]
application/ship-simu/main/constructions/terminals/.htaccess [deleted file]
application/ship-simu/main/constructions/terminals/class_Terminal.php [deleted file]
application/ship-simu/main/constructions/yards/.htaccess [deleted file]
application/ship-simu/main/constructions/yards/class_Shipyard.php [deleted file]
application/ship-simu/main/controller/.htaccess [deleted file]
application/ship-simu/main/controller/web/.htaccess [deleted file]
application/ship-simu/main/controller/web/class_WebCompanyController.php [deleted file]
application/ship-simu/main/controller/web/class_WebGovernmentFailedController.php [deleted file]
application/ship-simu/main/drives/.htaccess [deleted file]
application/ship-simu/main/drives/class_BaseDrive.php [deleted file]
application/ship-simu/main/drives/motor/.htaccess [deleted file]
application/ship-simu/main/drives/motor/class_Motor.php [deleted file]
application/ship-simu/main/factories/.htaccess [deleted file]
application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php [deleted file]
application/ship-simu/main/filter/.htaccess [deleted file]
application/ship-simu/main/filter/book/.htaccess [deleted file]
application/ship-simu/main/filter/book/refill/.htaccess [deleted file]
application/ship-simu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php [deleted file]
application/ship-simu/main/filter/class_ [deleted file]
application/ship-simu/main/filter/class_BaseShipSimuFilter.php [deleted file]
application/ship-simu/main/filter/government/.htaccess [deleted file]
application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php [deleted file]
application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php [deleted file]
application/ship-simu/main/filter/page/.htaccess [deleted file]
application/ship-simu/main/filter/page/class_RefillPageFilter.php [deleted file]
application/ship-simu/main/filter/validator/.htaccess [deleted file]
application/ship-simu/main/filter/validator/class_RefillRequestValidatorFilter.php [deleted file]
application/ship-simu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php [deleted file]
application/ship-simu/main/filter/verifier/.htaccess [deleted file]
application/ship-simu/main/filter/verifier/class_BirthdayVerifierFilter.php [deleted file]
application/ship-simu/main/government/.htaccess [deleted file]
application/ship-simu/main/government/class_SimplifiedGovernment.php [deleted file]
application/ship-simu/main/login/.htaccess [deleted file]
application/ship-simu/main/login/class_ShipSimuGuestLogin.php [deleted file]
application/ship-simu/main/login/class_ShipSimuUserLogin.php [deleted file]
application/ship-simu/main/login/helper/.htaccess [deleted file]
application/ship-simu/main/login/helper/class_ShipSimuLoginHelper.php [deleted file]
application/ship-simu/main/menu/.htaccess [deleted file]
application/ship-simu/main/menu/class_ShipSimu [deleted file]
application/ship-simu/main/menu/class_ShipSimuConfirmMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuHomeMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuLoginAreaMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuLoginFailedMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuLoginMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuLogoutMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuRegisterMenu.php [deleted file]
application/ship-simu/main/menu/class_ShipSimuStatusMenu.php [deleted file]
application/ship-simu/main/menu/government/.htaccess [deleted file]
application/ship-simu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php [deleted file]
application/ship-simu/main/opening/.htaccess [deleted file]
application/ship-simu/main/opening/bank/.htaccess [deleted file]
application/ship-simu/main/opening/bank/class_MoneyBankRealtimeOpening.php [deleted file]
application/ship-simu/main/opening/class_ [deleted file]
application/ship-simu/main/opening/class_BaseOpening.php [deleted file]
application/ship-simu/main/parts/.htaccess [deleted file]
application/ship-simu/main/parts/class_BaseShipPart.php [deleted file]
application/ship-simu/main/parts/maschineroom/.htaccess [deleted file]
application/ship-simu/main/parts/maschineroom/class_MaschineRoom.php [deleted file]
application/ship-simu/main/personell/.htaccess [deleted file]
application/ship-simu/main/personell/class_SimulatorPersonell.php [deleted file]
application/ship-simu/main/personell/company/.htaccess [deleted file]
application/ship-simu/main/personell/company/class_CompanyEmployee.php [deleted file]
application/ship-simu/main/registration/.htaccess [deleted file]
application/ship-simu/main/registration/class_ShipSimuRegistration.php [deleted file]
application/ship-simu/main/resolver/.htaccess [deleted file]
application/ship-simu/main/resolver/web/.htaccess [deleted file]
application/ship-simu/main/resolver/web/class_WebCompanyCommandResolver.php [deleted file]
application/ship-simu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php [deleted file]
application/ship-simu/main/ships/.htaccess [deleted file]
application/ship-simu/main/ships/class_BaseShip.php [deleted file]
application/ship-simu/main/ships/passenger/.htaccess [deleted file]
application/ship-simu/main/ships/passenger/class_PassengerShip.php [deleted file]
application/ship-simu/main/structures/.htaccess [deleted file]
application/ship-simu/main/structures/class_BaseStructure.php [deleted file]
application/ship-simu/main/structures/extended/.htaccess [deleted file]
application/ship-simu/main/structures/extended/cabines/.htaccess [deleted file]
application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php [deleted file]
application/ship-simu/main/structures/extended/cabines/ship/.htaccess [deleted file]
application/ship-simu/main/structures/extended/cabines/ship/class_EconomyCabin.php [deleted file]
application/ship-simu/main/structures/extended/cabines/ship/class_LowCabin.php [deleted file]
application/ship-simu/main/structures/extended/cabines/ship/class_LuxuryCabin.php [deleted file]
application/ship-simu/main/structures/extended/cabines/ship/class_PremierCabin.php [deleted file]
application/ship-simu/main/structures/extended/class_ [deleted file]
application/ship-simu/main/structures/extended/class_BaseCabinStructure.php [deleted file]
application/ship-simu/main/structures/extended/class_BaseDeckStructure.php [deleted file]
application/ship-simu/main/structures/extended/class_BaseUpperStructure.php [deleted file]
application/ship-simu/main/structures/extended/decks/.htaccess [deleted file]
application/ship-simu/main/structures/extended/decks/cargo/.htaccess [deleted file]
application/ship-simu/main/structures/extended/decks/cargo/class_CarDeck.php [deleted file]
application/ship-simu/main/structures/extended/decks/cargo/class_TrainDeck.php [deleted file]
application/ship-simu/main/structures/extended/decks/cargo/class_TruckDeck.php [deleted file]
application/ship-simu/main/structures/extended/decks/class_BaseDeck.php [deleted file]
application/ship-simu/main/structures/extended/lower/.htaccess [deleted file]
application/ship-simu/main/structures/extended/upper/.htaccess [deleted file]
application/ship-simu/main/structures/extended/upper/class_Bridge.php [deleted file]
application/ship-simu/main/user/.htaccess [deleted file]
application/ship-simu/main/user/class_ShipSimuBaseUser.php [deleted file]
application/ship-simu/main/user/extended/.htaccess [deleted file]
application/ship-simu/main/user/extended/class_ShipSimuGuest.php [deleted file]
application/ship-simu/main/user/extended/class_ShipSimuMember.php [deleted file]
application/ship-simu/main/wrapper/.htaccess [deleted file]
application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php [deleted file]
application/ship-simu/main/wrapper/class_UserGovernmentDatabaseWrapper.php [deleted file]
application/ship-simu/starter.php [deleted file]
application/ship-simu/templates/.htaccess [deleted file]
application/ship-simu/templates/de/.htaccess [deleted file]
application/ship-simu/templates/de/.xml [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_company.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_government_startup_help.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_government_training.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_logout.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_profile.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_refill.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_status_problem.ctp [deleted file]
application/ship-simu/templates/de/code/action_ship_simu_login_welcome.ctp [deleted file]
application/ship-simu/templates/de/code/block_company_data.ctp [deleted file]
application/ship-simu/templates/de/code/block_persona_data.ctp [deleted file]
application/ship-simu/templates/de/code/captch_graphic_code.ctp [deleted file]
application/ship-simu/templates/de/code/confirm_link.ctp [deleted file]
application/ship-simu/templates/de/code/emergency_exit.ctp [deleted file]
application/ship-simu/templates/de/code/footer.ctp [deleted file]
application/ship-simu/templates/de/code/footer_msg.ctp [deleted file]
application/ship-simu/templates/de/code/government_failed_main.ctp [deleted file]
application/ship-simu/templates/de/code/header.ctp [deleted file]
application/ship-simu/templates/de/code/header_extras_hook.ctp [deleted file]
application/ship-simu/templates/de/code/home.ctp [deleted file]
application/ship-simu/templates/de/code/login_failed.ctp [deleted file]
application/ship-simu/templates/de/code/login_form.ctp [deleted file]
application/ship-simu/templates/de/code/login_main.ctp [deleted file]
application/ship-simu/templates/de/code/logout_done.ctp [deleted file]
application/ship-simu/templates/de/code/mail_debug.ctp [deleted file]
application/ship-simu/templates/de/code/register_form.ctp [deleted file]
application/ship-simu/templates/de/code/shipsimu_main.ctp [deleted file]
application/ship-simu/templates/de/code/status.ctp [deleted file]
application/ship-simu/templates/de/emails/.htaccess [deleted file]
application/ship-simu/templates/de/emails/text_resend_link.tpl [deleted file]
application/ship-simu/templates/de/html/.htaccess [deleted file]
application/ship-simu/templates/de/html/nav_advert.tpl [deleted file]
application/ship-simu/templates/de/html/selector_ship-simu.tpl [deleted file]
application/ship-simu/templates/de/image/base_code.xml [deleted file]
application/ship-simu/templates/de/image/code_captcha.img [deleted file]
application/ship-simu/templates/de/image/emergency_exit.img [deleted file]
application/ship-simu/templates/de/menu/.htaccess [deleted file]
application/ship-simu/templates/de/menu/base_menu.xml [deleted file]
application/ship-simu/templates/de/menu/generic_menu_entries.xml [deleted file]
application/ship-simu/templates/game/!MISSING [deleted file]
application/ship-simu/templates/game/.htaccess [deleted file]
application/ship-simu/templates/game/building/.htaccess [deleted file]
application/ship-simu/templates/game/building/advanced_research_lab.xml [deleted file]
application/ship-simu/templates/game/building/base_building.xml [deleted file]
application/ship-simu/templates/game/building/research_lab.xml [deleted file]
application/ship-simu/templates/game/chemicals/.htaccess [deleted file]
application/ship-simu/templates/game/company/.htaccess [deleted file]
application/ship-simu/templates/game/container/.htaccess [deleted file]
application/ship-simu/templates/game/container/base_container.xml [deleted file]
application/ship-simu/templates/game/contract/.htaccess [deleted file]
application/ship-simu/templates/game/contract/base_contract.xml [deleted file]
application/ship-simu/templates/game/drink/.htaccess [deleted file]
application/ship-simu/templates/game/drink/base_drink.xml [deleted file]
application/ship-simu/templates/game/electronic/.htaccess [deleted file]
application/ship-simu/templates/game/electronic/base_electronic.xml [deleted file]
application/ship-simu/templates/game/electronic/cellphone.xml [deleted file]
application/ship-simu/templates/game/electronic/hifi_system.xml [deleted file]
application/ship-simu/templates/game/electronic/radio_receiver.xml [deleted file]
application/ship-simu/templates/game/electronic/surround_system.xml [deleted file]
application/ship-simu/templates/game/electronic/television.xml [deleted file]
application/ship-simu/templates/game/engine/.htaccess [deleted file]
application/ship-simu/templates/game/engine/base_engine.xml [deleted file]
application/ship-simu/templates/game/farmer/.htaccess [deleted file]
application/ship-simu/templates/game/farmer/base_farmer.xml [deleted file]
application/ship-simu/templates/game/fruit/.htaccess [deleted file]
application/ship-simu/templates/game/fruit/base_fruit.xml [deleted file]
application/ship-simu/templates/game/fuel/.htaccess [deleted file]
application/ship-simu/templates/game/fuel/base_fuel.xml [deleted file]
application/ship-simu/templates/game/grain/.htaccess [deleted file]
application/ship-simu/templates/game/grain/base_grain.xml [deleted file]
application/ship-simu/templates/game/lifestock/.htaccess [deleted file]
application/ship-simu/templates/game/lifestock/base_lifestock.xml [deleted file]
application/ship-simu/templates/game/merchant/.htaccess [deleted file]
application/ship-simu/templates/game/merchant/base_merchant.xml [deleted file]
application/ship-simu/templates/game/mineral/.htaccess [deleted file]
application/ship-simu/templates/game/mineral/base_mineral.xml [deleted file]
application/ship-simu/templates/game/produce/.htaccess [deleted file]
application/ship-simu/templates/game/produce/base_produce.xml [deleted file]
application/ship-simu/templates/game/research/.htaccess [deleted file]
application/ship-simu/templates/game/research/base_research.xml [deleted file]
application/ship-simu/templates/game/research/electricity.xml [deleted file]
application/ship-simu/templates/game/research/electronics.xml [deleted file]
application/ship-simu/templates/game/research/mathematics.xml [deleted file]
application/ship-simu/templates/game/research/radio_receiving.xml [deleted file]
application/ship-simu/templates/game/research/statics.xml [deleted file]
application/ship-simu/templates/game/resource/.htaccess [deleted file]
application/ship-simu/templates/game/resource/base_resource.xml [deleted file]
application/ship-simu/templates/game/ship/.htaccess [deleted file]
application/ship-simu/templates/game/ship/base_ship.xml [deleted file]
application/ship-simu/templates/game/tank/.htaccess [deleted file]
application/ship-simu/templates/game/tank/base_tank.xml [deleted file]
application/ship-simu/templates/game/technology/.htaccess [deleted file]
application/ship-simu/templates/game/technology/architecture.xml [deleted file]
application/ship-simu/templates/game/technology/base_technology.xml [deleted file]
application/ship-simu/templates/game/technology/cellular_network.xml [deleted file]
application/ship-simu/templates/game/technology/drawings.xml [deleted file]
application/ship-simu/templates/game/technology/glass_making.xml [deleted file]
application/ship-simu/templates/game/technology/household_devices.xml [deleted file]
application/ship-simu/templates/game/technology/intergrated_currents.xml [deleted file]
application/ship-simu/templates/game/technology/laboratory_equipment.xml [deleted file]
application/ship-simu/templates/game/technology/naval_architecture.xml [deleted file]
application/ship-simu/templates/game/technology/plastics.xml [deleted file]
application/ship-simu/templates/game/technology/signal_amplifying.xml [deleted file]
application/ship-simu/templates/game/technology/signal_modulation.xml [deleted file]
application/ship-simu/templates/game/technology/sound_equalizer.xml [deleted file]
application/ship-simu/templates/game/technology/sound_processor.xml [deleted file]
application/ship-simu/templates/game/technology/surround_mixing.xml [deleted file]
application/ship-simu/templates/game/technology/transistor.xml [deleted file]
application/ship-simu/templates/game/technology/video_receiving.xml [deleted file]
application/ship-simu/templates/game/types/.htaccess [deleted file]
application/ship-simu/templates/game/types/building_types.xml [deleted file]
application/ship-simu/templates/game/types/container_types.xml [deleted file]
application/ship-simu/templates/game/types/content_types.xml [deleted file]
application/ship-simu/templates/game/types/contract_types.xml [deleted file]
application/ship-simu/templates/game/types/electronic_types.xml [deleted file]
application/ship-simu/templates/game/types/engine_types.xml [deleted file]
application/ship-simu/templates/game/types/farmer_types.xml [deleted file]
application/ship-simu/templates/game/types/fuel_types.xml [deleted file]
application/ship-simu/templates/game/types/merchant_types.xml [deleted file]
application/ship-simu/templates/game/types/owner_occupants.xml [deleted file]
application/ship-simu/templates/game/types/product_types.xml [deleted file]
application/ship-simu/templates/game/types/research_types.xml [deleted file]
application/ship-simu/templates/game/types/ship_types.xml [deleted file]
application/ship-simu/templates/game/types/signer_types.xml [deleted file]
application/ship-simu/templates/game/types/tank_types.xml [deleted file]
application/ship-simu/templates/game/types/technology_types.xml [deleted file]
application/ship-simu/templates/game/vegetable/.htaccess [deleted file]
application/ship-simu/templates/game/vegetable/base_vegetable.xml [deleted file]
application/shipsimu/.htaccess [new file with mode: 0644]
application/shipsimu/admin/.htaccess [new file with mode: 0644]
application/shipsimu/class_ApplicationHelper.php [new file with mode: 0644]
application/shipsimu/config.php [new file with mode: 0644]
application/shipsimu/data.php [new file with mode: 0644]
application/shipsimu/debug.php [new file with mode: 0644]
application/shipsimu/exceptions.php [new file with mode: 0644]
application/shipsimu/exceptions/.htaccess [new file with mode: 0644]
application/shipsimu/exceptions/class_BirthdayInvalidException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_CabinShipMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ContractAllreadySignedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ContractPartnerMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_DeckShipMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_EmptyStructuresListException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_InvalidContractPartnerException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_InvalidIDFormatException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ItemNotInPriceListException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ItemNotTradeableException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_MissingSimulatorIdException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_MotorShipMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_NoShippingCompanyOwnedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_NoShipyardsConstructedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_PersonellListAlreadyCreatedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_RoomShipMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ShipNotConstructedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ShipPartNotConstructableException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_StructureShipMismatchException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_StructuresOutOfBoundsException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_ToMuchEmployeesException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_TotalPriceNotCalculatedException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_UnsupportedLimitationPartException.php [new file with mode: 0644]
application/shipsimu/exceptions/class_WrongGenderSpecifiedException.php [new file with mode: 0644]
application/shipsimu/init.php [new file with mode: 0644]
application/shipsimu/interfaces/.htaccess [new file with mode: 0644]
application/shipsimu/interfaces/class_BookableAccount.php [new file with mode: 0644]
application/shipsimu/interfaces/class_ConstructableShip.php [new file with mode: 0644]
application/shipsimu/interfaces/class_ConstructableShipPart.php [new file with mode: 0644]
application/shipsimu/interfaces/class_ContractPartner.php [new file with mode: 0644]
application/shipsimu/interfaces/class_Customer.php [new file with mode: 0644]
application/shipsimu/interfaces/class_Personellizer.php [new file with mode: 0644]
application/shipsimu/interfaces/class_SignableContract.php [new file with mode: 0644]
application/shipsimu/interfaces/class_TradeableItem.php [new file with mode: 0644]
application/shipsimu/loader.php [new file with mode: 0644]
application/shipsimu/main/.htaccess [new file with mode: 0644]
application/shipsimu/main/actions/.htaccess [new file with mode: 0644]
application/shipsimu/main/actions/class_ [new file with mode: 0644]
application/shipsimu/main/actions/class_BaseShipSimuAction.php [new file with mode: 0644]
application/shipsimu/main/actions/ship-simu/.htaccess [new file with mode: 0644]
application/shipsimu/main/actions/ship-simu/class_ShipSimuLoginAction.php [new file with mode: 0644]
application/shipsimu/main/actions/ship-simu/class_ShipSimuProfileAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/.htaccess [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLogin [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginCompanyAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginLogoutAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginProfileAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginRefillAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php [new file with mode: 0644]
application/shipsimu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php [new file with mode: 0644]
application/shipsimu/main/bank/.htaccess [new file with mode: 0644]
application/shipsimu/main/bank/class_BaseBank.php [new file with mode: 0644]
application/shipsimu/main/bank/money/class_MoneyBank.php [new file with mode: 0644]
application/shipsimu/main/class_ [new file with mode: 0644]
application/shipsimu/main/class_BasePersonell.php [new file with mode: 0644]
application/shipsimu/main/class_BaseSimulator.php [new file with mode: 0644]
application/shipsimu/main/class_Merchant.php [new file with mode: 0644]
application/shipsimu/main/class_WorksContract.php [new file with mode: 0644]
application/shipsimu/main/commands/.htaccess [new file with mode: 0644]
application/shipsimu/main/commands/web/.htaccess [new file with mode: 0644]
application/shipsimu/main/commands/web/class_WebShipsimuGuestLoginCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/class_WebShipsimuProfileCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/class_WebShipsimuRefillCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/class_WebShipsimuRegisterCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/class_WebShipsimuUserLoginCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/company/.htaccess [new file with mode: 0644]
application/shipsimu/main/commands/web/company/class_WebShipSimuCompanyCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/government/.htaccess [new file with mode: 0644]
application/shipsimu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php [new file with mode: 0644]
application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php [new file with mode: 0644]
application/shipsimu/main/companies/.htaccess [new file with mode: 0644]
application/shipsimu/main/companies/class_ShippingCompany.php [new file with mode: 0644]
application/shipsimu/main/constructions/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/berths/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/berths/class_Berth.php [new file with mode: 0644]
application/shipsimu/main/constructions/class_BaseConstruction.php [new file with mode: 0644]
application/shipsimu/main/constructions/docks/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/docks/class_DryDock.php [new file with mode: 0644]
application/shipsimu/main/constructions/harbors/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/harbors/class_Harbor.php [new file with mode: 0644]
application/shipsimu/main/constructions/terminals/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/terminals/class_Terminal.php [new file with mode: 0644]
application/shipsimu/main/constructions/yards/.htaccess [new file with mode: 0644]
application/shipsimu/main/constructions/yards/class_Shipyard.php [new file with mode: 0644]
application/shipsimu/main/controller/.htaccess [new file with mode: 0644]
application/shipsimu/main/controller/web/.htaccess [new file with mode: 0644]
application/shipsimu/main/controller/web/class_WebCompanyController.php [new file with mode: 0644]
application/shipsimu/main/controller/web/class_WebGovernmentFailedController.php [new file with mode: 0644]
application/shipsimu/main/drives/.htaccess [new file with mode: 0644]
application/shipsimu/main/drives/class_BaseDrive.php [new file with mode: 0644]
application/shipsimu/main/drives/motor/.htaccess [new file with mode: 0644]
application/shipsimu/main/drives/motor/class_Motor.php [new file with mode: 0644]
application/shipsimu/main/factories/.htaccess [new file with mode: 0644]
application/shipsimu/main/factories/class_ShipSimuWebNewsFactory.php [new file with mode: 0644]
application/shipsimu/main/filter/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/book/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/book/refill/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/class_ [new file with mode: 0644]
application/shipsimu/main/filter/class_BaseShipSimuFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/government/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/page/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/page/class_RefillPageFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/validator/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/validator/class_RefillRequestValidatorFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php [new file with mode: 0644]
application/shipsimu/main/filter/verifier/.htaccess [new file with mode: 0644]
application/shipsimu/main/filter/verifier/class_BirthdayVerifierFilter.php [new file with mode: 0644]
application/shipsimu/main/government/.htaccess [new file with mode: 0644]
application/shipsimu/main/government/class_SimplifiedGovernment.php [new file with mode: 0644]
application/shipsimu/main/login/.htaccess [new file with mode: 0644]
application/shipsimu/main/login/class_ShipSimuGuestLogin.php [new file with mode: 0644]
application/shipsimu/main/login/class_ShipSimuUserLogin.php [new file with mode: 0644]
application/shipsimu/main/login/helper/.htaccess [new file with mode: 0644]
application/shipsimu/main/login/helper/class_ShipSimuLoginHelper.php [new file with mode: 0644]
application/shipsimu/main/menu/.htaccess [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimu [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuConfirmMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuHomeMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuLoginAreaMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuLoginFailedMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuLoginMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuLogoutMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuRegisterMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/class_ShipSimuStatusMenu.php [new file with mode: 0644]
application/shipsimu/main/menu/government/.htaccess [new file with mode: 0644]
application/shipsimu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php [new file with mode: 0644]
application/shipsimu/main/opening/.htaccess [new file with mode: 0644]
application/shipsimu/main/opening/bank/.htaccess [new file with mode: 0644]
application/shipsimu/main/opening/bank/class_MoneyBankRealtimeOpening.php [new file with mode: 0644]
application/shipsimu/main/opening/class_ [new file with mode: 0644]
application/shipsimu/main/opening/class_BaseOpening.php [new file with mode: 0644]
application/shipsimu/main/parts/.htaccess [new file with mode: 0644]
application/shipsimu/main/parts/class_BaseShipPart.php [new file with mode: 0644]
application/shipsimu/main/parts/maschineroom/.htaccess [new file with mode: 0644]
application/shipsimu/main/parts/maschineroom/class_MaschineRoom.php [new file with mode: 0644]
application/shipsimu/main/personell/.htaccess [new file with mode: 0644]
application/shipsimu/main/personell/class_SimulatorPersonell.php [new file with mode: 0644]
application/shipsimu/main/personell/company/.htaccess [new file with mode: 0644]
application/shipsimu/main/personell/company/class_CompanyEmployee.php [new file with mode: 0644]
application/shipsimu/main/registration/.htaccess [new file with mode: 0644]
application/shipsimu/main/registration/class_ShipSimuRegistration.php [new file with mode: 0644]
application/shipsimu/main/resolver/.htaccess [new file with mode: 0644]
application/shipsimu/main/resolver/web/.htaccess [new file with mode: 0644]
application/shipsimu/main/resolver/web/class_WebCompanyCommandResolver.php [new file with mode: 0644]
application/shipsimu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php [new file with mode: 0644]
application/shipsimu/main/ships/.htaccess [new file with mode: 0644]
application/shipsimu/main/ships/class_BaseShip.php [new file with mode: 0644]
application/shipsimu/main/ships/passenger/.htaccess [new file with mode: 0644]
application/shipsimu/main/ships/passenger/class_PassengerShip.php [new file with mode: 0644]
application/shipsimu/main/structures/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/class_BaseStructure.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/class_BaseCabin.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/ship/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/ship/class_EconomyCabin.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/ship/class_LowCabin.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/ship/class_LuxuryCabin.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/cabines/ship/class_PremierCabin.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/class_ [new file with mode: 0644]
application/shipsimu/main/structures/extended/class_BaseCabinStructure.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/class_BaseDeckStructure.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/class_BaseUpperStructure.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/cargo/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/cargo/class_CarDeck.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/cargo/class_TrainDeck.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/cargo/class_TruckDeck.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/decks/class_BaseDeck.php [new file with mode: 0644]
application/shipsimu/main/structures/extended/lower/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/upper/.htaccess [new file with mode: 0644]
application/shipsimu/main/structures/extended/upper/class_Bridge.php [new file with mode: 0644]
application/shipsimu/main/user/.htaccess [new file with mode: 0644]
application/shipsimu/main/user/class_ShipSimuBaseUser.php [new file with mode: 0644]
application/shipsimu/main/user/extended/.htaccess [new file with mode: 0644]
application/shipsimu/main/user/extended/class_ShipSimuGuest.php [new file with mode: 0644]
application/shipsimu/main/user/extended/class_ShipSimuMember.php [new file with mode: 0644]
application/shipsimu/main/wrapper/.htaccess [new file with mode: 0644]
application/shipsimu/main/wrapper/class_CompanyDatabaseWrapper.php [new file with mode: 0644]
application/shipsimu/main/wrapper/class_UserGovernmentDatabaseWrapper.php [new file with mode: 0644]
application/shipsimu/starter.php [new file with mode: 0644]
application/shipsimu/templates/.htaccess [new file with mode: 0644]
application/shipsimu/templates/de/.htaccess [new file with mode: 0644]
application/shipsimu/templates/de/.xml [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_company.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_government_startup_help.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_government_training.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_logout.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_profile.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_refill.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_status_problem.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/action_ship_simu_login_welcome.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/block_company_data.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/block_persona_data.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/captch_graphic_code.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/confirm_link.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/emergency_exit.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/footer.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/footer_msg.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/government_failed_main.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/header.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/header_extras_hook.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/home.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/login_failed.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/login_form.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/login_main.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/logout_done.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/mail_debug.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/register_form.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/shipsimu_main.ctp [new file with mode: 0644]
application/shipsimu/templates/de/code/status.ctp [new file with mode: 0644]
application/shipsimu/templates/de/emails/.htaccess [new file with mode: 0644]
application/shipsimu/templates/de/emails/text_resend_link.tpl [new file with mode: 0644]
application/shipsimu/templates/de/html/.htaccess [new file with mode: 0644]
application/shipsimu/templates/de/html/nav_advert.tpl [new file with mode: 0644]
application/shipsimu/templates/de/html/selector_ship-simu.tpl [new file with mode: 0644]
application/shipsimu/templates/de/image/base_code.xml [new file with mode: 0644]
application/shipsimu/templates/de/image/code_captcha.img [new file with mode: 0644]
application/shipsimu/templates/de/image/emergency_exit.img [new file with mode: 0644]
application/shipsimu/templates/de/menu/.htaccess [new file with mode: 0644]
application/shipsimu/templates/de/menu/base_menu.xml [new file with mode: 0644]
application/shipsimu/templates/de/menu/generic_menu_entries.xml [new file with mode: 0644]
application/shipsimu/templates/game/!MISSING [new file with mode: 0644]
application/shipsimu/templates/game/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/building/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/building/advanced_research_lab.xml [new file with mode: 0644]
application/shipsimu/templates/game/building/base_building.xml [new file with mode: 0644]
application/shipsimu/templates/game/building/research_lab.xml [new file with mode: 0644]
application/shipsimu/templates/game/chemicals/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/company/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/container/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/container/base_container.xml [new file with mode: 0644]
application/shipsimu/templates/game/contract/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/contract/base_contract.xml [new file with mode: 0644]
application/shipsimu/templates/game/drink/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/drink/base_drink.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/electronic/base_electronic.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/cellphone.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/hifi_system.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/radio_receiver.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/surround_system.xml [new file with mode: 0644]
application/shipsimu/templates/game/electronic/television.xml [new file with mode: 0644]
application/shipsimu/templates/game/engine/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/engine/base_engine.xml [new file with mode: 0644]
application/shipsimu/templates/game/farmer/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/farmer/base_farmer.xml [new file with mode: 0644]
application/shipsimu/templates/game/fruit/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/fruit/base_fruit.xml [new file with mode: 0644]
application/shipsimu/templates/game/fuel/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/fuel/base_fuel.xml [new file with mode: 0644]
application/shipsimu/templates/game/grain/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/grain/base_grain.xml [new file with mode: 0644]
application/shipsimu/templates/game/lifestock/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/lifestock/base_lifestock.xml [new file with mode: 0644]
application/shipsimu/templates/game/merchant/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/merchant/base_merchant.xml [new file with mode: 0644]
application/shipsimu/templates/game/mineral/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/mineral/base_mineral.xml [new file with mode: 0644]
application/shipsimu/templates/game/produce/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/produce/base_produce.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/research/base_research.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/electricity.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/electronics.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/mathematics.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/radio_receiving.xml [new file with mode: 0644]
application/shipsimu/templates/game/research/statics.xml [new file with mode: 0644]
application/shipsimu/templates/game/resource/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/resource/base_resource.xml [new file with mode: 0644]
application/shipsimu/templates/game/ship/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/ship/base_ship.xml [new file with mode: 0644]
application/shipsimu/templates/game/tank/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/tank/base_tank.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/technology/architecture.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/base_technology.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/cellular_network.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/drawings.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/glass_making.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/household_devices.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/intergrated_currents.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/laboratory_equipment.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/naval_architecture.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/plastics.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/signal_amplifying.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/signal_modulation.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/sound_equalizer.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/sound_processor.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/surround_mixing.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/transistor.xml [new file with mode: 0644]
application/shipsimu/templates/game/technology/video_receiving.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/types/building_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/container_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/content_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/contract_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/electronic_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/engine_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/farmer_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/fuel_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/merchant_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/owner_occupants.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/product_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/research_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/ship_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/signer_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/tank_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/types/technology_types.xml [new file with mode: 0644]
application/shipsimu/templates/game/vegetable/.htaccess [new file with mode: 0644]
application/shipsimu/templates/game/vegetable/base_vegetable.xml [new file with mode: 0644]
core [new submodule]
inc [new symlink]

diff --git a/.gitmodules b/.gitmodules
new file mode 100644 (file)
index 0000000..7b054c7
--- /dev/null
@@ -0,0 +1,3 @@
+[submodule "core"]
+       path = core
+       url = git://git.mxchange.org/core.git
diff --git a/application/ship-simu/.htaccess b/application/ship-simu/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/admin/.htaccess b/application/ship-simu/admin/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/class_ApplicationHelper.php b/application/ship-simu/class_ApplicationHelper.php
deleted file mode 100644 (file)
index 7000c38..0000000
+++ /dev/null
@@ -1,227 +0,0 @@
-<?php
-/**
- * A class holding general data about the application and some methods for
- * the management including the entry point.
- *
- * E.g.:
- *
- * index.php?app=my_app
- *
- * You need to create a folder in the folder "application" named "my_app"
- * (without the quotes) and create a include file called
- * class_ApplicationHelper.php. You have to write the same class for your
- * application and implement the same interface called ManageableApplication
- * because this class include file will be searched for.
- *
- * It is good when you avoid more GET parameters to keep URLs short and sweet.
- * But sometimes you need some GET paramerers e.g. for your imprint or info page
- * or other linked pages which you have to create and state some informations.
- *
- * Please remember that this include file is being loaded *before* the class
- * loader is loading classes from "exceptions", "interfaces" and "main"!
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0
- * @copyright  Copyright (c) 2007 - 2008 Roland Haeder, 2009 - 2012 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- *
- * 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 ApplicationHelper extends BaseFrameworkSystem implements ManageableApplication, Registerable {
-       /**
-        * The version number of this application
-        */
-       private $appVersion = '';
-
-       /**
-        * The human-readable name for this application
-        */
-       private $appName = '';
-
-       /**
-        * The short uni*-like name for this application
-        */
-       private $shortName = '';
-
-       /**
-        * An instance of this class
-        */
-       private static $selfInstance = NULL;
-
-       /**
-        * Private constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Getter for an instance of this class
-        *
-        * @return      $selfInstance   An instance of this class
-        */
-       public static final function getSelfInstance () {
-               // Is the instance there?
-               if (is_null(self::$selfInstance)) {
-                       self::$selfInstance = new ApplicationHelper();
-               } // END - if
-
-               // Return the instance
-               return self::$selfInstance;
-       }
-
-       /**
-        * Getter for the version number
-        *
-        * @return      $appVersion     The application's version number
-        */
-       public final function getAppVersion () {
-               return $this->appVersion;
-       }
-       /**
-        * Setter for the version number
-        *
-        * @param       $appVersion     The application's version number
-        * @return      void
-        */
-       public final function setAppVersion ($appVersion) {
-               // Cast and set it
-               $this->appVersion = (string) $appVersion;
-       }
-
-       /**
-        * Getter for human-readable name
-        *
-        * @return      $appName        The application's human-readable name
-        */
-       public final function getAppName () {
-               return $this->appName;
-       }
-
-       /**
-        * Setter for human-readable name
-        *
-        * @param       $appName        The application's human-readable name
-        * @return      void
-        */
-       public final function setAppName ($appName) {
-               // Cast and set it
-               $this->appName = (string) $appName;;
-       }
-
-       /**
-        * Getter for short uni*-like name
-        *
-        * @return      $shortName      The application's short uni*-like name
-        */
-       public final function getAppShortName () {
-               return $this->shortName;
-       }
-
-       /**
-        * Setter for short uni*-like name
-        *
-        * @param       $shortName      The application's short uni*-like name
-        * @return      void
-        */
-       public final function setAppShortName ($shortName) {
-               // Cast and set it
-               $this->shortName = (string) $shortName;
-       }
-
-       /**
-        * Launches the application
-        *
-        * @return      void
-        */
-       public final function entryPoint () {
-               // Set this application in registry
-               Registry::getRegistry()->addInstance('app', $this);
-
-               // Default response is console
-               $response = $this->getResponseTypeFromSystem();
-               $responseType = $this->getResponseTypeFromSystem();
-
-               // Create a new request object
-               $requestInstance = ObjectFactory::createObjectByName($this->convertToClassName($response) . 'Request');
-
-               // Remember request instance here
-               $this->setRequestInstance($requestInstance);
-
-               // Do we have another response?
-               if ($requestInstance->isRequestElementSet('request')) {
-                       // Then use it
-                       $response = strtolower($requestInstance->getRequestElement('request'));
-                       $responseType = $response;
-               } // END - if
-
-               // ... and a new response object
-               $responseClass = sprintf("%sResponse", $this->convertToClassName($response));
-               $responseInstance = ObjectFactory::createObjectByName($responseClass, array($this));
-
-               // Remember response instance here
-               $this->setResponseInstance($responseInstance);
-
-               // Get the parameter from the request
-               $commandName = $requestInstance->getRequestElement('command');
-
-               // If it is null then get default command
-               if (is_null($commandName)) {
-                       // Get default command
-                       $commandName = $responseInstance->getDefaultCommand();
-
-                       // Set it in request
-                       $requestInstance->setRequestElement('command', $commandName);
-               } // END - if
-
-               // Get a controller resolver
-               $resolverClass = $this->convertToClassName($this->getAppShortName() . '_' . $responseType . '_controller_resolver');
-               $resolverInstance = ObjectFactory::createObjectByName($resolverClass, array($commandName, $this));
-
-               // Get a controller instance as well
-               $this->setControllerInstance($resolverInstance->resolveController());
-
-               // Launch the main routine here
-               $this->getControllerInstance()->handleRequest($requestInstance, $responseInstance);
-       }
-
-       /**
-        * Handle the indexed array of fatal messages and puts them out in an
-        * acceptable fasion
-        *
-        * @param       $messageList    An array of fatal messages
-        * @return      void
-        */
-       public function handleFatalMessages (array $messageList) {
-               // Walk through all messages
-               foreach ($messageList as $message) {
-                       exit(__METHOD__ . ':MSG:' . $message);
-               } // END - foreach
-       }
-
-       /**
-        * Builds the master template's name
-        *
-        * @return      $masterTemplateName             Name of the master template
-        */
-       public function buildMasterTemplateName () {
-               return 'node_main';
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/config.php b/application/ship-simu/config.php
deleted file mode 100644 (file)
index b37151f..0000000
+++ /dev/null
@@ -1,539 +0,0 @@
-<?php
-/**
- * Additional/overwritten configuration parts
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Get a configuration instance for shorter lines
-$cfg = FrameworkConfiguration::getSelfInstance();
-
-// CFG: HEADER-CHARSET
-$cfg->setConfigEntry('header_charset', 'utf-8');
-
-// CFG: DEFAULT-WEB-COMMAND
-$cfg->setConfigEntry('default_web_command', 'home');
-
-// CFG: DEFAULT-IMAGE-COMMAND
-$cfg->setConfigEntry('default_image_command', 'build');
-
-// CFG: FORM-ACTION
-$cfg->setConfigEntry('form_action', 'index.php?app={?app_short_name?}&amp;page=do_form');
-
-// CFG: FORM-METHOD
-$cfg->setConfigEntry('form_method', 'post');
-
-// CFG: FORM-TARGET
-$cfg->setConfigEntry('form_target', '_self');
-
-// CFG: REGISTER-REQUIRES-EMAIL
-$cfg->setConfigEntry('register_requires_email', 'Y');
-
-// CFG: REGISTER-INCLUDES-PROFILE
-$cfg->setConfigEntry('register_includes_profile', 'Y');
-
-// CFG: REGISTER-PERSONAL-DATA
-$cfg->setConfigEntry('register_personal_data', 'Y');
-
-// CFG: REGISTER-EMAIL-UNIQUE
-$cfg->setConfigEntry('register_email_unique', 'Y');
-
-// CFG: PROFILE-INCLUDES-BIRTHDAY
-$cfg->setConfigEntry('profile_includes_birthday', 'Y');
-
-// CFG: CHAT-ENABLED-ICQ
-$cfg->setConfigEntry('chat_enabled_icq', 'Y');
-
-// CFG: CHAT-ENABLED-JABBER
-$cfg->setConfigEntry('chat_enabled_jabber', 'Y');
-
-// CFG: CHAT-ENABLED-YAHOO
-$cfg->setConfigEntry('chat_enabled_yahoo', 'Y');
-
-// CFG: CHAT-ENABLED-AOL
-$cfg->setConfigEntry('chat_enabled_aol', 'Y');
-
-// CFG: CHAT-ENABLED-MSN
-$cfg->setConfigEntry('chat_enabled_msn', 'Y');
-
-// CFG: USER-REGISTRATION
-$cfg->setConfigEntry('user_registration_class', 'ShipSimuRegistration');
-
-// CFG: USER-LOGIN-CLASS
-$cfg->setConfigEntry('user_login_class', 'ShipSimuUserLogin');
-
-// CFG: GUEST-LOGIN-CLASS
-$cfg->setConfigEntry('guest_login_class', 'ShipSimuGuestLogin');
-
-// CFG: USER-STATUS-REGISTER
-$cfg->setConfigEntry('user_status_unconfirmed', 'UNCONFIRMED');
-
-// CFG: USER-STATUS-GUEST
-$cfg->setConfigEntry('user_status_guest', 'GUEST');
-
-// CFG: USER-STATUS-CONFIRMED
-$cfg->setConfigEntry('user_status_confirmed', 'CONFIRMED');
-
-// CFG: USER-STATUS-LOCKED
-$cfg->setConfigEntry('user_status_locked', 'LOCKED');
-
-// CFG: LOGIN-HELPER-CLASS
-$cfg->setConfigEntry('login_helper_class', 'ShipSimuLoginHelper');
-
-// CFG: AUTH-METHOD-CLASS
-$cfg->setConfigEntry('auth_method_class', 'CookieAuth');
-
-// CFG: APP-LOGIN-URL
-$cfg->setConfigEntry('app_login_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: LOGIN-FAILED-URL
-$cfg->setConfigEntry('login_failed_url', 'index.php?app={?app_short_name?}&amp;page=login_failed');
-
-// CFG: LOGIN-FAILED-LOGIN-RETRY-ACTION-URL
-$cfg->setConfigEntry('login_failed_login_retry_action_url', 'index.php?app={?app_short_name?}&amp;page=login&amp;note=login_failed');
-
-// CFG: LOGOUT-DONE-URL
-$cfg->setConfigEntry('logout_done_url', 'index.php?app={?app_short_name?}&amp;page=logout_done');
-
-// CFG: ACTION-STATUS-PROBLEM
-$cfg->setConfigEntry('action_status_problem', 'status_problem');
-
-// CFG: LOGIN-USER-STATUS-URL
-$cfg->setConfigEntry('login_user_status_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=status_problem&amp;status=general');
-
-// CFG: LOGIN-USER-STATUS-GUEST-URL
-$cfg->setConfigEntry('login_user_status_guest_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=status_problem&amp;status=guest');
-
-// CFG: USER-NOT-UNCONFIRMED-URL
-$cfg->setConfigEntry('user_not_unconfirmed_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=unconfirmed_problem');
-
-// CFG: USER-UNCONFIRMED-EMAIL-MISSING-URL
-$cfg->setConfigEntry('user_unconfirmed_email_missing_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=unconfirmed_email_missing');
-
-// CFG: CONFIRM-CODE-INVALID-URL
-$cfg->setConfigEntry('confirm_code_invalid_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=confirm_code_invalid');
-
-// CFG: USER-NOT-FOUND-URL
-$cfg->setConfigEntry('user_not_found_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=user_not_found');
-
-// CFG: LOGIN-GOVERNMENT-STARTUP-FAILED-URL
-$cfg->setConfigEntry('login_government_startup_failed_url', 'index.php?app={?app_short_name?}&amp;page=government_failed&amp;failed=startup');
-
-// CFG: LOGIN-GOVERNMENT-TRAINING-FAILED-URL
-$cfg->setConfigEntry('login_government_training_failed_url', 'index.php?app={?app_short_name?}&amp;page=government_failed&amp;failed=training');
-
-// CFG: REFILL-PAGE-CURRENCY-DONE-URL
-$cfg->setConfigEntry('refill_page_done_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=refill_done&amp;done={?refill_done?}&amount={?amount?}');
-
-// CFG: LOGIN-DEFAULT-ACTION
-$cfg->setConfigEntry('login_default_action', 'welcome');
-
-// CFG: LOGIN-AREA-LOGOUT-ACTION-URL
-$cfg->setConfigEntry('login_area_logout_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: GOVERNMENT-FAILED-LOGOUT-ACTION-URL
-$cfg->setConfigEntry('government_failed_logout_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: LOGIN-AREA-PROFILE-ACTION-URL
-$cfg->setConfigEntry('login_area_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=profile');
-
-// CFG: GOVERNMENT-FAILED-PROFILE-ACTION-URL
-$cfg->setConfigEntry('government_failed_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=profile');
-
-// CFG: LOGIN-AREA-COMPANY-ACTION-URL
-$cfg->setConfigEntry('login_area_company_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: GOVERNMENT-FAILED-COMPANY-ACTION-URL
-$cfg->setConfigEntry('government_failed_company_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: LOGIN-AREA-LIST-COMPANIES-ACTION-URL
-$cfg->setConfigEntry('login_area_list_companies_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: LOGIN-AREA-LOGOUT-NOW-ACTION-URL
-$cfg->setConfigEntry('login_area_logout_now_action_url', 'index.php?app={?app_short_name?}&amp;page=logout');
-
-// CFG: LOGIN-AREA-RETURN-LOGIN-ACTION-URL
-$cfg->setConfigEntry('login_area_return_login_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: LOGIN-AREA-SHIPSIMU-PROFILE-ACTION-URL
-$cfg->setConfigEntry('login_area_shipsimu_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=profile');
-
-// CFG: LOGOUT_DONE-RELOGIN-ACTION-URL
-$cfg->setConfigEntry('logout_done_relogin_action_url', 'index.php?app={?app_short_name?}&amp;page=login');
-
-// CFG: LOGIN-REGISTER-ACTION-URL
-$cfg->setConfigEntry('login_register_action_url', 'index.php?app={?app_short_name?}&amp;page=register');
-
-// CFG: CONFIRM-DIRECT-LOGIN-ACTION-URL
-$cfg->setConfigEntry('confirm_direct_login_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
-
-// CFG: WEB-CMD-USER-IS-NULL-URL
-$cfg->setConfigEntry('web_cmd_user_is_null_url', 'index.php?app={?app_short_name?}&amp;page=problem&amp;problem=user_null');
-
-// CFG: NEWS-READER-HOME-CLASS
-$cfg->setConfigEntry('news_reader_home_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-CLASS
-$cfg->setConfigEntry('news_reader_login_area_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-LOGOUT-CLASS
-$cfg->setConfigEntry('news_reader_login_area_logout_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-COMPANY-CLASS
-$cfg->setConfigEntry('news_reader_login_area_company_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-REFILL-CLASS
-$cfg->setConfigEntry('news_reader_login_area_refill_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-PROFILE-CLASS
-$cfg->setConfigEntry('news_reader_login_area_profile_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-GOVERNMENT-TRAINING-CLASS
-$cfg->setConfigEntry('news_reader_login_area_government_training_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-GOVERNMENT-STARTUP-HELP-CLASS
-$cfg->setConfigEntry('news_reader_login_area_government_startup_help_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-LOGIN-AREA-STATUS-PROBLEM-CLASS
-$cfg->setConfigEntry('news_reader_login_area_status_problem_class', 'DefaultNewsReader');
-
-// CFG: NEWS-READER-GOVERNMENT-FAILED-CLASS
-$cfg->setConfigEntry('news_reader_government_failed_class', 'DefaultNewsReader');
-
-// CFG: NEWS-DOWNLOAD-FILTER
-$cfg->setConfigEntry('news_download_filter', 'NewsDownloadFilter');
-
-// CFG: NEWS-PROCESS-FILTER
-$cfg->setConfigEntry('news_process_filter', 'NewsProcessFilter');
-
-// CFG: USER-AUTH-FILTER
-$cfg->setConfigEntry('user_auth_filter', 'UserAuthFilter');
-
-// CFG: USER-UPDATE-FILTER
-$cfg->setConfigEntry('user_update_filter', 'UserUpdateFilter');
-
-// CFG: USER-STATUS-CONFIRMED-FILTER
-$cfg->setConfigEntry('user_status_confirmed_filter', 'UserStatusConfimedUpdateFilter');
-
-// CFG: CAPTCHA-ENCRYPT-VALIDATOR-FILTER
-$cfg->setConfigEntry('captcha_encrypt_validator_filter', 'CaptchaEncryptFilter');
-
-// CFG: REFILL-REQUEST-VALIDATOR-FILTER
-$cfg->setConfigEntry('refill_request_validator_filter', 'RefillRequestValidatorFilter');
-
-// CFG: CAPTCHA-GUEST-VERIFIER-FILTER
-$cfg->setConfigEntry('captcha_guest_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CAPTCHA-USER-VERIFIER-FILTER
-$cfg->setConfigEntry('captcha_user_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CAPTCHA-REGISTER-VERIFIER-FILTER
-$cfg->setConfigEntry('captcha_register_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CAPTCHA-REFILL-VERFIER-FILTER
-$cfg->setConfigEntry('captcha_refill_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CAPTCHA-GOVERNMENT-VERFIER-FILTER
-$cfg->setConfigEntry('captcha_government_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CAPTCHA-PROFILE-VERFIER-FILTER
-$cfg->setConfigEntry('captcha_profile_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
-
-// CFG: CONFIRM-CODE-VERIFIER-FILTER
-$cfg->setConfigEntry('confirm_code_verifier_filter', 'ConfirmCodeVerifierFilter');
-
-// CFG: BIRTHDAY-REGISTER-VERIFIER-FILTER
-$cfg->setConfigEntry('birthday_register_verifier_filter', 'BirthdayVerifierFilter');
-
-// CFG: BIRTHDAY-PROFILE-VERIFIER-FILTER
-$cfg->setConfigEntry('birthday_profile_verifier_filter', 'BirthdayVerifierFilter');
-
-// CFG: REFILL-PAGE-FILTER
-$cfg->setConfigEntry('refill_page_filter', 'RefillPageFilter');
-
-// CFG: REFILL-REQUEST-CURRENCY-BOOK-FILTER
-$cfg->setConfigEntry('refill_request_currency_test_book_filter', 'RefillRequestCurrencyTestBookFilter');
-
-// CFG: PAYMENT-DISCOVERY-FILTER
-$cfg->setConfigEntry('payment_discovery_filter', 'PaymentDiscoveryFilter');
-
-// CFG: GOVERNMENT-PAYS-TRAINING-FILTER
-$cfg->setConfigEntry('government_pays_training_filter', 'ShipSimuGovernmentPaysTrainingFilter');
-
-// CFG: GOVERNMENT-PAYS-STARTUP-HELP-FILTER
-$cfg->setConfigEntry('government_pays_startup_help_filter', 'ShipSimuGovernmentPaysStartupHelpFilter');
-
-// CFG: USER-STATUS-GUEST-FILTER
-$cfg->setConfigEntry('user_status_guest_filter', 'ShipSimuUserStatusGuestFilter');
-
-// CFG: NEWS-HOME-LIMIT
-$cfg->setConfigEntry('news_home_limit', 10);
-
-// CFG: NEWS-LOGIN-AREA-LIMIT
-$cfg->setConfigEntry('news_login_area_limit', 15);
-
-// CFG: NEWS-GOVERNMENT-FAILED-LIMIT
-$cfg->setConfigEntry('news_government_failed_limit', 15);
-
-// CFG: LOGIN-ENABLED
-$cfg->setConfigEntry('login_enabled', 'Y');
-
-// CFG: CONFIRM-EMAIL-ENABLED
-$cfg->setConfigEntry('confirm_email_enabled', 'Y');
-
-// CFG: LOGIN-DISABLED-REASON
-$cfg->setConfigEntry('login_disabled_reason', 'Loginbereich befindet sich noch im Aufbau.');
-
-// CFG: LOGIN-TYPE
-$cfg->setConfigEntry('login_type', 'username'); // username, email, both
-
-// CFG: EMAIL-CHANGE-ALLOWED
-$cfg->setConfigEntry('email_change_allowed', 'Y');
-
-// CFG: EMAIL-CHANGE-CONFIRMATION
-$cfg->setConfigEntry('email_change_confirmation', 'Y');
-
-// CFG: GUEST-LOGIN-ALLOWED
-$cfg->setConfigEntry('guest_login_allowed', 'Y');
-
-// CFG: GUEST-LOGIN-USERNAME
-$cfg->setConfigEntry('guest_login_user', 'guest');
-
-// CFG: GUEST-LOGIN-PASS
-$cfg->setConfigEntry('guest_login_passwd', 'guest');
-
-// CFG: LOGIN-WELCOME-ACTION-CLASS
-$cfg->setConfigEntry('login_welcome_action_class', 'ShipSimuLoginAction');
-
-// CFG: LOGIN-LOGOUT-ACTION-CLASS
-$cfg->setConfigEntry('login_logout_action_class', 'ShipSimuLogoutAction');
-
-// CFG: LOGIN-PROFILE-ACTION-CLASS
-$cfg->setConfigEntry('login_profile_action_class', 'ShipSimuProfileAction');
-
-// CFG: SHIPSIMU-REGISTER-CAPTCHA
-$cfg->setConfigEntry('shipsimu_register_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-USER-LOGIN-CAPTCHA
-$cfg->setConfigEntry('shipsimu_user_login_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-GUEST-LOGIN-CAPTCHA
-$cfg->setConfigEntry('shipsimu_guest_login_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-PROFILE-CAPTCHA
-$cfg->setConfigEntry('shipsimu_profile_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-REFILL-CAPTCHA
-$cfg->setConfigEntry('shipsimu_refill_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-GOVERNMENT-STARTUP-CAPTCHA
-$cfg->setConfigEntry('shipsimu_government_startup_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: SHIPSIMU-GOVERNMENT-TRAINING-CAPTCHA
-$cfg->setConfigEntry('shipsimu_government_training_captcha', 'GraphicalCodeCaptcha');
-
-// CFG: CAPTCHA-STRING-LENGTH
-$cfg->setConfigEntry('captcha_string_length', 5);
-
-// CFG: CAPTCHA-SEARCH-CHARS
-$cfg->setConfigEntry('captcha_search_chars', '+/=');
-
-// CFG: RANDOM-STRING-LENGTH
-$cfg->setConfigEntry('random_string_length', 100);
-
-// CFG: SHIPSIMU-REGISTER-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_register_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-USER-LOGIN-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_user_login_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-GUEST-LOGIN-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_guest_login_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-PROFILE-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_profile_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-REFILL-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_refill_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-GOVERNMENT-STARTUP-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_government_startup_captcha_secured', 'Y');
-
-// CFG: SHIPSIMU-GOVERNMENT-TRAINING-CAPTCHA-SECURED
-$cfg->setConfigEntry('shipsimu_government_training_captcha_secured', 'Y');
-
-// CFG: BLOCK-SHOWS-REGISTRATION
-$cfg->setConfigEntry('block_shows_registration', 'Y');
-
-// CFG: COMPANY-CLASS
-$cfg->setConfigEntry('company_class', 'ShippingCompany');
-
-// CFG: COMPANY-DB-WRAPPER-CLASS
-$cfg->setConfigEntry('company_db_wrapper_class', 'CompanyDatabaseWrapper');
-
-// CFG: USER-POINTS-DB-WRAPPER-CLASS
-$cfg->setConfigEntry('user_points_db_wrapper_class', 'UserPointsDatabaseWrapper');
-
-// CFG: USER-GOVERNMENT-WRAPPER-CLASS
-$cfg->setConfigEntry('user_gov_wrapper_class', 'UserGovernmentDatabaseWrapper');
-
-// CFG: PAYMENT-DB-WRAPPER-CLASS
-$cfg->setConfigEntry('payment_db_wrapper_class', 'PaymentsDatabaseWrapper');
-
-// CFG EMAIl-TPL-RESEND-LINK
-$cfg->setConfigEntry('email_tpl_resend_link', 'text');
-
-// CFG: MAIL-TEMPLATE-CLASS
-$cfg->setConfigEntry('mail_template_class', 'MailTemplateEngine');
-
-// CFG: IMAGE-TEMPLATE-CLASS
-$cfg->setConfigEntry('image_template_class', 'ImageTemplateEngine');
-
-// CFG: MENU-TEMPLATE-CLASS
-$cfg->setConfigEntry('menu_template_class', 'MenuTemplateEngine');
-
-// CFG: MENU-TEMPLATE-EXTENSION
-$cfg->setConfigEntry('menu_template_extension', '.xml');
-
-// CFG: ADMIN-EMAIL
-$cfg->setConfigEntry('admin_email', 'you@some-hoster.invalid');
-
-// CFG: USER-CLASS
-$cfg->setConfigEntry('user_class', 'ShipSimuMember');
-
-// CFG: GUEST-CLASS
-$cfg->setConfigEntry('guest_class', 'ShipSimuGuest');
-
-// CFG: MAX-ALLOWED-COMPANIES-FOUND
-$cfg->setConfigEntry('max_allowed_companies_found', 10);
-
-// CFG: FOUND-NEW-COMPANY-ACTION-POINTS
-$cfg->setConfigEntry('found_new_company_action_points', 1000000);
-
-// CFG: WRITE-APPLICATION-ACTION-POINTS
-$cfg->setConfigEntry('write_applications_action_points', 10000);
-
-// CFG: USER-POINTS-CLASS
-$cfg->setConfigEntry('user_points_class', 'UserPoints');
-
-// CFG: GOVERNMENT-CLASS
-$cfg->setConfigEntry('government_class', 'SimplifiedGovernment');
-
-// CFG: BANK-CLASS
-$cfg->setConfigEntry('bank_class', 'MoneyBank');
-
-// CFG: REFILL-PAGE-ACTIVE
-$cfg->setConfigEntry('refill_page_active', 'Y');
-
-// CFG: REFILL-PAGE-MIN-CURRENCY-AMOUNT
-$cfg->setConfigEntry('refill_page_min_currency_amount', 1000);
-
-// CFG: SHIP-SIMU-LOGIN-FILL-PAYMENT-DISCOVERY
-$cfg->setConfigEntry('ship_simu_login_refill_payment_discovery', 'LocalPaymentDiscovery');
-
-// CFG: GOVERNMENT-STARTUP-HELP-LIMIT
-$cfg->setConfigEntry('government_startup_help_limit', 3);
-
-// CFG: GOVERNMENT-TRAINING-LIMIT
-$cfg->setConfigEntry('government_training_limit', 2);
-
-// CFG: WEB-BLOCK-HELPER
-$cfg->setConfigEntry('web_block_helper', 'WebBlockHelper');
-
-// CFG: WEB-FORM-HELPER
-$cfg->setConfigEntry('web_form_helper', 'WebFormHelper');
-
-// CFG: WEB-LINK-HELPER
-$cfg->setConfigEntry('web_link_helper', 'WebLinkHelper');
-
-// CFG: WEB-CMD-GOVERNMENT-FAILED-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_government_failed_resolver_class', 'WebGovernmentFailedCommandResolver');
-
-// CFG: WEB-CMD-LOGIN-FAILED-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_login_failed_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-COMPANY-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_company_resolver_class', 'WebCompanyCommandResolver');
-
-// CFG: WEB-CMD-HOME-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_home_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-REGISTER-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_register_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-DO-FORM-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_do_form_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-LOGIN-AREA-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_login_area_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-CONFIRM-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_confirm_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-PROBLEM-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_problem_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-LOGOUT-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_logout_resolver_class', 'WebCommandResolver');
-
-// CFG: WEB-CMD-LOGOUT-DONE-RESOLVER-CLASS
-$cfg->setConfigEntry('web_cmd_logout_done_resolver_class', 'WebCommandResolver');
-
-// CFG: REFILL-REQUEST-CURRENCY-PAYMENT-TYPE
-$cfg->setConfigEntry('refill_request_currency_payment_type', 'test');
-
-// CFG: LOGIN-REGISTER-LOGIN-FORM
-$cfg->setConfigEntry('login_register_login_form', 'index.php?app={?app_short_name?}&amp;page=register');
-
-// CFG: HOME-MENU-CLASS
-$cfg->setConfigEntry('home_menu_class', 'ShipSimuHomeMenu');
-
-// CFG: LOGIN-FAILED-MENU-CLASS
-$cfg->setConfigEntry('login_failed_menu_class', 'ShipSimuLoginFailedMenu');
-
-// CFG: STATUS-MENU-CLASS
-$cfg->setConfigEntry('status_menu_class', 'ShipSimuStatusMenu');
-
-// CFG: LOGIN-MENU-CLASS
-$cfg->setConfigEntry('login_menu_class', 'ShipSimuLoginMenu');
-
-// CFG: LOGOUT-MENU-CLASS
-$cfg->setConfigEntry('logout_menu_class', 'ShipSimuLogoutMenu');
-
-// CFG: REGISTER-MENU-CLASS
-$cfg->setConfigEntry('register_menu_class', 'ShipSimuRegisterMenu');
-
-// CFG: CONFIRM-MENU-CLASS
-$cfg->setConfigEntry('confirm_menu_class', 'ShipSimuConfirmMenu');
-
-// CFG: LOGIN-AREA-MENU-CLASS
-$cfg->setConfigEntry('login_area_menu_class', 'ShipSimuLoginAreaMenu');
-
-// CFG: GOVERNMENT-FAILED-AREA-MENU-CLASS
-$cfg->setConfigEntry('government_failed_area_menu_class', 'ShipSimuGovernmentFailedAreaMenu');
-
-// CFG: MONEYBANK-ACTIVATED
-$cfg->setConfigEntry('moneybank_activated', 'Y');
-
-// CFG: MONEYBANK-OPENING-CLASS
-$cfg->setConfigEntry('moneybank_opening_class', 'MoneyBankRealtimeOpening');
-
-// [EOF]
-?>
diff --git a/application/ship-simu/data.php b/application/ship-simu/data.php
deleted file mode 100644 (file)
index 07cfe25..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-<?php
-/**
- * Application data
- *
- * Please remember that this include file is being loaded *before* the class
- * loader is loading classes from "exceptions", "interfaces" and "main"!
- *
- * You can prevent adding this application to the selector by uncommenting the
- * following line:
- *
- * if ((isset($this)) && (is_object($this)) && ($this->isClass("ApplicationSelector"))) { return; }
- *
- * isset() is required to prevent a warning and is_object() is highly required
- * when the application itself is requested in URL (hint: index.php?app=your_app)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Get config instance
-$cfg = FrameworkConfiguration::getSelfInstance();
-
-// Get an instance of the helper
-$app = call_user_func_array(
-       array($cfg->getConfigEntry('app_helper_class'), 'getSelfInstance'),
-       array()
-);
-
-// Set application name and version
-$app->setAppName("Ship-Simu Shipping Simulator");
-$app->setAppVersion("0.0.0");
-$app->setAppShortName("shipsimu");
-
-// [EOF]
-?>
diff --git a/application/ship-simu/debug.php b/application/ship-simu/debug.php
deleted file mode 100644 (file)
index 11bf631..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-<?php
-/**
- * Some debugging stuff for this application
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Reederei-Objekt debuggen
-//define('DEBUG_COMPANY_OBJ', true);
-// Hafen-Objekt debuggen
-//define('DEBUG_HARBOR_OBJ', true);
-// Schiff-Objekt debuggen
-//define('DEBUG_SHIP_OBJ', true);
-// Auftrag-Objekt debuggen
-//define('DEBUG_CONTRACT_OBJ', true);
-// Haendler-Objekt debuggen
-//define('DEBUG_MERCHANT_OBJ', true);
-// Personal-Objekt debuggen
-//define('DEBUG_PERSONELL_OBJ', true);
-// Personal debuggen
-//define('DEBUG_PERSONELL', true);
-// Reederei debuggen
-//define('DEBUG_COMPANY', true);
-// Mitarbeiter debuggen
-//define('DEBUG_COMPANY_EMPLOYEE', true);
-// Hafen debuggen
-//define('DEBUG_HARBOR', true);
-// Werft debuggen
-//define('DEBUG_SHIPYARD', true);
-// Schiff debuggen
-//define('DEBUG_SHIP', true);
-// Schiffstruktur debuggen
-//define('DEBUG_STRUCTURE', true);
-// Kabinen debuggen
-//define('DEBUG_CABIN', true);
-// Decks debuggen
-//define('DEBUG_DECK', true);
-// Bauauftraege debuggen
-//define('DEBUG_CONTRACT', true);
-// Haendler debuggen
-//define('DEBUG_MERCHANT', true);
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions.php b/application/ship-simu/exceptions.php
deleted file mode 100644 (file)
index d9cc8d9..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-<?php
-/**
- * The exception handler for this application
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Our own exception handler
-function __exceptionHandler (FrameworkException $e) {
-       // Call the app_die() method
-       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> (<span class=\"app_short_name\">%s</span>) has terminated due to an uncaught exception: <span class=\"exception_name\">%s</span> <span class=\"exception_number\">[%s]</span>: <span class=\"debug_exception\">%s</span> Backtrace: <div class=\"debug_backtrace\">%s</div>",
-               ApplicationHelper::getSelfInstance()->getAppName(),
-               ApplicationHelper::getSelfInstance()->getAppShortName(),
-               $e->__toString(),
-               $e->getHexCode(),
-               $e->getMessage(),
-               $e->getPrintableBackTrace()
-       ),
-               $e->getHexCode(),
-               $e->getExtraData()
-       );
-} // END - function
-
-// Set the new handler
-set_exception_handler('__exceptionHandler');
-
-// Error handler
-function __errorHandler ($errno, $errstr, $errfile, $errline, array $errcontext) {
-       // Construct the message
-       $message = sprintf("File: <span class=\"debug_file\">%s</span>, Line: <span class=\"debug_line\">%s</span>, Code: <span class=\"debug_code\">%s</span>, Message: <span class=\"debug_message\">%s</span>",
-               basename($errfile),
-               $errline,
-               $errno,
-               $errstr
-       );
-
-       // Throw an exception here
-       throw new FatalErrorException($message, BaseFrameworkSystem::EXCEPTION_FATAL_ERROR);
-} // END - function
-
-// Set error handler
-set_error_handler('__errorHandler');
-
-// Assertion handler
-function __assertHandler ($file, $line, $code) {
-       // Empty code?
-       if ($code === "") $code = "<em>Unknown</em>";
-
-       // Create message
-       $message = sprintf("File: <span class=\"debug_file\">%s</span>, Line: <span class=\"debug_line\">%s</span>, Code: <span class=\"debug_code\">%s</span>",
-               basename($file),
-               $line,
-               $code
-       );
-
-       // Throw an exception here
-       throw new AssertionException($message, BaseFrameworkSystem::EXCEPTION_ASSERTION_FAILED);
-} // END - function
-
-// Init assert handling
-assert_options(ASSERT_ACTIVE,     1);
-assert_options(ASSERT_WARNING,    0);
-assert_options(ASSERT_BAIL,       0);
-assert_options(ASSERT_QUIET_EVAL, 0);
-assert_options(ASSERT_CALLBACK,   '__assertHandler');
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/.htaccess b/application/ship-simu/exceptions/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/exceptions/class_BirthdayInvalidException.php b/application/ship-simu/exceptions/class_BirthdayInvalidException.php
deleted file mode 100644 (file)
index ed8e189..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-/**
- * An exception for invalid birthdays (like 13-01-2008)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BirthdayInvalidException extends FrameworkException {
-       public function __construct (array $birthArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("Das Geburtsdatum <span class=\"exception_reason\">%s</span> ist leider falsch.",
-                       date("d.m.Y", mktime(
-                               0, 0, 0,
-                               $birthArray[1],
-                               $birthArray[2],
-                               $birthArray[0]
-                       ))
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_CabinShipMismatchException.php b/application/ship-simu/exceptions/class_CabinShipMismatchException.php
deleted file mode 100644 (file)
index 6b9120b..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception for cabins which doesn't match the ship (why?)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 CabinShipMismatchException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ContractAllreadySignedException.php b/application/ship-simu/exceptions/class_ContractAllreadySignedException.php
deleted file mode 100644 (file)
index fc17f64..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/**
- * An exception thrown when the contract we want to sign is already signed
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ContractAllreadySignedException extends FrameworkException {
-       public function __construct (array $classArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Die Vertragsparteien <span class=\"exception_reason\">%s</span> und <span class=\"exception_reason\">%s</span> haben den Vertrag bereits unterzeichnet!",
-                       $classArray[0]->__toString(),
-                       $classArray[1]->getCompanyName(),
-                       $classArray[2]->getCompanyName()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ContractPartnerMismatchException.php b/application/ship-simu/exceptions/class_ContractPartnerMismatchException.php
deleted file mode 100644 (file)
index fce9748..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/**
- * An exception thrown when the contract partner did not match the excepted one
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ContractPartnerMismatchException extends FrameworkException {
-       public function __construct (array $classArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Der Vertragspartner von <span class=\"exception_reason\">%s</span> ist ung&uuml;tig (<span class=\"exception_reason\">%s</span>) und darf diesen Vertrag nicht unterzeichnen!",
-                       $classArray[0]->__toString(),
-                       $classArray[1]->getCompanyName(),
-                       $classArray[2]->getCompanyName()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_DeckShipMismatchException.php b/application/ship-simu/exceptions/class_DeckShipMismatchException.php
deleted file mode 100644 (file)
index 937cd6e..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception thrown when the deck mismatches the ship (why?)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 DeckShipMismatchException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_EmptyStructuresListException.php b/application/ship-simu/exceptions/class_EmptyStructuresListException.php
deleted file mode 100644 (file)
index 9c1eee2..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the structure list is empty
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 EmptyStructuresListException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Die Strukturen-Liste ist leer.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_InvalidContractPartnerException.php b/application/ship-simu/exceptions/class_InvalidContractPartnerException.php
deleted file mode 100644 (file)
index 8f4823e..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the contract partner is invalid
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 InvalidContractPartnerException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Kein g&uuml;tiger Vertragspartner.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_InvalidIDFormatException.php b/application/ship-simu/exceptions/class_InvalidIDFormatException.php
deleted file mode 100644 (file)
index 78e2e00..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the format of the id number is invalid
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 InvalidIDFormatException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Ung&uuml;ltige ID-Nummer &uuml;bergeben.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ItemNotInPriceListException.php b/application/ship-simu/exceptions/class_ItemNotInPriceListException.php
deleted file mode 100644 (file)
index 0013e92..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the requested item is not in pricing list
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 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 class=\"exception_reason\">%s</span> nicht gefunden.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ItemNotTradeableException.php b/application/ship-simu/exceptions/class_ItemNotTradeableException.php
deleted file mode 100644 (file)
index 074f17e..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when an item is not tradeable (maybe unneccessary)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ItemNotTradeableException extends FrameworkException {
-       public function __construct (array $classArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Object not tradeable.",
-                       $classArray[0]->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_MissingSimulatorIdException.php b/application/ship-simu/exceptions/class_MissingSimulatorIdException.php
deleted file mode 100644 (file)
index 09a55f3..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/**
- * An exception thrown when the provided simulator id is invalid
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 MissingSimulatorIdException extends FrameworkException {
-       public function __construct (array $classArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Die Simulator-ID <span class=\"exception_reason\">%s</span> scheint ung&uuml;ltig zu sein.",
-                       $classArray[0]->__toString(),
-                       $classArray[1]
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_MotorShipMismatchException.php b/application/ship-simu/exceptions/class_MotorShipMismatchException.php
deleted file mode 100644 (file)
index 7e688c2..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception thrown when the motor does not match the ship (why?)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 MotorShipMismatchException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_NoShippingCompanyOwnedException.php b/application/ship-simu/exceptions/class_NoShippingCompanyOwnedException.php
deleted file mode 100644 (file)
index 848362e..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-<?php
-/**
- * An exception thrown when a user owns no shipping companies
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 NoShippingCompanyOwnedException extends FrameworkException {
-       /**
-        * Constructor of this exception
-        *
-        * @param       $msgArray       Message array with exception data
-        * @param       $code           Exception code
-        * @return      void
-        */
-       public function __construct (array $msgArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:%d] Current user (class <span class=\"exception_reason\">%s</span>) does not own any shipping companies.",
-                       $msgArray[0]->__toString(),
-                       $this->getLine(),
-                       $msgArray[1]->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php b/application/ship-simu/exceptions/class_NoShipyardsConstructedException.php
deleted file mode 100644 (file)
index 52cf913..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-/**
- * An exception thrown when there are no shipyards constructed yet.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 NoShipyardsConstructedException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // No class given
-               $message = sprintf("Please provide a class for <span class=\"exception_reason\">%s</span>", __CLASS__);
-               if (is_object($class)) {
-                       // Add a message around the missing class
-                       $message = sprintf("[%s:] Keine Werften gefunden!",
-                               $class->__toString()
-                       );
-               } // END - if
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php b/application/ship-simu/exceptions/class_PersonellListAlreadyCreatedException.php
deleted file mode 100644 (file)
index c89dc44..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when a crew list has already been initialized
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 PersonellListAlreadyCreatedException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Die interne Crew-Liste wurde bereits initialisiert.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_RoomShipMismatchException.php b/application/ship-simu/exceptions/class_RoomShipMismatchException.php
deleted file mode 100644 (file)
index d84528c..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception thrown when a room mismatches the ship (why?)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 RoomShipMismatchException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ShipNotConstructedException.php b/application/ship-simu/exceptions/class_ShipNotConstructedException.php
deleted file mode 100644 (file)
index 3313c36..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception thrown when a ship is not constructed (yet)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipNotConstructedException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ShipPartNotConstructableException.php b/application/ship-simu/exceptions/class_ShipPartNotConstructableException.php
deleted file mode 100644 (file)
index 48b4fe7..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the ship part is not constructed yet.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipPartNotConstructableException extends FrameworkException {
-       public function __construct (array $partArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("Schiffteil <span class=\"exception_reason\">%s</span> ist nicht constrierbar!",
-                       $partArray[0]
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_StructureShipMismatchException.php b/application/ship-simu/exceptions/class_StructureShipMismatchException.php
deleted file mode 100644 (file)
index 62152e8..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An exception thrown when a structure does not match the ship (why?)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 StructureShipMismatchException extends FrameworkException {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_StructuresOutOfBoundsException.php b/application/ship-simu/exceptions/class_StructuresOutOfBoundsException.php
deleted file mode 100644 (file)
index 916207f..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * An exception thrown when the ship part index is out of bounds
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 StructuresOutOfBoundsException extends FrameworkException {
-       public function __construct ($idx, $code) {
-               // Add a message around the missing class
-               $message = sprintf("Der Index <span class=\"exception_reason\">%s</span> liegt ausserhalb des g&uuml;tigen Bereiches! Schiffsteil nicht auffindbar.", $idx);
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_ToMuchEmployeesException.php b/application/ship-simu/exceptions/class_ToMuchEmployeesException.php
deleted file mode 100644 (file)
index a6bffb0..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/**
- * An exception thrown when to less people are unemployed and cannot be recruited
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ToMuchEmployeesException extends FrameworkException {
-       public function __construct (array $amountArray, $code) {
-               // Add a message around the missing class
-               $message = sprintf("<u>%d</u> Leute nicht einstellbar, da nur <u>%d</u> arbeitslos sind!",
-                       $amountArray[0],
-                       $amountArray[1]
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php b/application/ship-simu/exceptions/class_TotalPriceNotCalculatedException.php
deleted file mode 100644 (file)
index 7aa57ae..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * An exception thrown when the total price was not calculated
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 TotalPriceNotCalculatedException extends FrameworkException {
-       public function __construct (FrameworkInterface $class, $code) {
-               // Add a message around the missing class
-               $message = sprintf("[%s:] Gesamtpreis ist nicht ermittelbar.",
-                       $class->__toString()
-               );
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_UnsupportedLimitationPartException.php b/application/ship-simu/exceptions/class_UnsupportedLimitationPartException.php
deleted file mode 100644 (file)
index ee7aa5a..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * An exception thrown when the limitation type is not supported
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 UnsupportedLimitationPartException extends FrameworkException {
-       public function __construct ($str, $code) {
-               // Add a message around the missing class
-               $message = sprintf("Limitierungsinformation <span class=\"exception_reason\">%s</span> wird derzeit nicht unterst&uuml;tzt.", $str);
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/exceptions/class_WrongGenderSpecifiedException.php b/application/ship-simu/exceptions/class_WrongGenderSpecifiedException.php
deleted file mode 100644 (file)
index 306a680..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * An exception thrown when a wrong gender was specified
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WrongGenderSpecifiedException extends FrameworkException {
-       public function __construct ($gender, $code) {
-               // Add a message around the missing class
-               $message = sprintf("Das Geschlecht <span class=\"exception_reason\">%s</span> Ist nicht <em>M</em> (M&auml;nnlich) oder <em>F</em> (Weiblich).", $gender);
-
-               // Call parent constructor
-               parent::__construct($message, $code);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/init.php b/application/ship-simu/init.php
deleted file mode 100644 (file)
index d27a1f5..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-/**
- * Application initializer
- *
- * Please remember that this include file is being loaded *before* the class
- * loader is loading classes from "exceptions", "interfaces" and "main"!
- *
- * You can prevent adding this application to the selector by uncommenting the
- * following line:
- *
- * if ((isset($this)) && (is_object($this)) && ($this->isClass("ApplicationSelector"))) { return; }
- *
- * isset() is required to prevent a warning and is_object() is highly required
- * when the application itself is requested in URL (hint: index.php?app=your_app)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Get config instance
-$cfg = FrameworkConfiguration::getSelfInstance();
-
-// Initialize output system
-require($cfg->getConfigEntry('base_path') . 'inc/output.php');
-
-// This application needs a database connection then we have to simply include
-// the inc/database.php script
-require($cfg->getConfigEntry('base_path') . 'inc/database.php');
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/.htaccess b/application/ship-simu/interfaces/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/interfaces/class_BookableAccount.php b/application/ship-simu/interfaces/class_BookableAccount.php
deleted file mode 100644 (file)
index 3f3a575..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * An interface for bookable user accounts
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface BookableAccount extends FrameworkInterface {
-       /**
-        * Books the given 'amount' in the request instance on the users "points
-        * account"
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @return      void
-        */
-       function bookAmountDirectly (Requestable $requestInstance);
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_ConstructableShip.php b/application/ship-simu/interfaces/class_ConstructableShip.php
deleted file mode 100644 (file)
index db76fd5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An interface for constructable ships
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface ConstructableShip extends FrameworkInterface {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_ConstructableShipPart.php b/application/ship-simu/interfaces/class_ConstructableShipPart.php
deleted file mode 100644 (file)
index 8135bc3..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-/**
- * An interface for constructable ship parts
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface ConstructableShipPart extends FrameworkInterface {
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_ContractPartner.php b/application/ship-simu/interfaces/class_ContractPartner.php
deleted file mode 100644 (file)
index 35b4b6d..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * An interface for contract partners
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface ContractPartner extends FrameworkInterface {
-       /**
-        * This is a contract partner
-        *
-        * @param       $contractInstance       Must be a valid instance of WorksContract
-        * @return      boolean                 true  = can be a contract partner,
-        *                                                      false = no partner for contracts
-        */
-       function isContractPartner (SignableContract $contractInstance);
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_Customer.php b/application/ship-simu/interfaces/class_Customer.php
deleted file mode 100644 (file)
index 5de5210..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-<?php
-/**
- * An interface for all customers
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface Customer extends FrameworkInterface {
-       /**
-        * Adds a contract to the customer's list
-        *
-        * @param       $contractInstance       A valid instance to WorksContract
-        * @return      void
-        */
-       function addNewWorksContract (SignableContract $contractInstance);
-
-       /**
-        * Signs a works contract.
-        *
-        * @param       $contractInstance       A valid instance to WorksContract
-        * @param       $partnerInstance        An instance the other contract partner
-        * @return      void
-        * @throws      InvalidContractPartnerException         If the in $contractInstance
-        *                                                                              set contract partner is
-        *                                                                              not the expected
-        */
-       function signContract (SignableContract $contractInstance, ContractPartner $partnerInstance);
-
-       /**
-        * Withdraw from a signed contract
-        *
-        * @param       $contractInstance       A valid instance to WorksContract
-        * @return      void
-        */
-       function withdrawFromContract (SignableContract $contractInstance);
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_Personellizer.php b/application/ship-simu/interfaces/class_Personellizer.php
deleted file mode 100644 (file)
index b56df14..0000000
+++ /dev/null
@@ -1,200 +0,0 @@
-<?php
-/**
- * An interface for all personells
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface Personellizer extends FrameworkInterface {
-         ///////////////////////
-        /// General methods ///
-       ///////////////////////
-
-       /**
-        * Remove min/max age
-        *
-        * @return      void
-        */
-       function removeMinMaxAge ();
-
-       /**
-        * Create a valid birthday
-        *
-        * @return void
-        */
-       function createBirthday ();
-
-       /**
-        * Verify if given year/month/day is a valid date combination
-        *
-        * @param               $year   4-digit year (valid  : 2007, 1946,
-        *                                                    invalid: 24, 2a, aa)
-        * @param               $month  1 to 2-digit month (range: 1 to 12)
-        * @param               $day            1 to 2-digit day (range: 1 to 31/30/29/28)
-        * @return      boolean true  = date is valid,
-        *                                      false = date is invalid
-        */
-       function isDateValid ($year, $month, $day);
-
-               /////////////////////////
-        //// Status requests ////
-       /////////////////////////
-
-       /**
-        * Is the person employed?
-        *
-        * @return      boolean true  = person is employed
-        *                                      false = person is umemployed
-        */
-       function isEmployed ();
-
-       /**
-        * Is the person married? (to which one doesn't matter here)
-        *
-        * @return      boolean true  = person is married
-        *                                      false = person is not married
-        */
-       function isMarried ();
-
-       /**
-        * Is the person a male?
-        *
-        * @return      boolean true  = person is male
-        *                                      false = person is not male (maybe female? ;-))
-        */
-       function isMale ();
-
-       /**
-        * Is the person a female?
-        *
-        * @return      boolean true  = person is female
-        *                                      false = person is not female (maybe male? ;-))
-        */
-       function isFemale ();
-
-               /////////////////
-        //// Getters ////
-       /////////////////
-
-       /**
-        * Getter for surname
-        *
-        * @return      $surname        The person's surname
-        */
-       function getSurname ();
-
-       /**
-        * Getter for family name
-        *
-        * @return      $family The person's family name
-        */
-       function getFamily ();
-
-       /**
-        * Getter for gender
-        *
-        * @return      $gender The person's gender (F/M)
-        */
-       function getGender ();
-
-       /**
-        * Getter for salary
-        *
-        * @return      $salary The person's current salary
-        */
-       function getSalary ();
-
-               /////////////////
-        //// Setters ////
-       /////////////////
-
-       /**
-        * Setter for surname
-        *
-        * @param               $surname        The person's new surname as a string
-        * @return      void
-        */
-       function setSurname ($surname);
-
-       /**
-        * Setter for family name
-        *
-        * @param               $family The person's new family name as a string
-        * @return      void
-        */
-       function setFamily ($family);
-
-       /**
-        * Setter for gender. Do not use this so often... ;-)
-        * This method shall only be used when the person is "created"
-        *
-        * @param               $gender The person's new gender as a 1-char string (M/F)
-        * @return      void
-        */
-       function setGender ($gender);
-
-       /**
-        * Setter for employment status
-        *
-        * @param               $employed       The person's new employment stats
-        * @return      void
-        */
-       function setEmployed ($employed);
-
-       /**
-        * Setter for marrital status
-        *
-        * @param               $married        The person's new marrital status
-        * @return      void
-        */
-       function setMarried ($married);
-
-       /**
-        * Setter for a already validated birthday.
-        *
-        * @param               $year   The person's new year-of-birth (4 digits)
-        * @param               $month  The person's new month-of-birth (1 to 2 digits)
-        * @param               $day            The person's new day-of-birth (1 to 2 digits)
-        * @return      void
-        */
-       function setBirthday ($year, $month, $day);
-
-               /////////////////////////////////////
-        //// Methods for changing salary ////
-       /////////////////////////////////////
-
-       /**
-        * Increase person's salary by a specified amount
-        *
-        * @param               $add            Add this float amount to current salary
-        * @return      void
-        */
-       function increaseSalary ($add);
-
-       /**
-        * Decrease person's salary by a specified amount
-        *
-        * @param               $sub            Subtract this float amount to current salary
-        * @return      void
-        */
-       function decreaseSalary ($sub);
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/interfaces/class_SignableContract.php b/application/ship-simu/interfaces/class_SignableContract.php
deleted file mode 100644 (file)
index a8f62ce..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-/**
- * An interface for signable contracts
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface SignableContract extends FrameworkInterface {
-       // Sign the contract
-       function signContract (ContractPartner $partnerInstance, ContractPartner $partyInstance);
-}
-
-// [EOF]
-?>
\ No newline at end of file
diff --git a/application/ship-simu/interfaces/class_TradeableItem.php b/application/ship-simu/interfaces/class_TradeableItem.php
deleted file mode 100644 (file)
index f850be2..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * An interface for tradeable items
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-interface TradeableItem extends FrameworkInterface {
-       /**
-        * Is this item (=object) tradeable?
-        *
-        * @return      boolean true  = is a tradeable object,
-        *                                      false = is not tradeable
-        */
-       function isTradeable ();
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/loader.php b/application/ship-simu/loader.php
deleted file mode 100644 (file)
index d28600b..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/**
- * A specialized class loader for this class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Get config instance
-$cfg = FrameworkConfiguration::getSelfInstance();
-
-// Load all classes for the application
-foreach ($lowerClasses as $className) {
-       // Load the application classes
-       ClassLoader::getSelfInstance()->scanClassPath(sprintf("%s/%s/%s", $cfg->getConfigEntry('application_path'), $cfg->getConfigEntry('app_name'), $className));
-} // END - if
-
-// Clean up the global namespace
-unset($lowerClasses);
-unset($className);
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/.htaccess b/application/ship-simu/main/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/actions/.htaccess b/application/ship-simu/main/actions/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/actions/class_ b/application/ship-simu/main/actions/class_
deleted file mode 100644 (file)
index d84fab7..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-/**
- * 
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 ???Action extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public final static function create???Action (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new ???Action();
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here
-               $this->partialStub("You have to implement me.");
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Call parent addExtraFilters method
-               parent::addExtraFilters($controllerInstance, $requestInstance);
-
-               // Unfinished method
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/class_BaseShipSimuAction.php b/application/ship-simu/main/actions/class_BaseShipSimuAction.php
deleted file mode 100644 (file)
index 41dcce0..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-/**
- * A general action class for blog
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseShipSimuAction extends BaseAction {
-       /**
-        * Protected constructor
-        *
-        * @param       $className      Name of the class
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       protected function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Add code here executed with every action
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Unfinished method
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/ship-simu/.htaccess b/application/ship-simu/main/actions/ship-simu/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/actions/ship-simu/class_ShipSimuLoginAction.php b/application/ship-simu/main/actions/ship-simu/class_ShipSimuLoginAction.php
deleted file mode 100644 (file)
index 2fbee37..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-<?php
-/**
- * An action class for the login welcome page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLoginAction extends BaseShipSimuAction implements PerformableAction {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createShipSimuLoginAction () {
-               // Get a new instance
-               $actionInstance = new ShipSimuLoginAction();
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Maybe we need to do something later here
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/ship-simu/class_ShipSimuProfileAction.php b/application/ship-simu/main/actions/ship-simu/class_ShipSimuProfileAction.php
deleted file mode 100644 (file)
index 56090bf..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-<?php
-/**
- * An action class for the profile page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuProfileAction extends BaseShipSimuAction implements PerformableAction {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createShipSimuProfileAction () {
-               // Get a new instance
-               $actionInstance = new ShipSimuProfileAction();
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Maybe we need to do something later here
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/.htaccess b/application/ship-simu/main/actions/web/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLogin b/application/ship-simu/main/actions/web/class_WebShipSimuLogin
deleted file mode 100644 (file)
index d60f442..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-/**
- * An action for 
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 WebShipSimuLogin???Action extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public final static function createWebShipSimuLogin???Action (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLogin???Action();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute parent method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginCompanyAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginCompanyAction.php
deleted file mode 100644 (file)
index 842d6cb..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-/**
- * An action for shipping company page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginCompanyAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginCompanyAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginCompanyAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Maybe add fetching company list of current user here?
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some more filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php
deleted file mode 100644 (file)
index fa62481..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-<?php
-/**
- * An action for government startup help form
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginGovernmentStartupHelpAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginGovernmentStartupHelpAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginGovernmentStartupHelpAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Check if government can pay startup help
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_startup_help_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php
deleted file mode 100644 (file)
index fcbc711..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-<?php
-/**
- * An action for trainings payed by government
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginGovernmentTrainingAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginGovernmentTrainingAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginGovernmentTrainingAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some more filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Check if government can pay a training
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_training_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginLogoutAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginLogoutAction.php
deleted file mode 100644 (file)
index 9b066a9..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-<?php
-/**
- * An action for logout
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginLogoutAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginLogoutAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginLogoutAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginProfileAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginProfileAction.php
deleted file mode 100644 (file)
index 58d6745..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-/**
- * An action for profile (editing) page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginProfileAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginProfileAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginProfileAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginRefillAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginRefillAction.php
deleted file mode 100644 (file)
index 31c7337..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-<?php
-/**
- * An action for money refill page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginRefillAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginRefillAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginRefillAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Is the refill page active?
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_page_filter'));
-
-               // Add payment discovery filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('payment_discovery_filter', array($this)));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php
deleted file mode 100644 (file)
index 8b26b8f..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-/**
- * An action for 
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginStatusProblemAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginStatusProblemAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginStatusProblemAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Check for user status by default
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php b/application/ship-simu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php
deleted file mode 100644 (file)
index d839bd1..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-<?php
-/**
- * An action for the welcome page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuLoginWelcomeAction extends BaseShipSimuAction implements Commandable, Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this action
-        *
-        * @param       $resolverInstance       An instance of an action resolver
-        * @return      $actionInstance         An instance of this action class
-        */
-       public static final function createWebShipSimuLoginWelcomeAction (ActionResolver $resolverInstance) {
-               // Get a new instance
-               $actionInstance = new WebShipSimuLoginWelcomeAction();
-
-               // Set the resolver instance
-               $actionInstance->setResolverInstance($resolverInstance);
-
-               // Return the instance
-               return $actionInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Call parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Add your code here...
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some filters here
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Unfinished method
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/bank/.htaccess b/application/ship-simu/main/bank/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/bank/class_BaseBank.php b/application/ship-simu/main/bank/class_BaseBank.php
deleted file mode 100644 (file)
index 21ae0d5..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-<?php
-/**
- * A general bank class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.org
- * @todo               Find an instance for all banks and move the abstract functions there
- *
- * 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/>.
- */
-abstract class BaseBank extends BaseFrameworkSystem {
-       /**
-        * Protected constructor
-        *
-        * @param       $className      The class' real name
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Checks wether the bank lends more money to the current user
-        *
-        * @return      $lendsMoreMoney         Wether this bank lends more money to the user
-        */
-       public abstract function ifBankLendsMoreMoney ();
-
-       /**
-        * Checks wethert the current user has maximum allowed credits with this bank
-        *
-        * @return      $hasMaximumCredits      Wether the user has maximum allowed credits
-        */
-       public abstract function ifUserHasMaxCredits ();
-
-       /**
-        * Checks wether this money bank has opened
-        *
-        * @return      $hasOpened      Wether this money bank has opened
-        */
-       public abstract function ifMoneyBankHasOpened ();
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/bank/money/class_MoneyBank.php b/application/ship-simu/main/bank/money/class_MoneyBank.php
deleted file mode 100644 (file)
index 11d4d9e..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-<?php
-/**
- * A money bank which may lend points to the user
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 MoneyBank extends BaseBank implements Registerable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this money bank class
-        *
-        * @param       $userInstance   A class instance of a user object
-        * @return      $bankInstance   An instance of this class
-        */
-       public static final function createMoneyBank (ManageableAccount $userInstance) {
-               // Get a new instance
-               $moneyInstance = new MoneyBank();
-
-               // Set the user instance
-               $moneyInstance->setUserInstance($userInstance);
-
-               // Return the prepared instance
-               return $moneyInstance;
-       }
-
-       /**
-        * Checks wether the bank lends more money to the current user
-        *
-        * @return      $lendsMoreMoney         Wether this bank lends more money to the user
-        */
-       public function ifBankLendsMoreMoney () {
-               $this->partialStub();
-       }
-
-       /**
-        * Checks wethert the current user has maximum allowed credits with this bank
-        *
-        * @return      $hasMaximumCredits      Wether the user has maximum allowed credits
-        */
-       public function ifUserHasMaxCredits () {
-               $this->partialStub();
-       }
-
-       /**
-        * Checks wether this money bank has opened
-        *
-        * @return      $hasOpened      Wether this money bank has opened
-        */
-       public function ifMoneyBankHasOpened () {
-               // Has not opened by default
-               $hasOpened = false;
-
-               // Is the money bank activated in config?
-               if ($this->getConfigInstance()->getConfigEntry('moneybank_activated')) {
-                       // Okay, does the user ask within the opening times? To find this out we need a OpeningTimes class
-                       $openingInstance = ObjectFactory::createObjectByConfiguredName('moneybank_opening_class', array($this));
-
-                       // Then we simply "ask" the opening time instance if the user asks within the opening time
-                       $hasOpened = $openingInstance->ifWithinOpeningTimes();
-               } // END - if
-
-               // Return status
-               return $hasOpened;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/class_ b/application/ship-simu/main/class_
deleted file mode 100644 (file)
index 956f6c5..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * 
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 ??? extends BaseFrameworkSystem {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this money bank class
-        *
-        * @return      $???Instance    An instance of this class
-        */
-       public final static function create??? () {
-               // Get a new instance
-               $???Instance = new ???();
-
-               // Return the prepared instance
-               return $???Instance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/class_BasePersonell.php b/application/ship-simu/main/class_BasePersonell.php
deleted file mode 100644 (file)
index 8e08ec3..0000000
+++ /dev/null
@@ -1,246 +0,0 @@
-<?php
-/**
- * A general class for personell
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BasePersonell extends BaseFrameworkSystem implements Personellizer {
-       // Maximum/minimum age
-       private $MIN_AGE = 21;
-       private $MAX_AGE = 40;
-
-       // Male/female
-       private $gender     = ""; // M=Male, F=Female, empty=uninitialized
-
-       // Year/month/day of birth
-       private $yearBirth  = 0;
-       private $monthBirth = 0;
-       private $dayBirth   = 0;
-
-       // Surname/family name
-       private $surname    = "";
-       private $family     = "";
-
-       // Employed?
-       private $employed   = false;
-
-       // Married?
-       private $married    = false;
-
-       // Her/his salary
-       private $salary     = 0.00;
-
-       // Constructor
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Remove min/max ages
-       public final function removeMinMaxAge () {
-               unset($this->MIN_AGE);
-               unset($this->MAX_AGE);
-       }
-
-       // Generates a birthday based on MAX_AGE/MIN_AGE and the current date
-       public final function createBirthday () {
-               // Is the birthday already set?
-               if ($this->isDateValid($this->yearBirth, $this->monthBirth, $this->dayBirth)) return false;
-
-               // Get current year
-               $currYear = date("Y", time());
-
-               // Generate random year/month/day
-               $year = mt_rand(($currYear - $this->MIN_AGE), ($currYear - $this->MAX_AGE));
-               $month = 0;
-               $day = 0;
-               while ($this->isDateValid($year, $month, $day) === false) {
-                       $month = mt_rand(1, 12);
-                       switch ($month) {
-                       case 1:
-                       case 3:
-                       case 5:
-                       case 7:
-                       case 8:
-                       case 10:
-                       case 12:
-                               $day   = mt_rand(1, 31);
-                               break;
-
-                       case 4:
-                       case 6:
-                       case 9:
-                       case 11:
-                               $day   = mt_rand(1, 30);
-                               break;
-
-                       case 2: // February
-                               if ($year % 4 == 0) {
-                                       // Is a "Schaltjahr"
-                                       $day = mt_rand(1, 29);
-                               } else {
-                                       // Regular year
-                                       $day = mt_rand(1, 28);
-                               }
-                               break;
-                       } // END - switch
-               } // END - while
-
-               // Set the new birthday
-               $this->setBirthday($year, $month, $day);
-       }
-
-       // Is the current day valid?
-       public final function isDateValid ($year, $month, $day) {
-               // Create timestamp
-               $stamp = mktime(0, 0, 0, $month, $day, $year);
-
-               // Get year/month/day back
-               $y = date("Y", $stamp);
-               $m = date("m", $stamp);
-               $d = date("d", $stamp);
-
-               // Compare all
-               return (($y == $year) && ($m == $month) && ($d == $day));
-       }
-
-       // Employed?
-       public final function isEmployed () {
-               return $this->employed;
-       }
-
-       // Married?
-       public final function isMarried () {
-               return $this->married;
-       }
-
-       // Male?
-       public final function isMale () {
-               return ($this->gender == "M");
-       }
-
-       // Female
-       public final function isFemale () {
-               return ($this->gender == "F");
-       }
-
-       // Setter for surname
-       public final function setSurname ($surname) {
-               $this->surname = (string) $surname;
-       }
-
-       // Getter for surname
-       public function getSurname () {
-               return $this->surname;
-       }
-
-       // Setter for family name
-       public final function setFamily ($family) {
-               $this->family = (string) $family;
-       }
-
-       // Getter for family name
-       public final function getFamily () {
-               return $this->family;
-       }
-
-       // Setter for gender
-       public final function setGender ($gender) {
-               // Set random gender here
-               if (($gender == "M") || ($gender == "F") || ((empty($gender)) && ($this->getSurname() == ""))) {
-                       $this->gender = $gender;
-               } else {
-                       throw new WrongGenderSpecifiedException($gender, self::EXCEPTION_GENDER_IS_WRONG);
-               }
-       }
-
-       // Getter for gender
-       public final function getGender () {
-               return $this->gender;
-       }
-
-       // Setter for employment status
-       public final function setEmployed ($employed) {
-               $this->employed = (boolean) $employed;
-       }
-
-       // Setter for marriage status
-       public final function setMarried ($married) {
-               $this->married = (boolean) $married;
-       }
-
-       // Getter for salary
-       public final function getSalary () {
-               return $this->salary;
-       }
-
-       // Increase salary
-       public final function increaseSalary ($add) {
-               $this->salary += (float) abs($add);
-       }
-
-       // Decrease salary
-       public final function decreaseSalary ($sub) {
-               $this->salary -= (float) abs($sub);
-       }
-
-       // Setter for birthday
-       public final function setBirthday ($year, $month, $day) {
-               $this->yearBirth  = (int) abs($year);
-               $this->monthBirth = (int) abs($month);
-               $this->dayBirth   = (int) abs($day);
-       }
-
-       // Remove gender
-       public final function removeGender () {
-               unset($this->gender);
-       }
-
-       // Remove both names
-       public final function removeNames () {
-               unset($this->surname);
-               unset($this->family);
-       }
-
-       // Remove complete birthday
-       public final function removeBirthday () {
-               unset($this->yearBirth);
-               unset($this->monthBirth);
-               unset($this->dayBirth);
-       }
-
-       // Remove salary
-       public final function removeSalary () {
-               unset($this->salary);
-       }
-
-       // Remove employment status
-       public final function removeEmployed () {
-               unset($this->employed);
-       }
-
-       // Remove marrital status
-       public final function removeMarried () {
-               unset($this->married);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/class_BaseSimulator.php b/application/ship-simu/main/class_BaseSimulator.php
deleted file mode 100644 (file)
index e460013..0000000
+++ /dev/null
@@ -1,302 +0,0 @@
-<?php
-/**
- * The general simulator class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseSimulator extends BaseFrameworkSystem {
-       // Schiffsteilinstanz
-       private $partInstance = null;
-
-       // Abmasse (Breite/Hoehe/Laenge)
-       private $width  = 0;
-       private $height = 0;
-       private $length = 0;
-
-       // Aktuelles Schiff und Schiffsteil
-       private $currShip = null;
-       private $currPart = null;
-
-       // Faktoren zur Erweiterung der Masse. Beispielsweise soll der Maschinenraum groesser wie der Motor sein
-       private $resizeFactorArray = array(
-               'width'  => 1,
-               'height' => 1,
-               'length' => 1
-       );
-
-       // Konstruktor
-       protected function __construct ($className) {
-               // Call highest constructor
-               parent::__construct($className);
-
-               // Clean up a little, dies sollte ganz zum Schluss erfolgen!
-               $this->removeResizeFactorArray();
-               $this->removeCurrPart();
-               $this->removeCurrShip();
-       }
-
-       // Setter-Methode fuer Laenge
-       public final function setLength ($length) {
-               $this->length = (float) $length;
-       }
-
-       // Setter-Methode fuer Breite
-       public final function setWidth ($width) {
-               $this->width = (float) $width;
-       }
-
-       // Setter-Methode fuer Hoehe
-       public final function setHeight ($height) {
-               $this->height = (float) $height;
-       }
-
-       // Getter-Methode fuer Laenge
-       public final function getLength () {
-               return $this->length;
-       }
-
-       // Getter-Methode fuer Breite
-       public final function getWidth () {
-               return $this->width;
-       }
-
-       // Getter-Methode fuer Hoehe
-       public final function getHeight () {
-               return $this->height;
-       }
-
-       // Setter-Methode fuer Teil-Instanz
-       public final function setPartInstance (ConstructableShipPart $partInstance) {
-               $this->partInstance = $partInstance;
-       }
-
-       // Getter-Methode fuer Teil-Instanz
-       public final function getPartInstance () {
-               if (!isset($this->partInstance)) {
-                       return null;
-               }
-               return $this->partInstance;
-       }
-
-       // Remover-Methode fuer die Teil-Instanz
-       public final function removePartInstance () {
-               unset($this->partInstance);
-       }
-
-       // Prueft ob all Umberechnungsfaktoren gesetzt sind
-       private function isResizeFactorValid () {
-               return (($this->getResizeFactorElement('width')  > 1)
-                       || ($this->getResizeFactorElement('height') > 1)
-                       || ($this->getResizeFactorElement('length') > 1)
-               );
-       }
-
-       // Baut einen Motor in das Schiff ein
-       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $partInstance) {
-               // Schiff/-steil merken
-               $this->currShip = $shipInstance;
-               $this->currPart = $partInstance;
-
-               // Passt ueberhaupt das Schiffsteil in's Schiff?
-               if ($this->isShipPartSizeValid()) {
-                       // Muessen die Masse angepasst werden?
-                       if ($this->isResizeFactorValid()) {
-                               // Neue Angaben berechnen (wir lassen etwas Lust fuer Kabelbaeume, Roehren, Maschinisten, etc.)
-                               $this->newWidth  = (float) $this->getCurrPart()->getWidth()  * $this->resizeFactorArray['width'];
-                               $this->newHeight = (float) $this->getCurrPart()->getHeight() * $this->resizeFactorArray['height'];
-                               $this->newLength = (float) $this->getCurrPart()->getLength() * $this->resizeFactorArray['length'];
-
-                               // Passt dies nun immer noch?
-                               if ($this->isNewSizeValid()) {
-                                       // Das passt auch, dann Werte setzen und Motor-Instanz merken
-                                       $this->setWidth($this->newWidth);
-                                       $this->setHeight($this->newHeight);
-                                       $this->setLength($this->newLength);
-
-                                       // Einige Dinge entfernen...
-                                       $this->removeAllNewAttr();
-                               } else {
-                                       // Passt nicht! Also wieder Exception werfen...
-                                       throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> vom Typ <strong>%s</strong> ist zu gross f&uuml;r das Schiff!",
-                                               $this->getCurrPart()->__toString(),
-                                               $this->getCurrPart()->getObjectDescription(),
-                                               $this->getCurrPart()->__toString()
-                                       ), 2);
-                               }
-                       } elseif ($this->currPart != null) {
-                               // Aktuelle Masse setzen
-                               $this->setWidth($this->getCurrPart()->getWidth());
-                               $this->setHeight($this->getCurrPart()->getHeight());
-                               $this->setLength($this->getCurrPart()->getLength());
-                       }
-
-                       // Existiert ein Schiffsteil?
-                       if (!is_null($this->currPart)) {
-                               // Schiffsteil-Instanz setzen
-                               $this->setPartInstance($this->currPart);
-
-                               // Instanzen entfernen
-                               $this->getCurrPart()->removeCurrShip();
-                               $this->getCurrPart()->removeCurrPart();
-                               $this->getCurrPart()->removePartInstance();
-                               $this->getCurrPart()->removeResizeFactorArray();
-                       }
-               } else {
-                       // Exception werfen!
-                       throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <u>%s</u> vom Typ <u>%s</u> passt nicht in das Schiff!",
-                               $this->getCurrPart()->realClass,
-                               $this->getCurrPart()->getObjectDescription(),
-                               $this->getCurrPart()->__toString()
-                       ), 1);
-               }
-
-               // Nochmals Clean up a little
-               $this->removeResizeFactorArray();
-               $this->removeCurrShip();
-               $this->removeCurrPart();
-       }
-
-       // Array fuer Umrechnungstabelle entfernen
-       public final function removeResizeFactorArray () {
-               unset($this->resizeFactorArray);
-       }
-
-       /**
-        * Remove all new*** attributes
-        *
-        * @return      void
-        */
-       public final function removeAllNewAttr () {
-               unset($this->newWidth);
-               unset($this->newHeight);
-               unset($this->newLength);
-       }
-
-       /**
-        * Remove current ship instance
-        *
-        * @return      void
-        */
-       public final function removeCurrShip () {
-               unset($this->currShip);
-       }
-
-       // Aktuelle Schiffsteil-Instanz entfernen
-       public final function removeCurrPart () {
-               unset($this->currPart);
-       }
-
-       // Breite entfernen
-       public final function removeWidth () {
-               unset($this->width);
-       }
-
-       // Hoehe entfernen
-       public final function removeHeight () {
-               unset($this->height);
-       }
-
-       // Laenge entfernen
-       public final function removeLength () {
-               unset($this->length);
-       }
-
-       // Tiefgang entfernen
-       public final function removeDraught () {
-               unset($this->draught);
-       }
-
-       // Getter-Methode fuer Element aus resizeFactor
-       public final function getResizeFactorElement ($el) {
-               if (isset($this->resizeFactorArray[$el])) {
-                       // Element gefunden
-                       return $this->resizeFactorArray[$el];
-               } else {
-                       // Element nicht gefunden!
-                       return null;
-               }
-       }
-
-       // Setter-Methode fuer Element in resizeFactor
-       public final function setResizeFactorElement ($el, $value) {
-               $this->resizeFactorArray[$el] = (float) $value;
-       }
-
-       // Kontrolliert, ob die Abmasse Schiffsteil->Schiff stimmen
-       public function isShipPartSizeValid () {
-               return (
-                       (
-                               ( // Already defined ship messurings
-                                                ($this->getCurrPart()->getWidth()  < $this->currShip->getWidth())
-                                       && ($this->getCurrPart()->getHeight() < $this->currShip->getDraught())
-                                       && ($this->getCurrPart()->getLength() < $this->currShip->getLength())
-                               ) || ( // Ship messurings shall be calculated
-                                                ($this->currShip->getWidth()  == 0)
-                                       && ($this->currShip->getHeight() == 0)
-                                       && ($this->currShip->getLength() == 0)
-                               )
-                       // The inserted part must be messured!
-                       ) && ($this->getCurrPart()->getWidth()  > 0)
-                               && ($this->getCurrPart()->getHeight() > 0)
-                               && ($this->getCurrPart()->getLength() > 0)
-               );
-       }
-
-       // Kontrolliert, ob die Abmasse Maschinenraum->Schiff stimmen
-       public function isNewSizeValid () {
-               return (
-                       ( // Already defined ship messurings
-                                        ($this->newWidth  < $this->currShip->getWidth())
-                               && ($this->newHeight < $this->currShip->getDraught())
-                               && ($this->newLength < $this->currShip->getLength())
-                       ) || ( // Ship messurings shall be calculated
-                                        ($this->currShip->getWidth()  == 0)
-                               && ($this->currShip->getHeight() == 0)
-                               && ($this->currShip->getLength() == 0)
-                       )
-               );
-       }
-
-       // Masse extrahieren
-       public function extractDimensions ($dim) {
-               // Abmasse setzen
-               if ((isset($dim)) && (is_array($dim)) && (count($dim) == 3)) {
-                       // Abmasse aus Array holen
-                       $this->setWidth($dim[0]);
-                       $this->setHeight($dim[1]);
-                       $this->setLength($dim[2]);
-               } else {
-                       // Nicht gefundene Abmasse!
-                       throw new DimNotFoundInArrayException($this, self::EXCEPTION_DIMENSION_ARRAY_INVALID);
-               }
-       }
-
-       /**
-        * Getter for current part instance
-        *
-        * @return              $currPart       Instance of the current ship part object
-        */
-       public final function getCurrPart () {
-               return $this->currPart;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/class_Merchant.php b/application/ship-simu/main/class_Merchant.php
deleted file mode 100644 (file)
index 648e299..0000000
+++ /dev/null
@@ -1,109 +0,0 @@
-<?php
-/**
- * A class for merchants which can trade items
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Merchant extends BaseFrameworkSystem {
-       // Name des Haendlers
-       private $merchantName   = "Namenloser H&auml;ndler";
-
-       // Preislite (Objekte wiedermal!)
-       private $priceList      = null;
-
-       // Zugewiesener Hafen
-       private $harborInstance = null;
-
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Haendler mit Namen erzeugen
-       public static final function createMerchant ($merchantName, Harbor $harborInstance) {
-               // String absichern
-               $merchantName = (string) $merchantName;
-
-               // Get new instance
-               $merchantInstance = new Merchant();
-
-               // Debug message
-               if ((defined('DEBUG_MERCHANT')) || (defined('DEBUG_ALL'))) {
-                       $merchantInstance->debugOutput(sprintf("[%s:%d] Ein H&auml;ndler <strong>%s</strong> wird angelegt und soll sich am <strong>%s</strong> niederlassen.",
-                               __CLASS__,
-                               __LINE__,
-                               $merchantName,
-                               $harborInstance->getHarborName()
-                       ));
-               }
-
-               // Haendlernamen setzen
-               $merchantInstance->setMerchantName($merchantName);
-
-               // In dem angegebenen Hafen den Haendler ansiedeln
-               $merchantInstance->setHarborInstance($harborInstance);
-
-               // Preisliste initialisieren
-               $merchantInstance->createPriceList();
-
-               // Instanz zurueckliefern
-               return $merchantInstance;
-       }
-
-       // Initialize pricing list
-       private function createPriceList () {
-               $this->priceList = new FrameworkArrayObject("FakedPriceList");
-       }
-
-       // Setter for merchant name
-       public final function setMerchantName ($merchantName) {
-               // Debug message
-               $this->merchantName = (string) $merchantName;
-       }
-
-       // Getter for merchant name
-       public final function getMerchantName () {
-               return $this->merchantName;
-       }
-
-       // Setter for harbor instance
-       public final function setHarborInstance (Harbor $harborInstance) {
-               $this->harborInstance = $harborInstance;
-       }
-
-       // Getter for harbor instance
-       public final function getHarborInstance () {
-               return $this->harborInstance;
-       }
-
-       // Add new item to merchant's price list
-       public function addItemToPriceList (TradeableItem $itemInstance, $price) {
-               $this->makeDeprecated();
-       }
-
-       // Get a price from the merchant's list
-       public final function getPriceFromList (TradeableItem $itemInstance) {
-               $this->makeDeprecated();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/class_WorksContract.php b/application/ship-simu/main/class_WorksContract.php
deleted file mode 100644 (file)
index bbe2f35..0000000
+++ /dev/null
@@ -1,329 +0,0 @@
-<?php
-/**
- * The work constract class which can be used for contract parties
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WorksContract extends BaseFrameworkSystem implements SignableContract {
-       // Zukuenftiger Schiffsname
-       private $shipName         = "";
-
-       // Instanz zum Schiffstypen
-       private $shipInstance     = null;
-
-       // Contract partner
-       private $contractPartner  = null;
-
-       // Other contract partner
-       private $contractParty    = null;
-
-       // Is the contract signed?
-       private $signed           = false;
-
-       // Merchant instance
-       private $merchantInstance = null;
-
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Neuen Bauvertrag generieren
-       public static final function createWorksContract ($shipType, $shipName, ContractPartner $partnerInstance) {
-               // Strings absichern
-               $shipType = (string) $shipType;
-               $shipName = (string) $shipName;
-
-               // Get new instance
-               $contractInstance = new WorksContract();
-
-               // Schiffsnamen setzen
-               $contractInstance->setShipName($shipName);
-
-               // Existiert die Klasse ueberhaupt?
-               if (!class_exists($shipType)) {
-                       // Klasse nicht gefunden
-                       throw new NoClassException ($shipType, self::EXCEPTION_CLASS_NOT_FOUND);
-               }
-
-               // Schiff-Instanz temporaer erzeugen und in den Bauvertrag einfuegen
-               $shipInstance = ObjectFactory::createObjectByName($shipType, array($shipName));
-               $contractInstance->setShipInstance($shipInstance);
-
-               // Remove the ship instance
-               unset($shipInstance);
-
-               // Set itself as contract partner
-               $contractInstance->setContractPartner($partnerInstance);
-
-               // Instanz zurueckgeben
-               return $contractInstance;
-       }
-
-       // Setter for ship instance
-       private final function setShipInstance (ConstructableShip $shipInstance) {
-               $this->shipInstance = $shipInstance;
-       }
-
-       // Setter for ship name
-       private final function setShipName ($shipName) {
-               $this->shipName = (string) $shipName;
-       }
-
-       // Getter for ship name
-       public final function getShipName () {
-               return $this->shipName;
-       }
-
-       // Getter for ship instance
-       public final function getShipInstance () {
-               return $this->shipInstance;
-       }
-
-       // Add detail to the contract
-       public function addContractDetails ($shipPart, $parentPart, array $dataArray) {
-               // Secure strings
-               $shipPart   = (string) $shipPart;
-               $parentPart = (string) $parentPart;
-
-               // Debug message
-               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiffsteil <strong>%s</strong> wird zusammen mit dem Konstruktionsteil <strong>%s</strong> in den Bauvertrag aufgenommen.",
-                       __CLASS__,
-                       __LINE__,
-                       $shipPart,
-                       $parentPart
-               ));
-
-               // Initialize the instance (shall not be done within dynamic part)
-               $partInstance = null;
-
-               // Try to get an instance for this ship part
-               try {
-                       $partInstance = ObjectFactory::createObjectByName($shipPart, $dataArray);
-               } catch (DimNotFoundInArrayException $e) {
-                       $this->debugOutput(sprintf("[main:] Die <strong>%s</strong> konnte nicht vervollst&auml;ndigt werden. Grund: <strong>%s</strong><br />",
-                               $this->getShipInstance()->getShipName(),
-                               $e->getMessage()
-                       ));
-
-                       // Debug message
-                       if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Versuche ein Schiffsteil in den Bauvertrag aufzunehmen.",
-                               __CLASS__,
-                               __LINE__
-                       ));
-
-                       // Is this ship part constructable?
-                       if (!$partInstance instanceof ConstructableShipPart) {
-                               // Ship part not constructable!
-                               throw new ShipPartNotConstructableException(array($shipPart), self::EXCEPTION_NOT_CONSTRUCTABLE);
-                       } elseif ($this->getShipInstance()->createShipPart($partInstance, $parentPart) === false) {
-                               // Schiff konnte nicht gebaut werden!
-                               throw new ShipNotConstructedException(sprintf("Das Schiff <strong>%s</strong> konnte wegen eines Fehlers nicht gebaut werden. Siehe obere Meldungen.",
-                                       $this->getShipInstance()->getShipName()
-                               ));
-                       }
-               } catch (NoClassException $e) {
-                       // Throw it again...
-                       throw new NoClassException($e->getMessage(), $e->getCode());
-               }
-
-               // Get price for this item
-               $price = $this->getMerchantInstance()->getPriceFromList($partInstance);
-
-               // Add price
-               $partInstance->setPrice($price);
-       }
-
-       // Setter for contract partner
-       public final function setContractPartner (ContractPartner $partnerInstance) {
-               $this->contractPartner = $partnerInstance;
-       }
-
-       // Getter for contract partner
-       public final function getContractPartner () {
-               return $this->contractPartner;
-       }
-
-       // Setter for contract party
-       public final function setContractParty (ContractPartner $partyInstance) {
-               $this->contractParty = $partyInstance;
-       }
-
-       // Getter for contract party
-       public final function getContractParty () {
-               return $this->contractParty;
-       }
-
-       // Setter for signature
-       public final function setSigned ($signed) {
-               $this->signed = (boolean) $signed;
-       }
-
-       // Getter for signature
-       public function isSigned () {
-               return $this->signed;
-       }
-
-       // Sign the contract
-       public function signContract (ContractPartner $partnerInstance, ContractPartner $partyInstance) {
-               // Is this contract already signed?
-               if ($this->isSigned()) {
-                       // Throw an exception
-                       throw new ContractAllreadySignedException(array($this, $this->getContractPartner(), $this->getContractParty()), self::EXCEPTION_CONTRACT_ALREADY_SIGNED);
-               }
-
-               // Is the first contract partner still the same?
-               if ($partnerInstance->equals($this->getContractPartner())) {
-                       // Set contract party (other partner is already set)
-                       $this->setContractParty($partyInstance);
-
-                       // Finally sign it
-                       $this->setSigned(true);
-               } else {
-                       // Throw an exception
-                       throw new ContractPartnerMismatchException(array($this, $this->getContractPartner(), $partyInstance), self::EXCEPTION_CONTRACT_PARTNER_MISMATCH);
-               }
-
-               // Debug message
-               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) {
-                       if ($partnerInstance->equals($partyInstance)) {
-                               // With itself
-                               $this->debugOutput(sprintf("[%s:%d] Die <strong>%s</strong> <em><strong>%s</strong></em> stimmt einem Bauvertrag &uuml;ber das <strong>%s</strong> <em><strong>%s</strong></em> zu.",
-                                       __CLASS__,
-                                       __LINE__,
-                                       $partnerInstance->getObjectDescription(),
-                                       $partnerInstance->getCompanyName(),
-                                       $this->getShipInstance()->getObjectDescription(),
-                                       $this->getShipInstance()->getShipName()
-                               ));
-                       } else {
-                               // Other contract party
-                               $this->debugOutput(sprintf("[%s:%d] Die <strong>%s</strong> <em><strong>%s</strong></em> geht mit der <strong>%s</strong> <em><strong>%s</strong></em> einen Bauvertrag &uuml;ber das <strong>%s</strong> <em><strong>%s</strong></em> ein.",
-                                       __CLASS__,
-                                       __LINE__,
-                                       $partnerInstance->getObjectDescription(),
-                                       $partnerInstance->getCompanyName(),
-                                       $partyInstance->getObjectDescription(),
-                                       $partyInstance->getCompanyName(),
-                                       $this->getShipInstance()->getObjectDescription(),
-                                       $this->getShipInstance()->getShipName()
-                               ));
-                       }
-               }
-       }
-
-       // Setter for merchant instance
-       public final function setMerchantInstance (Merchant $merchantInstance) {
-               $this->merchantInstance = $merchantInstance;
-       }
-
-       // Getter for merchant instance
-       public final function getMerchantInstance () {
-               return $this->merchantInstance;
-       }
-
-       // Getter for total price
-       public final function getTotalPrice () {
-               // Get ship instance
-               $shipInstance = $this->getShipInstance();
-
-               // Is this a ship?
-               if (is_null($shipInstance)) {
-                       // Opps! Empty partner instance?
-                       throw new NullPointerException($shipInstance, self::EXCEPTION_IS_NULL_POINTER);
-               } elseif (!is_object($shipInstance)) {
-                       // Not an object! ;-(
-                       throw new InvalidObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
-               } elseif (!$shipInstance instanceof ConstructableShip) {
-                       // Does not have the required feature (method)
-                       throw new ShipIsInvalidException(array($shipInstance), self::EXCEPTION_INVALID_SHIP_INSTANCE);
-               }
-
-               // Get the structure array
-               $struct = $shipInstance->getStructuresArray();
-
-               // Is this a ship?
-               if (is_null($struct)) {
-                       // Opps! Empty partner instance?
-                       throw new EmptyStructuresListException($this, self::EXCEPTION_EMPTY_STRUCTURES_ARRAY);
-               }
-
-               // Init total price
-               $totalPrice = 0;
-
-               // Iterate through the list
-               for ($iter = $struct->getIterator(); $iter->valid(); $iter->next()) {
-                       // Get item
-                       $item = $iter->current();
-
-                       // Is this a ship?
-                       if (is_null($item)) {
-                               // Opps! Empty partner instance?
-                               throw new NullPointerException($item, self::EXCEPTION_IS_NULL_POINTER);
-                       } elseif (!is_object($item)) {
-                               // Not an object! ;-(
-                               throw new InvalidObjectException($item, self::EXCEPTION_IS_NO_OBJECT);
-                       } elseif (!$item instanceof BaseSimulator) {
-                               // Does not have the required feature (method)
-                               throw new MissingMethodException(array($item, 'getPartInstance'), self::EXCEPTION_MISSING_METHOD);
-                       }
-
-                       // Get part instance
-                       $part = $item->getPartInstance();
-
-                       // Is this a ship?
-                       if (is_null($part)) {
-                               // Opps! Empty partner instance?
-                               throw new NullPointerException($part, self::EXCEPTION_IS_NULL_POINTER);
-                       } elseif (!is_object($part)) {
-                               // Not an object! ;-(
-                               throw new InvalidObjectException($part, self::EXCEPTION_IS_NO_OBJECT);
-                       } elseif (!method_exists($part, 'getPrice')) {
-                               // Does not have the required feature (method)
-                               throw new MissingMethodException(array($part, 'getPrice'), self::EXCEPTION_MISSING_METHOD);
-                       }
-
-                       // Get price for one item
-                       $price = $part->getPrice();
-
-                       // Is there numCabin() available?
-                       if (method_exists($item, 'getNumCabin')) {
-                               // Get total cabin and multiply it with the price
-                               $price = $price * $item->getNumCabin();
-                       }
-
-                       // Add price to total price
-                       $totalPrice += $price;
-               }
-
-               // Total price calculated?
-               if ($totalPrice === 0) {
-                       // Throw exception
-                       throw new TotalPriceNotCalculatedException($this, self::EXCEPTION_TOTAL_PRICE_NOT_CALCULATED);
-               }
-
-               // Return total price
-               return $totalPrice;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/.htaccess b/application/ship-simu/main/commands/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/commands/web/.htaccess b/application/ship-simu/main/commands/web/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/commands/web/class_WebShipsimuGuestLoginCommand.php b/application/ship-simu/main/commands/web/class_WebShipsimuGuestLoginCommand.php
deleted file mode 100644 (file)
index 14015a3..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-<?php
-/**
- * A command for guest logins
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuGuestLoginCommand extends BaseCommand implements Commandable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipsimuGuestLoginCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipsimuGuestLoginCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // First get a GuestLogin instance
-               $loginInstance = ObjectFactory::createObjectByConfiguredName('guest_login_class');
-
-               // First set request and response instance
-               $loginInstance->setRequestInstance($requestInstance);
-
-               // Encrypt the password
-               $loginInstance->encryptPassword('passwd');
-
-               // Do the login here
-               $loginInstance->doLogin($requestInstance, $responseInstance);
-
-               // Was the login fine? Then redirect here
-               if ($loginInstance->ifLoginWasSuccessfull()) {
-                       // Try to redirect here
-                       try {
-                               // Redirect...
-                               $responseInstance->redirectToConfiguredUrl('app_login');
-
-                               // Exit here
-                               exit();
-                       } catch (FrameworkException $e) {
-                               // Something went wrong here!
-                               $responseInstance->addFatalMessage($e->getMessage());
-                       }
-               } else {
-                       // Attach error message to the response
-                       $responseInstance->addFatalMessage('failed_user_login');
-               }
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add more filters
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add username verifier filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_guest_verifier_filter'));
-
-               // Add password verifier filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('passwd_guest_verifier_filter'));
-
-               // Add CAPTCHA verifier code
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_guest_verifier_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/class_WebShipsimuProfileCommand.php b/application/ship-simu/main/commands/web/class_WebShipsimuProfileCommand.php
deleted file mode 100644 (file)
index a266f26..0000000
+++ /dev/null
@@ -1,153 +0,0 @@
-<?php
-/**
- * A command for profile-update handling
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuProfileCommand extends BaseCommand implements Commandable {
-       /**
-        * Filtered request data
-        */
-       private $requestData = array();
-
-       /**
-        * Allowed profile data to pass through
-        */
-       private $allowedData = array(
-               'pass'  => 'pass1',
-               'email' => 'email1',
-               'surname',
-               'family',
-               'street',
-               'city',
-               'zip',
-               'icq',
-               'jabber',
-               'yahoo',
-               'aol',
-               'msn',
-               'rules',
-               'birth_day',
-               'birth_month',
-               'birth_year'
-       );
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipsimuProfileCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipsimuProfileCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Add functionality here
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Make sure only allowed values are comming through
-               foreach ($this->allowedData as $alias => $element) {
-                       // Get data
-                       $data = $requestInstance->getRequestElement($element);
-
-                       // Silently skip empty fields
-                       if (empty($data)) continue;
-
-                       // Do we have an alias?
-                       if (is_string($alias)) {
-                               // Yes, so use it
-                               $this->requestData[$alias]   = $data;
-                       } else {
-                               // No, default entry
-                               $this->requestData[$element] = $data;
-                       }
-               } // END - foreach
-
-               // Remove the array, we don't need it anymore
-               unset($this->allowedData);
-
-               // Unfinished!
-               $this->partialStub("Unfinished work.");
-               $this->debugBackTrace();
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some more pre/post filters to the controller
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add user auth filter (we don't need an update of the user here because it will be redirected)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // User status filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // User status if not 'guest' filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_guest_filter'));
-
-               // Updated rules accepted
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('rules_accepted_filter'));
-
-               // Account password validation
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
-
-               // Validate CAPTCHA input
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_profile_verifier_filter'));
-
-               // Validate birthday input
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('birthday_profile_verifier_filter'));
-
-               // Email changed
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_change_filter'));
-
-               // Password changed
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_change_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/class_WebShipsimuRefillCommand.php b/application/ship-simu/main/commands/web/class_WebShipsimuRefillCommand.php
deleted file mode 100644 (file)
index 1c9bd8e..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-<?php
-/**
- * A command for the money refill page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuRefillCommand extends BaseCommand implements Commandable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipsimuRefillCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipsimuRefillCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get template instance
-               $templateInstance = $responseInstance->getTemplateInstance();
-
-               // Set amount and type as variables
-               $templateInstance->assignVariable('refill_done', $requestInstance->getRequestElement('type'));
-               $templateInstance->assignVariable('amount'     , $requestInstance->getRequestElement('amount'));
-
-               // This method does currently redirect if all goes right. Booking is done in filters
-               $responseInstance->redirectToConfiguredUrl('refill_page_done');
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add user auth filter (we don't need an update of the user here because it will be redirected)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // Add user status filter here
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Is the refill page active?
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_page_filter'));
-
-               // Verify password
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
-
-               // Verify CAPTCHA code
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_refill_verifier_filter'));
-
-               // Verify refill request
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_request_validator_filter'));
-
-               // Construct config entry for wether automatic payment from API or waiting for approval
-               $paymentTypeConfig = sprintf("refill_request_%s_payment_type", $requestInstance->getRequestElement('type'));
-
-               // Prepare a filter based on the requested type we shall refill
-               $filterName = sprintf("refill_request_%s_%s_book_filter",
-                       $requestInstance->getRequestElement('type'),
-                       $this->getConfigInstance()->getConfigEntry($paymentTypeConfig)
-               );
-
-               // Now, try to load that filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName($filterName));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/class_WebShipsimuRegisterCommand.php b/application/ship-simu/main/commands/web/class_WebShipsimuRegisterCommand.php
deleted file mode 100644 (file)
index 181ce2f..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-<?php
-/**
- * A command for registration handling
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuRegisterCommand extends BaseCommand implements Commandable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipsimuRegisterCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipsimuRegisterCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // First get a UserRegistration instance
-               $registerInstance = ObjectFactory::createObjectByConfiguredName('user_registration_class');
-
-               // First set request and response instance
-               $registerInstance->setRequestInstance($requestInstance);
-               $registerInstance->setResponseInstance($responseInstance);
-
-               // Encrypt the password
-               $registerInstance->encryptPassword('pass1');
-
-               // Do things before registration
-               $registerInstance->doPreRegistration();
-
-               // Register the new user
-               $registerInstance->registerNewUser();
-
-               // Do things after registration like notifying partner pages or queueing
-               // them for notification
-               $registerInstance->doPostRegistration();
-
-               // Redirect or login after registration
-               $registerInstance->doPostAction();
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add some more pre/post filters to the controller
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Validate email address (if configured: check on double email addresses)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_validator_filter'));
-
-               // Validate username and check if it does not exist
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_validator_filter'));
-
-               // Validate if username is "guest" and not taken
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_is_guest_filter'));
-
-               // Validate if password is set
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_validator_filter'));
-
-               // Check if rules where accepted
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('rules_accepted_filter'));
-
-               // Validate CAPTCHA input
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_register_verifier_filter'));
-
-               // Validate birthday
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('birthday_register_verifier_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/class_WebShipsimuUserLoginCommand.php b/application/ship-simu/main/commands/web/class_WebShipsimuUserLoginCommand.php
deleted file mode 100644 (file)
index 2a33a8f..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-<?php
-/**
- * A command for user login
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuUserLoginCommand extends BaseCommand implements Commandable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipsimuUserLoginCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipsimuUserLoginCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // First get a UserLogin instance
-               $loginInstance = ObjectFactory::createObjectByConfiguredName('user_login_class');
-
-               // First set request and response instance
-               $loginInstance->setRequestInstance($requestInstance);
-
-               // Encrypt the password
-               $loginInstance->encryptPassword('pass');
-
-               // Do the login here
-               $loginInstance->doLogin($requestInstance, $responseInstance);
-
-               // Was the login fine? Then redirect here
-               if ($loginInstance->ifLoginWasSuccessfull()) {
-                       // Try to redirect here
-                       try {
-                               // Redirect...
-                               $responseInstance->redirectToConfiguredUrl('app_login');
-
-                               // Exit here
-                               exit();
-                       } catch (FrameworkException $e) {
-                               // Something went wrong here!
-                               $responseInstance->addFatalMessage($e->getMessage());
-                       }
-               } else {
-                       // Attach error message to the response
-                       $responseInstance->addFatalMessage('failed_user_login');
-               }
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Add more filters
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Which login type do we have?
-               switch ($this->getConfigInstance()->getConfigEntry('login_type')) {
-                       case 'username': // Login via username
-                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_verifier_filter'));
-                               break;
-
-                       case 'email': // Login via email
-                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_verifier_filter'));
-                               break;
-
-                       default: // Wether username or email is set
-                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_email_verifier_filter'));
-                               break;
-               }
-
-               // Password verifier filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_verifier_filter'));
-
-               // Add filter for CAPTCHA
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_user_verifier_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/company/.htaccess b/application/ship-simu/main/commands/web/company/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/commands/web/company/class_WebShipSimuCompanyCommand.php b/application/ship-simu/main/commands/web/company/class_WebShipSimuCompanyCommand.php
deleted file mode 100644 (file)
index 7fed46f..0000000
+++ /dev/null
@@ -1,88 +0,0 @@
-<?php
-/**
- * A command for the money refill page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipSimuCompanyCommand extends BaseCommand implements Commandable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this command and sets the resolver instance
-        *
-        * @param       $resolverInstance       An instance of a command resolver
-        * @return      $commandInstance        The created command instance
-        */
-       public static final function createWebShipSimuCompanyCommand (CommandResolver $resolverInstance) {
-               // Get a new instance
-               $commandInstance = new WebShipSimuCompanyCommand();
-
-               // Set the resolver instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get template instance
-               $templateInstance = $responseInstance->getTemplateInstance();
-
-               // Set amount and type as variables
-               $templateInstance->assignVariable('refill_done', $requestInstance->getRequestElement('type'));
-               $templateInstance->assignVariable('amount'     , $requestInstance->getRequestElement('amount'));
-
-               // This method does currently redirect if all goes right
-               $responseInstance->redirectToConfiguredUrl('refill_page_done');
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add user auth filter (we don't need an update of the user here because it will be redirected)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // Add user status filter here
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/government/.htaccess b/application/ship-simu/main/commands/web/government/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php b/application/ship-simu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php
deleted file mode 100644 (file)
index e720850..0000000
+++ /dev/null
@@ -1,146 +0,0 @@
-<?php
-/**
- * A command for a failed startup request. This may happen when the user
- * "knows" the correct URL but government refuses to pay.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebGovernmentFailedStartupCommand extends BaseCommand implements Commandable {
-       /**
-        * 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      $commandInstance        An instance a prepared command class
-        */
-       public static final function createWebGovernmentFailedStartupCommand (CommandResolver $resolverInstance) {
-               // Get new instance
-               $commandInstance = new WebGovernmentFailedStartupCommand();
-
-               // Set the application instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the given command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get the action instance from registry
-               $actionInstance = Registry::getRegistry()->getInstance('action');
-
-               // Do we have an action here?
-               if ($actionInstance instanceof PerformableAction) {
-                       // Execute the action (shall not output anything, see below why)
-                       $actionInstance->execute($requestInstance, $responseInstance);
-               } // END - if
-
-               // Get the application instance
-               $appInstance = $this->getResolverInstance()->getApplicationInstance();
-
-               // Prepare a template instance
-               $templateInstance = $this->prepareTemplateInstance($appInstance);
-
-               // Assign base URL
-               $templateInstance->assignConfigVariable('base_url');
-
-               // Assign all the application's data with template variables
-               $templateInstance->assignApplicationData($appInstance);
-
-               // Load the master template
-               $masterTemplate = $appInstance->buildMasterTemplateName();
-
-               // Load header template
-               $templateInstance->loadCodeTemplate('header');
-
-               // Compile and assign it with a variable
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('header', 'header');
-
-               // Load footer template
-               $templateInstance->loadCodeTemplate('footer');
-
-               // Compile and assign it with a variable
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('footer', 'footer');
-
-               // Load main template
-               $templateInstance->loadCodeTemplate('government_failed_main');
-
-               // Assign the main template with the master template as a content ... ;)
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('government_failed_main', 'content');
-
-               // Load the master template
-               $templateInstance->loadCodeTemplate($masterTemplate);
-
-               // Set title
-               $templateInstance->assignVariable('title', $this->getLanguageInstance()->getMessage($requestInstance->getRequestElement('page') . '_' . $requestInstance->getRequestElement('failed') . '_title'));
-
-               // Construct the menu in every command. We could do this in BaseCommand class. But this means
-               // *every* command has a navigation system and that is want we don't want.
-               $menuInstance = ObjectFactory::createObjectByConfiguredName('government_failed_area_menu_class', array($appInstance));
-
-               // Render the menu
-               $menuInstance->renderMenu();
-
-               // Transfer it to the template engine instance
-               $menuInstance->transferContentToTemplateEngine();
-
-               // ... and all variables. This should be merged together in a pattern
-               // to make things easier. A cache mechanism should be added between
-               // these two calls to cache compiled templates.
-               $templateInstance->compileVariables();
-
-               // Get the content back from the template engine and put it in response class
-               $templateInstance->transferToResponse($responseInstance);
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Maybe we need some filters here?
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Empty for now
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php b/application/ship-simu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php
deleted file mode 100644 (file)
index 45bcc32..0000000
+++ /dev/null
@@ -1,146 +0,0 @@
-<?php
-/**
- * A command for a failed training request. This may happen when the user
- * "knows" the correct URL but government refuses to pay.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebGovernmentFailedTrainingCommand extends BaseCommand implements Commandable {
-       /**
-        * 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      $commandInstance        An instance a prepared command class
-        */
-       public static final function createWebGovernmentFailedTrainingCommand (CommandResolver $resolverInstance) {
-               // Get new instance
-               $commandInstance = new WebGovernmentFailedTrainingCommand();
-
-               // Set the application instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the given command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get the action instance from registry
-               $actionInstance = Registry::getRegistry()->getInstance('action');
-
-               // Do we have an action here?
-               if ($actionInstance instanceof PerformableAction) {
-                       // Execute the action (shall not output anything, see below why)
-                       $actionInstance->execute($requestInstance, $responseInstance);
-               } // END - if
-
-               // Get the application instance
-               $appInstance = $this->getResolverInstance()->getApplicationInstance();
-
-               // Prepare a template instance
-               $templateInstance = $this->prepareTemplateInstance($appInstance);
-
-               // Assign base URL
-               $templateInstance->assignConfigVariable('base_url');
-
-               // Assign all the application's data with template variables
-               $templateInstance->assignApplicationData($appInstance);
-
-               // Load the master template
-               $masterTemplate = $appInstance->buildMasterTemplateName();
-
-               // Load header template
-               $templateInstance->loadCodeTemplate('header');
-
-               // Compile and assign it with a variable
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('header', 'header');
-
-               // Load footer template
-               $templateInstance->loadCodeTemplate('footer');
-
-               // Compile and assign it with a variable
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('footer', 'footer');
-
-               // Load main template
-               $templateInstance->loadCodeTemplate('government_failed_main');
-
-               // Assign the main template with the master template as a content ... ;)
-               $templateInstance->compileTemplate();
-               $templateInstance->assignTemplateWithVariable('government_failed_main', 'content');
-
-               // Load the master template
-               $templateInstance->loadCodeTemplate($masterTemplate);
-
-               // Set title
-               $templateInstance->assignVariable('title', $this->getLanguageInstance()->getMessage($requestInstance->getRequestElement('page') . '_' . $requestInstance->getRequestElement('failed') . '_title'));
-
-               // Construct the menu in every command. We could do this in BaseCommand class. But this means
-               // *every* command has a navigation system and that is want we don't want.
-               $menuInstance = ObjectFactory::createObjectByConfiguredName('government_failed_area_menu_class', array($appInstance));
-
-               // Render the menu
-               $menuInstance->renderMenu();
-
-               // Transfer it to the template engine instance
-               $menuInstance->transferContentToTemplateEngine();
-
-               // ... and all variables. This should be merged together in a pattern
-               // to make things easier. A cache mechanism should be added between
-               // these two calls to cache compiled templates.
-               $templateInstance->compileVariables();
-
-               // Get the content back from the template engine and put it in response class
-               $templateInstance->transferToResponse($responseInstance);
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Maybe we need some filters here?
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Empty for now
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php b/application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php
deleted file mode 100644 (file)
index 3153962..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-<?php
-/**
- * A command for a failed startup request. This may happen when the user
- * "knows" the correct URL but government refuses to pay.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuGovernmentStartupCommand extends BaseCommand implements Commandable {
-       /**
-        * 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      $commandInstance        An instance a prepared command class
-        */
-       public static final function createWebShipsimuGovernmentStartupCommand (CommandResolver $resolverInstance) {
-               // Get new instance
-               $commandInstance = new WebShipsimuGovernmentStartupCommand();
-
-               // Set the application instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the given command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get a wrapper instance
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
-
-               // Register the startup help
-               $wrapperInstance->registerStartupHelpByRequest($requestInstance);
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Maybe we need some filters here?
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add user auth filter (we don't need an update of the user here because it will be redirected)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // Add user status filter here
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Check if government can pay startup help
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_startup_help_filter'));
-
-               // Verify password
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
-
-               // Verify CAPTCHA code
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_government_verifier_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php b/application/ship-simu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php
deleted file mode 100644 (file)
index 035e5e8..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-<?php
-/**
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebShipsimuGovernmentTrainingCommand extends BaseCommand implements Commandable {
-       /**
-        * 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      $commandInstance        An instance a prepared command class
-        */
-       public static final function createWebShipsimuGovernmentTrainingCommand (CommandResolver $resolverInstance) {
-               // Get new instance
-               $commandInstance = new WebShipsimuGovernmentTrainingCommand();
-
-               // Set the application instance
-               $commandInstance->setResolverInstance($resolverInstance);
-
-               // Return the prepared instance
-               return $commandInstance;
-       }
-
-       /**
-        * Executes the given command with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Get a wrapper instance
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
-
-               // Register the training
-               $wrapperInstance->registerTrainingByRequest($requestInstance);
-       }
-
-       /**
-        * Adds extra filters to the given controller instance
-        *
-        * @param       $controllerInstance             A controller instance
-        * @param       $requestInstance                An instance of a class with an Requestable interface
-        * @return      void
-        * @todo        Maybe we need some filters here?
-        */
-       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
-               // Add user auth filter (we don't need an update of the user here because it will be redirected)
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // Add user status filter here
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
-
-               // Check if government can pay training help
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_training_filter'));
-
-               // Verify password
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
-
-               // Verify CAPTCHA code
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_refill_verifier_filter'));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/companies/.htaccess b/application/ship-simu/main/companies/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/companies/class_ShippingCompany.php b/application/ship-simu/main/companies/class_ShippingCompany.php
deleted file mode 100644 (file)
index de959b6..0000000
+++ /dev/null
@@ -1,666 +0,0 @@
-<?php
-/**
- * A shipping company may be founded with this class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShippingCompany extends BaseSimulator implements Customer, ContractPartner {
-       /**
-        * Full name of this company
-        */
-       private $companyName     = "Namenlose Reederei";
-
-       /**
-        * Shorted name of this company
-        */
-       private $shortName       = "";
-
-       /**
-        * Instance of the founder
-        */
-       private $founderInstance = null;
-
-       /**
-        * Headquarter harbor instance
-        */
-       private $hqInstance      = null;
-
-       /**
-        * Employed people by this company
-        */
-       private $employeeList    = null;
-
-       /**
-        * List of all assigned shipyards
-        */
-       private $shipyardList   = null;
-
-       /**
-        * List of owned ships
-        */
-       private $ownedShips      = null;
-
-       /**
-        * Work constracts this company is currently working on
-        */
-       private $contractList    = null;
-
-       // Exception constants
-       const EXCEPTION_USER_OWNS_NO_COMPANY = 0x200;
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this company class or throws an exception if the
-        * given user owns no company.
-        *
-        * @param       $userInstance           A user class
-        * @return      $companyInstance        Prepared company instance
-        * @todo        Add functionality if user participates in a company
-        */
-       public static final function createShippingCompany (ManageableAccount $userInstance) {
-               // Get new instance
-               $companyInstance = new ShippingCompany();
-
-               // Does the given user owns a company?
-               if ($companyInstance->ifUserParticipatesInCompany($userInstance)) {
-                       // 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
-
-               // Init all lists
-               $companyInstance->initCompanyLists();
-
-               // Return instance
-               return $companyInstance;
-       }
-
-       /**
-        * Checks wether the given user participates in a company
-        *
-        * @param       $userInstance   An instance of a user class
-        * @return      $participates   Wether the user participates at lease in one company
-        */
-       protected function ifUserParticipatesInCompany (ManageableAccount $userInstance)  {
-               // By default no user owns any company... ;)
-               $participates = false;
-
-               // Get a company database wrapper class
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class', array($this));
-
-               // Ask the wrapper if this user participates
-               $participates = $wrapperInstance->ifUserParticipatesInCompany($userInstance);
-
-               // Get the result instance
-               $resultInstance = $wrapperInstance->getResultInstance();
-
-               // Caches the result instance here, if set (we don't the wrapper anymore!)
-               if ($resultInstance instanceof SearchableResult) {
-                       // Set the result instance
-                       $this->setResultInstance($resultInstance);
-               } // END - if
-
-               // Return result
-               return $participates;
-       }
-
-       /**
-        * Checks wether the current user in registry is the company founder
-        *
-        * @return      $isFounder      Wether the current user is the company founder
-        * @todo        Check if user is company founder
-        */
-       public function ifUserIsFounder () {
-               // Default is not the founder
-               $isFounder = false;
-
-               // Get result instance
-               $resultInstance = $this->getResultInstance();
-
-               // Is it set?
-               if ($resultInstance instanceof SearchableResult) {
-                       // Result found so analyse it
-                       $this->partialStub("Check if user is company founder.");
-               } // END - if
-
-               // Return result
-               return $isFounder;
-       }
-
-       /**
-        * Checks wether the current user in registry is the company owner
-        *
-        * @return      $isOwner        Wether the current user is the company owner
-        * @todo        Check if user is company owner
-        */
-       public function ifUserIsOwner () {
-               // Default is not the owner
-               $isOwner = false;
-
-               // Get result instance
-               $resultInstance = $this->getResultInstance();
-
-               // Is it set?
-               if ($resultInstance instanceof SearchableResult) {
-                       // Result found so analyse it
-                       $this->partialStub("Check if user is company owner.");
-               } // END - if
-
-               // Return result
-               return $isOwner;
-       }
-
-       /**
-        * Checks wether the current user in registry is an employee in this company
-        *
-        * @return      $isOwner        Wether the current user is an employee in this company
-        */
-       public function ifUserIsEmployee () {
-               // Default is no employee
-               $isEmployee = false;
-
-               // Get result instance
-               $resultInstance = $this->getResultInstance();
-
-               // Is it set?
-               if ($resultInstance instanceof SearchableResult) {
-                       // Result found so he is employee
-                       $isEmployee = true;
-               } // END - if
-
-               // Return result
-               return $isEmployee;
-       }
-
-       //------------------------------------------------------------------------------\
-       // Below here is very old code which needs to be translated and changed heavily |
-       //------------------------------------------------------------------------------/
-
-       /**
-        * Intialize all lists
-        *
-        * @return      void
-        * @todo        Maybe we don't need these big lists anymore?! So we can deprecate/remove it
-        */
-       protected function initCompanyLists () {
-               // Employees
-               $this->employeeList = new FrameworkArrayObject("FakedEmployeeList");
-
-               // Ship yards
-               $this->shipyardList = new FrameworkArrayObject("FakedShipyardList");
-
-               // Contracts
-               $this->contractList = new FrameworkArrayObject("FakedContractList");
-       }
-
-       // Setter-Methode fuer Firmennamen
-       public final function setCompanyName ($companyName) {
-               $this->companyName = (string) $companyName;
-       }
-
-       // Getter-Methode fuer Firmennamen
-       public final function getCompanyName () {
-               return $this->companyName;
-       }
-
-       // Setter-Methode fuer Firmensitz
-       public final function setHQInstance (Harbor $hqInstance) {
-               $this->hqInstance = $hqInstance;
-       }
-
-       // Kuerzel setzen
-       private function initShortName () {
-               // Mindestens eine Leerstelle?
-               $dummy = explode(" ", $this->getCompanyName());
-               foreach ($dummy as $part) {
-                       $this->shortName .= substr($part, 0, 1);
-               } // END - if
-       }
-
-       // Reedereien Werften bauen lassen
-       public function createShipyardInHarbor($shipyardName, Harbor $harborInstance) {
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> baut im <strong>%s</strong> eine Werft <strong>%s</strong>.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $harborInstance->getHarborName(),
-                       $shipyardName
-               ));
-
-               // Wird im HQ gebaut?
-               if ($this->hqInstance->equals($harborInstance)) {
-                       // Die neue Werft wird im HQ gebaut!
-                       $this->hqInstance->addNewShipyardNotify($shipyardName, $this);
-                       // Die Werft drueber in Kenntnis setzen, welcher Reederei sie angehoert
-               } else {
-                       // Ausserhalb des Heimathafens soll eine Werft gebaut werden
-                       $harborInstance->addNewShipyardNotify($shipyardName, $this);
-               }
-       }
-
-       // Setter fuer Reederei-Gruender
-       public final function setCompanyFounder(CompanyEmployee $founderInstance) {
-               $this->founderInstance = $founderInstance;
-       }
-
-       // Getter for founder instance
-       public final function getFounderInstance () {
-               return $this->founderInstance;
-       }
-
-       // Neue(n) Angestellte(n) in Angestellten-Liste aufnehmen
-       public function addNewEmployee (SimulatorPersonell $employeeInstance) {
-               $this->employeeList->append($employeeInstance);
-       }
-
-       // Neue Werft in Liste aufnehmen
-       public function addNewShipyard (Shipyard $shipyardInstance) {
-               $this->shipyardList->append($shipyardInstance);
-       }
-
-       // Neue Mitarbeiter per Zufall einstellen/rekrutieren
-       public function recruitRandomEmployees($amount, SimulatorPersonell $personellInstance) {
-               // Anzahl Mitarbeiter absichern
-               $amount = (int) $amount;
-
-               // Debug-Meldung ausgeben
-               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> stellt per Zufall <strong>%d</strong> neue Mitarbeiter ein.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $amount
-               ));
-
-               // Gesamtanzahl verfuegbarer Erwerbsloser holen
-               $totalUnemployed = $personellInstance->getAllUnemployed();
-
-               // Existiert die gewuenschte Anzahl freier Arbeiter? (doppelt geht derzeit nicht)
-               if ($totalUnemployed < $amount) {
-                       // Reichte nicht aus!
-                       throw new ToMuchEmployeesException(array($amount, $personellInstance->getAllUnemployed()), self::EXCEPTION_NOT_ENOUGTH_UNEMPLOYEES);
-               } // END - if
-
-               // Get list for all unemployed people
-               $list = $personellInstance->getSpecialPersonellList(false); // Should be cached
-
-               // Get iterator of the list
-               $iterator = $list->getIterator();
-
-               // Get the requested amount of personell
-               for ($idx = 0; $idx < $amount; $idx++) {
-                       $employee = null;
-                       // Is this personl unemployed?
-                       while (is_null($employee) || $employee->isEmployed()) {
-                               // Generate random number
-                               $pos = mt_rand(0, ($totalUnemployed - 1)); // Don't remove the -1 here:
-                               // E.g. 100 entries means latest position is 99...
-
-                               // Seek for the position
-                               $iterator->seek($pos);
-
-                               // Is the current position valid?
-                               if ($iterator->valid() === false) {
-                                       // Should normally not happen... :(
-                                       throw new StructuresOutOfBoundsException($idx, self::EXCEPTION_INDEX_OUT_OF_BOUNDS);
-                               } // END - if
-
-                               // Get current element
-                               $employee = $iterator->current();
-                       } // END - while
-
-                       // A dummy just for the description and real class
-                       $dummy = CompanyEmployee::createCompanyEmployee("", "", "M", 1970, 1, 1, $employee->isMarried(), 0);
-
-                       // Make this person employed and give him some money to work
-                       $employee->setEmployed(true);
-                       $employee->setRealClass($dummy->__toString());
-                       $employee->increaseSalary((mt_rand(7, 14) * 100)); // Are 700 to 1400 EUR for the begin okay?
-
-                       // Debug message
-                       if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> stellt den/die Angestellte(n) <strong>%s %s</strong> ein.",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getCompanyName(),
-                               $employee->getSurname(),
-                               $employee->getFamily()
-                       ));
-
-                       // Add this employee
-                       $this->addNewEmployee($employee);
-               } // End - for
-
-               // Cache resetten
-               $personellInstance->resetCache();
-
-               // Debug-Meldung ausgeben
-               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat per Zufall <strong>%d</strong> neue Mitarbeiter eingestellt.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $amount
-               ));
-       } // End - method
-
-       // Distribute all personells on all shipyards
-       public function distributeAllPersonellOnShipyards () {
-               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> verteilt alle ihre <strong>%d</strong> Mitarbeiter auf alle <strong>%d</strong> Werft(en).",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $this->getTotalEmployee(),
-                       $this->getTotalShipyards()
-               ));
-
-               // Do we have some shipyards?
-               if (is_null($this->shipyardList)) {
-                       // No shipyards created
-                       throw new NoShipyardsConstructedException($this, self::EXCEPTION_HARBOR_HAS_NO_SHIPYARDS);
-               }
-
-               // Get iterator for shipyards
-               $shipyardIter = $this->shipyardList->getIterator();
-
-               // Iterate through all employees
-               for ($idx = $this->employeeList->getIterator(); $idx->valid(); $idx->next()) {
-                       // Is the shipyard iterator still okay?
-                       if ($shipyardIter->valid() === false) {
-                               // Rewind to first position
-                               $shipyardIter->seek(0);
-                       } // END - if
-
-                       // Get Shipyard object
-                       $shipyard = $shipyardIter->current();
-
-                       // Is this a Shipyard object?
-                       if (is_null($shipyard)) {
-                               // No class returned
-                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
-                       } elseif (!is_object($shipyard)) {
-                               // Not an object! ;-(
-                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
-                       } elseif ($shipyard->isClass("Shipyard") === false) {
-                               // Nope, so throw exception
-                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
-                       }
-
-                       // Add employee to the shipyard
-                       $shipyard->addNewPersonell($idx->current());
-
-                       // Continue to next shipyard
-                       $shipyardIter->next();
-               }
-       }
-
-       // Getter for total employees
-       public final function getTotalEmployee () {
-               // Count all...
-               $total = $this->employeeList->count();
-
-               // Debug message
-               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat <strong>%d</strong> Mitarbeiter.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $total
-               ));
-
-               // Return amount
-               return $total;
-       }
-
-       // Getter for total shipyards
-       public final function getTotalShipyards () {
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] F&uuml;r die Reederei <strong>%s</strong> werden die Anzahl der Werften in allen H&auml;fen ermittelt.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName()
-               ));
-
-               // Do we have some shipyards?
-               if (is_null($this->shipyardList)) {
-                       // No shipyards created
-                       throw new NoShipyardsConstructedException($this, self::EXCEPTION_HARBOR_HAS_NO_SHIPYARDS);
-               }
-
-               // Get iterator
-               $total = $this->shipyardList->count();
-
-               // Debug message
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat <strong>%d</strong> Werft(en).",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $total
-               ));
-
-               // Return amount
-               return $total;
-       }
-
-       // Add a ship type (class) to all shipyards
-       public function addShipTypeToAllShipyards ($shipType) {
-               // Secure strings
-               $shipType = (string) $shipType;
-
-               // Is the class there?
-               if (!class_exists($shipType)) {
-                       // Throw exception
-                       throw new NoClassException($shipType, self::EXCEPTION_CLASS_NOT_FOUND);
-               }
-
-               // Create dummy ship
-               eval(sprintf("\$shipInstance = %s::create%s(\"M/S Dummy\");",
-                       $shipType,
-                       $shipType
-               ));
-
-               // Iterate shipyard list
-               for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
-                       // Get current element
-                       $shipyard = $idx->current();
-
-                       // Is this a shipyard?
-                       if (is_null($shipyard)) {
-                               // Opps! Empty list?
-                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
-                       } elseif (!is_object($shipyard)) {
-                               // Not an object! ;-(
-                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
-                       } elseif ($shipyard->isClass("Shipyard") === false) {
-                               // Class is not a shipyard
-                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
-                       }
-
-                       // Add the new ship type to the shipyard
-                       $shipyard->addNewConstructableShipType($shipType);
-               } // END - for
-       }
-
-       // Validate the requested ship type with the company if they can construct it
-       public function validateWorksContractShipType (SignableContract $contractInstance) {
-               // First get the ship type
-               $shipInstance = $contractInstance->getShipInstance();
-
-               // Ist there a ship instance?
-               if (is_null($shipInstance)) {
-                       // Opps! Empty entry?
-                       throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
-               } elseif (!is_object($shipInstance)) {
-                       // Not an object! ;-(
-                       throw new InvalidObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
-               }
-
-               // Get it's real class name
-               $shipType = $shipInstance->__toString();
-
-               // Now check if ship type is in any list and return the result
-               return ($this->isShipTypeConstructable($shipType));
-       }
-
-       // Is the ship type constructable?
-       public function isShipTypeConstructable ($shipType) {
-               // The type must be a string!
-               $shipType = (string) $shipType;
-
-               // Debug message
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> fragt alle Werften ab, ob diese Schiffe vom Typ <strong>%s</strong> bauen k&ouml;nnen.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $shipType
-               ));
-
-               // First everthing is failed...
-               $result = false;
-
-               // Iterate through all shipyards
-               for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
-                       // Get current Shipyard instance
-                       $shipyard = $idx->current();
-
-                       // Is this a shipyard?
-                       if (is_null($shipyard)) {
-                               // Opps! Empty list?
-                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
-                       } elseif (!is_object($shipyard)) {
-                               // Not an object! ;-(
-                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
-                       } elseif ($shipyard->isClass("Shipyard") === false) {
-                               // Class is not a shipyard
-                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
-                       }
-
-                       // Validate if first found shipyard can construct the requested type
-                       $result = $shipyard->isShipTypeConstructable($shipType);
-
-                       // Does this shipyard construct the requested ship type?
-                       if ($result) break; // Then abort the search!
-               } // END - for
-
-               // Debug message
-               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat die Suche nach einer Werft beendet, die Schiffe vom Typ <strong>%s</strong> bauen kann.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getCompanyName(),
-                       $shipType
-               ));
-
-               // Return result
-               return $result;
-       }
-
-       // As a customer the shipping company can add new contracts
-       public function addNewWorksContract (SignableContract $contractInstance) {
-               $this->contractList->append($contractInstance);
-       }
-
-       // As a customer the shippng company can withdraw from a contract
-       public function withdrawFromContract (SignableContract $contractInstance) {
-               ApplicationEntryPoint::app_die("WITHDRAW:<pre>".print_r($contractInstance, true)."</pre>");
-       }
-
-       // Get latest added contract instance
-       public final function getLastContractInstance () {
-               // Get iterator
-               $iter = $this->contractList->getIterator();
-
-               // Get latest entry (total - 1)
-               $iter->seek($iter->count() - 1);
-
-               // Return entry
-               return $iter->current();
-       }
-
-       // Sign a contract with an other party which must also implement Customer
-       public function signContract (SignableContract $contractInstance, ContractPartner $partnerInstance) {
-               // Check wether the other party is our contract partner
-               if ($partnerInstance->isContractPartner($contractInstance) === false) {
-                       // Invalid contract partner!
-                       throw new InvalidContractPartnerException($partnerInstance, self::EXCEPTION_CONTRACT_PARTNER_INVALID);
-               } // END - if
-
-               // Determine if company "signs" own contract (must be done) or with an other party
-               if ($this->equals($partnerInstance)) {
-                       // With itself
-                       if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> erteilt an sich selbst einen Bauauftrag f&uuml;r das <strong>%s</strong> &quot;<strong>%s</strong>&quot;.",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getCompanyName(),
-                               $contractInstance->getShipInstance()->getObjectDescription(),
-                               $contractInstance->getShipInstance()->getShipName()
-                       ));
-               } else {
-                       // Other external company
-                       if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> unterzeichnet einen Bauauftrag f&uuml;r das <strong>%s</strong> &quot;<strong>%s</strong>&quot; mit der <strong>%s</strong>.",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getCompanyName(),
-                               $contractInstance->getShipInstance()->getObjectDescription(),
-                               $contractInstance->getShipInstance()->getShipName(),
-                               $partnerInstance->getCompanyName()
-                       ));
-               }
-
-               // Sign the contract
-               $contractInstance->signContract($this, $partnerInstance);
-
-               /**
-                * @todo        Maybe do something more here...
-                */
-       }
-
-       // Is this the right contract partner?
-       public function isContractPartner (SignableContract $contractInstance) {
-               // Get contract partner instance and compare it with $this contract partner
-               return ($this->equals($contractInstance->getContractPartner()));
-       }
-
-       // Setter for merchant instance
-       public final function setMerchantInstance (Merchant $merchantInstance) {
-               // Get contract
-               $contractInstance = $this->getLastContractInstance();
-
-               if (is_null($contractInstance)) {
-                       // Opps! Empty contract instance?
-                       throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
-               } elseif (!is_object($contractInstance)) {
-                       // Not an object! ;-(
-                       throw new InvalidObjectException($contractInstance, self::EXCEPTION_IS_NO_OBJECT);
-               } elseif ($contractInstance->isClass("WorksContract") === false) {
-                       // Is not a merchant
-                       throw new ClassMismatchException(array($contractInstance->__toString(), "WorksContract"), self::EXCEPTION_CLASSES_NOT_MATCHING);
-               }
-
-               // Set the merchant in the contract (for getting prices)
-               $contractInstance->setMerchantInstance($merchantInstance);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/.htaccess b/application/ship-simu/main/constructions/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/berths/.htaccess b/application/ship-simu/main/constructions/berths/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/berths/class_Berth.php b/application/ship-simu/main/constructions/berths/class_Berth.php
deleted file mode 100644 (file)
index c96ba10..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/**
- * A berth is a place where ships can wait for their next assignment
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Berth extends BaseConstruction {
-       // Durchlaufende Nummer der Liegeplaetze
-       private $berthIndex = 0;
-
-       // Zugewiesener Hafen
-       private $harborInstance = null;
-
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/class_BaseConstruction.php b/application/ship-simu/main/constructions/class_BaseConstruction.php
deleted file mode 100644 (file)
index af08a39..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * A general construction (land) class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseConstruction extends BaseSimulator {
-       // Tiefgang fuer z.B. Trockdocks
-       private $draught = 0;
-
-       // Konstruktor
-       protected function __construct ($className) {
-               // Eltern-Konstrutor aufrufen
-               parent::__construct($className);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/docks/.htaccess b/application/ship-simu/main/constructions/docks/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/docks/class_DryDock.php b/application/ship-simu/main/constructions/docks/class_DryDock.php
deleted file mode 100644 (file)
index c9d6f8e..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * A dry dock where ships can be repaired, repainted or modified in.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 DryDock extends BaseConstruction {
-       // Zugewiesener Hafen
-       private $harborInstance = null;
-
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/harbors/.htaccess b/application/ship-simu/main/constructions/harbors/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/harbors/class_Harbor.php b/application/ship-simu/main/constructions/harbors/class_Harbor.php
deleted file mode 100644 (file)
index cf350ce..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-<?php
-/**
- * A harbor class suitable for all kind of harbors
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Harbor extends BaseConstruction {
-       // Namen des Hafens (z.B. Hamburger Hafen)
-       private $harborName = "Unbekannter Hafen";
-
-       // Schiffsliste aller gebauten Schiffe
-       private $constructedShips = null;
-
-       // Liegeplatz-Liste
-       private $berthList = null;
-
-       // List of all assigned shipyards
-       private $shipyardList = null;
-
-       // Constructor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Creates a harbor
-       public static final function createHarbor ($harborName) {
-               // Hafen-Instanz holen
-               $harborInstance = new Harbor();
-
-               // Hafenname setzen
-               $harborInstance->setHarborName($harborName);
-
-               // Werftliste initialisieren
-               $harborInstance->createshipyardList();
-
-               // Instanz zurueckliefern
-               return $harborInstance;
-       }
-
-       // Werft-Liste generieren
-       public function createshipyardList () {
-               $this->shipyardList = new FrameworkArrayObject("FakedShipyardList");
-       }
-
-       // Setter fuer Hafennamen
-       public final function setHarborName ($harborName) {
-               $this->harborName = (string) $harborName;
-       }
-
-       // Getter fuer Hafennamen
-       public final function getHarborName () {
-               return $this->harborName;
-       }
-
-       // Werft in den Hafen einbauen und Werft->Reederei zuweisen
-       public function addNewShipyardNotify ($shipyardName, ShippingCompany $companyInstance) {
-               // Werft generieren und in die Werftliste aufnehmen
-               $this->shipyardList->append(Shipyard::createShipyardNotify($this, $shipyardName, $companyInstance));
-       }
-
-       // Werft in den Hafen einbauen ohne Zuweisung einer Reederei (gehoert der "Stadt" dann)
-       public function addNewShipyard ($shipyardName) {
-               // Werft generieren und in die Werftliste aufnehmen
-               $this->shipyardList->append(Shipyard::createShipyard($this, $shipyardName));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/terminals/.htaccess b/application/ship-simu/main/constructions/terminals/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/terminals/class_Terminal.php b/application/ship-simu/main/constructions/terminals/class_Terminal.php
deleted file mode 100644 (file)
index 9ae9985..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * A terminal class where ships can land and passengers can board the ship
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Terminal extends BaseConstruction {
-       // Zugewiesener Hafen
-       private $harborInstance = null;
-
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/constructions/yards/.htaccess b/application/ship-simu/main/constructions/yards/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/constructions/yards/class_Shipyard.php b/application/ship-simu/main/constructions/yards/class_Shipyard.php
deleted file mode 100644 (file)
index 1959f83..0000000
+++ /dev/null
@@ -1,215 +0,0 @@
-<?php
-/**
- * A shipyard construction class which can be used for constructing all kinds of
- * ships.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Shipyard extends BaseConstruction {
-       // Werft-Name
-       private $shipyardName    = "Namenlose Werft";
-
-       // Arbeiter-Liste
-       private $staffList = null;
-
-       // Queue-Liste fuer zu bauende Schiffe
-       private $queueList = null;
-
-       // Aktuell im Bau befindliches Schiff
-       private $currShipInConst = null;
-
-       // Liste konstruierbarer Schiffstypen
-       private $shipTypeList = null;
-
-       // Zugewiesener Hafen
-       private $harborInstance = null;
-
-       // Zugewiesene Reederei
-       private $shippingCompany = null;
-
-       // Constructor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-
-               // Staff-Liste/Schiffstyp-Liste erzeugen
-               $this->createStaffList();
-               $this->createShipTypeList();
-       }
-
-       // Create a shipyard and notify it about it's owner
-       public static final function createShipyardNotify (Harbor $harborInstance, $shipyardName, ShippingCompany $companyInstance) {
-               // Werft-Instanz holen
-               $shipyardInstance = self::createShipyard($harborInstance, $shipyardName);
-
-               // Reederei der Werft zuweisen
-               $shipyardInstance->setCompanyInstance($companyInstance);
-
-               // Die Reederei ueber ihre Werft informieren
-               $companyInstance->addNewShipyard($shipyardInstance);
-
-               // Instanz zurueckgeben
-               return $shipyardInstance;
-       }
-
-       // Create a shipyard, first we need to create a harbor
-       public static final function createShipyard (Harbor $harborInstance, $shipyardName) {
-               // Instanz temporaer holen
-               $shipyardInstance = new Shipyard();
-
-               // Debug message
-               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Eine Werft mit dem Namen <strong>%s</strong> wird im Hafen <strong>%s</strong> konstruiert.",
-                       __CLASS__,
-                       __LINE__,
-                       $shipyardName,
-                       $harborInstance->getHarborName()
-               ));
-
-               // Werft-Name setzen
-               $shipyardInstance->setShipyardName($shipyardName);
-
-               // Hafen-Instanz setzen
-               $shipyardInstance->setHarborInstance($harborInstance);
-
-               // Abmasse setzen in Meter
-               $shipyardInstance->setWidth(30);
-               $shipyardInstance->setHeight(30);
-               $shipyardInstance->setLength(100);
-
-               // Clean up a little
-               $shipyardInstance->removeDraught();
-
-               // Debug-Meldung
-               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> wurde gebaut.",
-                       __CLASS__,
-                       __LINE__,
-                       $shipyardName
-               ));
-
-               // Instanz zurueckliefern
-               return $shipyardInstance;
-       }
-
-       // Create staff list
-       private function createStaffList () {
-               $this->staffList = new FrameworkArrayObject("FakedStaffList");
-       }
-
-       // Create ship type list
-       private function createShipTypeList () {
-               $this->shipTypeList = new FrameworkArrayObject("FakedShipTypeList");
-       }
-
-       // Setter-Methode fuer Werft-Name
-       public final function setShipyardName ($shipyardName) {
-               $this->shipyardName = (string) $shipyardName;
-       }
-
-       // Getter-Methode fuer Werft-Name
-       public final function getShipyardName () {
-               return $this->shipyardName;
-       }
-
-       // Setter-Methode fuer Hafen-Instanz
-       public final function setHarborInstance (Harbor $harborInstance) {
-               $this->harborInstance = $harborInstance;
-       }
-
-       // Getter-Methode fuer Hafen-Instanz
-       public final function getHarborInstance () {
-               return $this->harborInstance;
-       }
-
-       // Setter fuer Reederei-Instanz
-       public final function setCompanyInstance (ShippingCompany $companyInstance) {
-               $this->shippingCompany = $companyInstance;
-       }
-
-       // Getter fuer Reederei-Instanz
-       public final function getCompanyInstance () {
-               return $this->shippingCompany;
-       }
-
-       // Add new personell
-       public function addNewPersonell ($personell) {
-               // Add to list
-               $this->staffList->append($personell);
-       }
-
-       // Add a new ship type to our list
-       public function addNewConstructableShipType ($shipType) {
-               // This must be a string!
-               $shipType = (string) $shipType;
-
-               // Debug message
-               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> kann bald Schiffe vom Typ <strong>%s</strong> bauen.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getShipyardName(),
-                       $shipType
-               ));
-
-               // Add to list
-               $this->shipTypeList->append($shipType);
-       }
-
-       // Is the specified ship type in our list?
-       public function isShipTypeConstructable ($shipType) {
-               // First we can't build this ship
-               $result = false;
-
-               // This must be a string!
-               $shipType = (string) $shipType;
-
-               // Debug message
-               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> pr&uuml;ft, ob Schiffe vom Typ <strong>%s</strong> baubar sind.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getShipyardName(),
-                       $shipType
-               ));
-
-               // Iterate through all types
-               for ($idx = $this->shipTypeList->getIterator(); $idx->valid(); $idx->next()) {
-                       // Get current ship type
-                       $type = (string) $idx->current();
-
-                       // Is both the same?
-                       $result = ($type == $shipType);
-
-                       // Type is found?
-                       if ($result) break; // Then abort the search!
-               }
-
-               // Debug message
-               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> hat die Suche nach dem Schiffstyp <strong>%s</strong> abgeschlossen.",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getShipyardName(),
-                       $shipType
-               ));
-
-               // Return result
-               return $result;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/controller/.htaccess b/application/ship-simu/main/controller/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/controller/web/.htaccess b/application/ship-simu/main/controller/web/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/controller/web/class_WebCompanyController.php b/application/ship-simu/main/controller/web/class_WebCompanyController.php
deleted file mode 100644 (file)
index c5f1e2d..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-<?php
-/**
- * Controller for company requests
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebCompanyController 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
-        * @todo        Add some filters to this controller
-        */
-       public static final function createWebCompanyController (CommandResolver $resolverInstance) {
-               // Create the instance
-               $controllerInstance = new WebCompanyController();
-
-               // Set the command resolver
-               $controllerInstance->setResolverInstance($resolverInstance);
-
-               // User auth filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // User update filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_update_filter'));
-
-               // News fetcher filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_download_filter'));
-
-               // News proccess/display-preparation
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_process_filter'));
-
-               // 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 from the resolver by sending a request instance to the resolver
-               $commandInstance = $this->getResolverInstance()->resolveCommandByRequest($requestInstance);
-
-               // Add more filters by the command
-               $commandInstance->addExtraFilters($this, $requestInstance);
-
-               // Try to run the pre filters, if auth exceptions come through redirect here
-               try {
-                       // Run the pre filters
-                       $this->executePreFilters($requestInstance, $responseInstance);
-               } catch (UserAuthorizationException $e) {
-                       // Redirect to main page
-                       $responseInstance->redirectToConfiguredUrl('login_failed');
-
-                       // Exit here
-                       exit();
-               }
-
-               // This request was valid! :-D
-               $requestInstance->requestIsValid();
-
-               // Execute the command
-               $commandInstance->execute($requestInstance, $responseInstance);
-
-               // Run the pre filters
-               $this->executePostFilters($requestInstance, $responseInstance);
-
-               // Flush the response out
-               $responseInstance->flushBuffer();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/controller/web/class_WebGovernmentFailedController.php b/application/ship-simu/main/controller/web/class_WebGovernmentFailedController.php
deleted file mode 100644 (file)
index c51bf1c..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-<?php
-/**
- * Controller for failed government requests
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebGovernmentFailedController 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
-        * @todo        Add some filters to this controller
-        */
-       public static final function createWebGovernmentFailedController (CommandResolver $resolverInstance) {
-               // Create the instance
-               $controllerInstance = new WebGovernmentFailedController();
-
-               // Set the command resolver
-               $controllerInstance->setResolverInstance($resolverInstance);
-
-               // User auth filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
-
-               // User update filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_update_filter'));
-
-               // News fetcher filter
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_download_filter'));
-
-               // News proccess/display-preparation
-               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_process_filter'));
-
-               // 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 from the resolver by sending a request instance to the resolver
-               $commandInstance = $this->getResolverInstance()->resolveCommandByRequest($requestInstance);
-
-               // Add more filters by the command
-               $commandInstance->addExtraFilters($this, $requestInstance);
-
-               // Try to run the pre filters, if auth exceptions come through redirect here
-               try {
-                       // Run the pre filters
-                       $this->executePreFilters($requestInstance, $responseInstance);
-               } catch (UserAuthorizationException $e) {
-                       // Redirect to main page
-                       $responseInstance->redirectToConfiguredUrl('login_failed');
-
-                       // Exit here
-                       exit();
-               }
-
-               // This request was valid! :-D
-               $requestInstance->requestIsValid();
-
-               // Execute the command
-               $commandInstance->execute($requestInstance, $responseInstance);
-
-               // Run the pre filters
-               $this->executePostFilters($requestInstance, $responseInstance);
-
-               // Flush the response out
-               $responseInstance->flushBuffer();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/drives/.htaccess b/application/ship-simu/main/drives/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/drives/class_BaseDrive.php b/application/ship-simu/main/drives/class_BaseDrive.php
deleted file mode 100644 (file)
index 56f9802..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-<?php
-/**
- * A general drive class for all kind of "drives".
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseDrive extends BaseSimulator {
-       // Price of this drive
-       private $price      = 0.00;
-       // PS-Zahl
-       private $horsePower = 0;
-       // Anzahl Nocken
-       private $numCams    = 0;
-
-       // Konstruktor
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Setter-Methode fuert PS-Zahl
-       public final function setHorsePower ($hp) {
-               $this->horsePower = (int) $hp;
-       }
-
-       // Setter-Methode fuer Nockenanzahl
-       public final function setNumCams ($cams) {
-               $this->numCams = (int) $cams;
-       }
-
-       // Setter for price
-       public final function setPrice ($price) {
-               $this->price = (float) $price;
-       }
-
-       // Getter for price
-       public final function getPrice () {
-               return $this->price;
-       }
-
-       public final function removePrice () {
-               unset($this->price);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/drives/motor/.htaccess b/application/ship-simu/main/drives/motor/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/drives/motor/class_Motor.php b/application/ship-simu/main/drives/motor/class_Motor.php
deleted file mode 100644 (file)
index 2f3479e..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-<?php
-/**
- * A motorized drive for bigger ships
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Motor extends BaseDrive implements TradeableItem, ConstructableShipPart {
-       // Constructor
-       protected function __construct() {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Einen Motor erstellen
-       public static final function createMotor ($descr, $hp, $cams, $w, $h, $l) {
-               // Get new instance
-               $motorInstance = new Motor();
-
-               // Beschreibung und Abmasse setzen
-               $motorInstance->setWidth($w);
-               $motorInstance->setHeight($h);
-               $motorInstance->setLength($l);
-
-               // Weitere Daten setzen
-               $motorInstance->setHorsePower($hp);
-               $motorInstance->setNumCams($cams);
-
-               // Instanz zurueckgeben
-               return $motorInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/factories/.htaccess b/application/ship-simu/main/factories/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php b/application/ship-simu/main/factories/class_ShipSimuWebNewsFactory.php
deleted file mode 100644 (file)
index e42b021..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-<?php
-/**
- * A class for the special news object factory
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuWebNewsFactory extends BaseFrameworkSystem {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return              $factoryInstance        An instance of this class
-        */
-       public static final function createShipSimuWebNewsFactory () {
-               // Get a new instance
-               $factoryInstance = new ShipSimuWebNewsFactory();
-
-               // Return the prepared instance
-               return $factoryInstance;
-       }
-
-       /**
-        * Create the news object itself here depending on the request
-        *
-        * @param       $requestInstance        An instance of a request class
-        * @return      $newsInstance           An instance of a news class
-        */
-       public function createNewObject (Requestable $requestInstance) {
-               // Do some stuff here
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/.htaccess b/application/ship-simu/main/filter/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/book/.htaccess b/application/ship-simu/main/filter/book/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/book/refill/.htaccess b/application/ship-simu/main/filter/book/refill/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php b/application/ship-simu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php
deleted file mode 100644 (file)
index b7ff113..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-<?php
-/**
- * A filter for currency booking in refill requests. This filter shall "book" the
- * requested amount of points directly on the users account. This filter is for
- * testing/developing only and was needed for the first developement stage of the
- * game. You should not really use this filter on your "live-system".
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 RefillRequestCurrencyTestBookFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance         An instance of this filter class
-        */
-       public static final function createRefillRequestCurrencyTestBookFilter () {
-               // Get a new instance
-               $filterInstance = new RefillRequestCurrencyTestBookFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Add code being executed in this filter
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Get the user instance from registry
-               $userInstance = Registry::getRegistry()->getInstance('user');
-
-               // Run the update
-               $userInstance->bookAmountDirectly($requestInstance);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/class_ b/application/ship-simu/main/filter/class_
deleted file mode 100644 (file)
index 20653ff..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-<?php
-/**
- * A filter for money refill page
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 ???Filter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance         An instance of this filter class
-        */
-       public final static function create???Filter () {
-               // Get a new instance
-               $filterInstance = new ???Filter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Add code being executed in this filter
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               $this->partialStub("Add code here for your specific filter.");
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/class_BaseShipSimuFilter.php b/application/ship-simu/main/filter/class_BaseShipSimuFilter.php
deleted file mode 100644 (file)
index 7a80cf2..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A general filter class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseShipSimuFilter extends BaseFilter {
-       /**
-        * Protected constructor
-        *
-        * @param       $className      Name of the filter class
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Add something to do on every filter
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Add something to do on every filter
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/government/.htaccess b/application/ship-simu/main/filter/government/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php b/application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php
deleted file mode 100644 (file)
index 7becf12..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-<?php
-/**
- * A filter for checking if government can pay startup helps
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuGovernmentPaysStartupHelpFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance                 An instance of this filter class
-        */
-       public static final function createShipSimuGovernmentPaysStartupHelpFilter () {
-               // Get a new instance
-               $filterInstance = new ShipSimuGovernmentPaysStartupHelpFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Get the user instance from registry
-               $userInstance = Registry::getRegistry()->getInstance('user');
-
-               // Now simply check for it
-               if ((!$userInstance instanceof ManageableMember) || ($userInstance->ifGovernmentPaysStartupHelp() === false)) {
-                       // Request is invalid
-                       $requestInstance->requestIsValid(false);
-
-                       // Redirect to configured URL
-                       $responseInstance->redirectToConfiguredUrl('login_government_startup_failed');
-
-                       // Stop processing here
-                       exit();
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php b/application/ship-simu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php
deleted file mode 100644 (file)
index 75eb1cc..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-<?php
-/**
- * A filter for checking if government can pay a training for current user
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuGovernmentPaysTrainingFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance                 An instance of this filter class
-        */
-       public static final function createShipSimuGovernmentPaysTrainingFilter () {
-               // Get a new instance
-               $filterInstance = new ShipSimuGovernmentPaysTrainingFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        0% done
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Get the user instance from registry
-               $userInstance = Registry::getRegistry()->getInstance('user');
-
-               // Now simply check for it
-               if ((!$userInstance instanceof ManageableMember) || ($userInstance->ifGovernmentPaysTraining() === false)) {
-                       // Request is invalid
-                       $requestInstance->requestIsValid(false);
-
-                       // Redirect to configured URL
-                       $responseInstance->redirectToConfiguredUrl('login_government_training_failed');
-
-                       // Stop processing here
-                       exit();
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/page/.htaccess b/application/ship-simu/main/filter/page/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/page/class_RefillPageFilter.php b/application/ship-simu/main/filter/page/class_RefillPageFilter.php
deleted file mode 100644 (file)
index d4680ba..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-<?php
-/**
- * A filter for money refill page
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 RefillPageFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance                 An instance of this filter class
-        */
-       public static final function createRefillPageFilter () {
-               // Get a new instance
-               $filterInstance = new RefillPageFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @throws      FilterChainException    If this filter fails to operate
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Is the configuration variable set?
-               if ($this->getConfigInstance()->getConfigEntry('refill_page_active') === "N") {
-                       // Password is empty
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('refill_page_not_active');
-
-                       // Abort here
-                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/validator/.htaccess b/application/ship-simu/main/filter/validator/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/validator/class_RefillRequestValidatorFilter.php b/application/ship-simu/main/filter/validator/class_RefillRequestValidatorFilter.php
deleted file mode 100644 (file)
index 3abd7ba..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-<?php
-/**
- * A filter for validating the refill request
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 RefillRequestValidatorFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance         An instance of this filter class
-        */
-       public static final function createRefillRequestValidatorFilter () {
-               // Get a new instance
-               $filterInstance = new RefillRequestValidatorFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Maybe we need to added some more generic tests on the request here?
-        * @throws      FilterChainException    If this filter fails to operate
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Are all required request fields set?
-               if (($requestInstance->isRequestElementSet('type') === false) || ($requestInstance->isRequestElementSet('amount') === false)) {
-                       // Something important is missing
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('refill_page_required_fields_missing');
-
-                       // Abort here
-                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php b/application/ship-simu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php
deleted file mode 100644 (file)
index 989e1d4..0000000
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-/**
- * A filter for validating the refill request
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuUserStatusGuestFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance         An instance of this filter class
-        */
-       public static final function createShipSimuUserStatusGuestFilter () {
-               // Get a new instance
-               $filterInstance = new ShipSimuUserStatusGuestFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        * @todo        Maybe we need to added some more generic tests on the request here?
-        * @throws      FilterChainException    If this filter fails to operate
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Get a user instance for comparison
-               $userInstance = Registry::getRegistry()->getInstance('user');
-
-               // Is the user account confirmed?
-               if ($userInstance->getField(UserDatabaseWrapper::DB_COLUMN_USER_STATUS) == $this->getConfigInstance()->getConfigEntry('user_status_guest')) {
-                       // Request is invalid!
-                       $requestInstance->requestIsValid(false);
-
-                       // Redirect to configured URL
-                       $responseInstance->redirectToConfiguredUrl('login_user_status_guest');
-
-                       // Stop processing here
-                       exit();
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/filter/verifier/.htaccess b/application/ship-simu/main/filter/verifier/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/filter/verifier/class_BirthdayVerifierFilter.php b/application/ship-simu/main/filter/verifier/class_BirthdayVerifierFilter.php
deleted file mode 100644 (file)
index 51bb4db..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-<?php
-/**
- * A verifier filter for birthday data
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BirthdayVerifierFilter extends BaseShipSimuFilter implements Filterable {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this filter class
-        *
-        * @return      $filterInstance                 An instance of this filter class
-        */
-       public static final function createBirthdayVerifierFilter () {
-               // Get a new instance
-               $filterInstance = new BirthdayVerifierFilter();
-
-               // Return the instance
-               return $filterInstance;
-       }
-
-       /**
-        * Executes the filter with given request and response objects
-        *
-        * @param       $requestInstance        An instance of a class with an Requestable interface
-        * @param       $responseInstance       An instance of a class with an Responseable interface
-        * @return      void
-        */
-       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
-               // Execute the parent execute method
-               parent::execute($requestInstance, $responseInstance);
-
-               // Day of birth set?
-               if (!$requestInstance->isRequestElementSet('birth_day')) {
-                       // Day of birth isn't set
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('day_of_birth_unset');
-               } // END - if
-
-               // Month of birth set?
-               if (!$requestInstance->isRequestElementSet('birth_month')) {
-                       // Month of birth isn't set
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('month_of_birth_unset');
-               } // END - if
-
-               // Year of birth set?
-               if (!$requestInstance->isRequestElementSet('birth_year')) {
-                       // Year of birth isn't set
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('year_of_birth_unset');
-               } // END - if
-
-               // Is the request still valid?
-               if (!$requestInstance->isRequestValid()) {
-                       // Abort here
-                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
-               } // END - if
-
-               // Now comes the final check
-               $birthCheck = mktime(
-                       0,
-                       0,
-                       0,
-                       $requestInstance->getRequestElement('birth_day'),
-                       $requestInstance->getRequestElement('birth_month'),
-                       $requestInstance->getRequestElement('birth_year')
-               );
-
-               // Is there a number or such? (we don't care about the value itself here)
-               if (empty($birthCheck)) {
-                       // Validation has failed
-                       $requestInstance->requestIsValid(false);
-
-                       // Add a message to the response
-                       $responseInstance->addFatalMessage('birthday_invalid');
-
-                       // Abort here
-                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/government/.htaccess b/application/ship-simu/main/government/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/government/class_SimplifiedGovernment.php b/application/ship-simu/main/government/class_SimplifiedGovernment.php
deleted file mode 100644 (file)
index 8999153..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-<?php
-/**
- * A government class with simplified ways...
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.org
- * @todo               Find an interface for governments
- *
- * 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 SimplifiedGovernment extends BaseFrameworkSystem implements Registerable {
-       // Constants
-       const STATUS_STARTER_HELP    = 'STARTER_HELP';
-       const STATUS_TRAINING        = 'TRAINING';
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this government class by given user instance
-        *
-        * @param       $userInstance           The user instance
-        * @return      $governmentInstance     Instance of the prepared government instance
-        */
-       public static final function createSimplifiedGovernment (ManageableAccount $userInstance) {
-               // Get a new instance
-               $governmentInstance = new SimplifiedGovernment();
-
-               // Set the user instance
-               $governmentInstance->setUserInstance($userInstance);
-
-               // Return the prepared instance
-               return $governmentInstance;
-       }
-
-       /**
-        * Checks wether the government has already payed a training course for te
-        * current user
-        *
-        * @return      $alreadyPayed   Wether the government has already payed
-        * @todo        Needs do check training limit
-        */
-       public function ifGovernmentAlreadyPayedTraining () {
-               // Default is not payed
-               $alreadyPayed = false;
-
-               // Cache startup training limit
-               $trainingLimit = $this->getConfigInstance()->getConfigEntry('government_training_limit');
-
-               // Now get a search criteria and set the user's name as criteria
-               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
-               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_USERID  , $this->getUserInstance()->getUserId());
-               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_ACTIVITY, self::STATUS_TRAINING);
-               $searchInstance->setLimit(1);
-
-               // Get a wrapper instance
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
-
-               // Get result back
-               $resultInstance = $wrapperInstance->doSelectByCriteria($searchInstance);
-
-               // Was the query fine?
-               if ($resultInstance->next()) {
-                       // Get entry
-                       $currEntry = $resultInstance->current();
-
-                       // Entry was found so the government can no more pay a training
-                       $alreadyPayed = true;
-               } // END - if
-
-               // Return the result
-               return $alreadyPayed;
-       }
-
-       /**
-        * Checks wether the government has payed maximum of startup helps to the
-        * current user
-        *
-        * @return      $maximumPayed   Wether the government has already payed
-        * @todo        Needs do check help limit
-        */
-       public function ifGovernmentPayedMaxmimumStartupHelp () {
-               // Default is not payed
-               $maximumPayed = false;
-
-               // Cache startup help limit
-               $helpLimit = $this->getConfigInstance()->getConfigEntry('government_startup_help_limit');
-
-               // Now get a search criteria and set the user's name as criteria
-               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
-               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_USERID  , $this->getUserInstance()->getUserId());
-               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_ACTIVITY, self::STATUS_STARTER_HELP);
-               $searchInstance->setLimit($helpLimit);
-
-               // Get a wrapper instance
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
-
-               // Get result back
-               $resultInstance = $wrapperInstance->doSelectByCriteria($searchInstance);
-
-               // Was the query fine?
-               if ($resultInstance->next()) {
-                       // Get entry
-                       $currEntry = $resultInstance->current();
-
-                       // Entry found, so lets have a look if this government wants to again...
-                       $maximumPayed = true;
-               } // END - if
-
-               // Return the result
-               return $maximumPayed;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/login/.htaccess b/application/ship-simu/main/login/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/login/class_ShipSimuGuestLogin.php b/application/ship-simu/main/login/class_ShipSimuGuestLogin.php
deleted file mode 100644 (file)
index 16f76ed..0000000
+++ /dev/null
@@ -1,152 +0,0 @@
-<?php
-/**
- * A special guest login class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuGuestLogin extends BaseFrameworkSystem implements LoginableUser {
-       /**
-        * The hashed password
-        */
-       private $hashedPassword = '';
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this login class
-        *
-        * @return      $loginInstance  An instance of this login class
-        */
-       public static final function createShipSimuGuestLogin () {
-               // Get a new instance
-               $loginInstance = new ShipSimuGuestLogin();
-
-               // Return the instance
-               return $loginInstance;
-       }
-
-       /**
-        * Logins the user with the given request containing the credential. The
-        * result of the login can be thrown by exception or, if prefered stored
-        * in a boolean attribute which is then readable by a matching getter.
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @param       $responseInstance       An instance of a Responseable class
-        * @return      void
-        * @throws      UserAuthMethodException If wether username nor email login
-        *                                                                              was detected
-        * @throws      MissingMethodException          If a method was not found in the
-        *                                                                              User class
-        * @throws      UserPasswordMismatchException   If the supplied password did not
-        *                                                                              match with the stored password
-        */
-       public function doLogin (Requestable $requestInstance, Responseable $responseInstance) {
-               // By default no method is selected
-               $method = null;
-               $data = "";
-
-               // Detect login method (username or email) and try to get a userinstance
-               if (!is_null($requestInstance->getRequestElement('user'))) {
-                       // Username found!
-                       $method = 'createGuestByUsername';
-                       $data = $requestInstance->getRequestElement('user');
-               } // END - if
-
-               // Is a method detected?
-               if (is_null($method)) {
-                       // Then abort here
-                       throw new UserAuthMethodException($this, self::EXCEPTION_MISSING_METHOD);
-               } elseif (!method_exists($this->getConfigInstance()->getConfigEntry('guest_class'), $method)) {
-                       // The method is invalid!
-                       throw new MissingMethodException(array($this, $method), self::EXCEPTION_MISSING_METHOD);
-               }
-
-               // Get a user instance
-               $userInstance = call_user_func_array(array($this->getConfigInstance()->getConfigEntry('guest_class'), $method), array($data));
-
-               // Remember this new instance in registry
-               Registry::getRegistry()->addInstance('user', $userInstance);
-
-               // Is the password correct?
-               if ($userInstance->ifPasswordHashMatches($requestInstance) === false) {
-                       // Mismatching password
-                       throw new UserPasswordMismatchException(array($this, $userInstance), BaseUser::EXCEPTION_USER_PASS_MISMATCH);
-               } // END - if
-
-               // Now do the real login. This can be cookie- or session-based login
-               // which depends on the admins setting then on the user's taste.
-               // 1) Get a login helper instance
-               $helperInstance = ObjectFactory::createObjectByConfiguredName('login_helper_class', array($requestInstance));
-
-               // 2) Execute the login. This will now login...
-               $helperInstance->executeLogin($responseInstance);
-       }
-
-       /**
-        * Determines wether the login was fine. This is done by checking if 'login' instance is in registry
-        *
-        * @return      $loginDone      Wether the login was fine or not
-        */
-       public function ifLoginWasSuccessfull () {
-               // Is the registry key there?
-               $loginDone = (Registry::getRegistry()->getInstance('login') instanceof Registerable);
-
-               // Return the result
-               return $loginDone;
-       }
-
-       /**
-        * Encrypt given request key or throw an exception if key was not found in
-        * request
-        *
-        * @param       $requestKey             Key in request class
-        * @return      void
-        */
-       public function encryptPassword ($requestKey) {
-               // Check if password is found in request
-               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
-                       // So encrypt the password and store it for later usage in
-                       // the request:
-
-                       // Get the plain password
-                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
-
-                       // Get user instance
-                       $userInstance = Registry::getRegistry()->getInstance('user');
-
-                       // Get a crypto helper and hash the password
-                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword, $userInstance->getPasswordHash());
-
-                       // Store the hash back in request
-                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/login/class_ShipSimuUserLogin.php b/application/ship-simu/main/login/class_ShipSimuUserLogin.php
deleted file mode 100644 (file)
index cf43ef0..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-<?php
-/**
- * A special login class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuUserLogin extends BaseFrameworkSystem implements LoginableUser {
-       /**
-        * The hashed password
-        */
-       private $hashedPassword = '';
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this login class
-        *
-        * @return      $loginInstance  An instance of this login class
-        */
-       public static final function createShipSimuUserLogin () {
-               // Get a new instance
-               $loginInstance = new ShipSimuUserLogin();
-
-               // Return the instance
-               return $loginInstance;
-       }
-
-       /**
-        * Logins the user with the given request containing the credential. The
-        * result of the login can be thrown by exception or, if prefered stored
-        * in a boolean attribute which is then readable by a matching getter.
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @param       $responseInstance       An instance of a Responseable class
-        * @return      void
-        * @throws      UserPasswordMismatchException   If the supplied password did not
-        *                                                                              match with the stored password
-        * @todo        We need to add something here which will make more than one
-        * @todo        guest logins, users who are online but based on the same
-        * @todo        user account.
-        */
-       public function doLogin (Requestable $requestInstance, Responseable $responseInstance) {
-               // By default no method is selected
-               $method = null;
-               $data = "";
-
-               // Get member class
-               $userClass = $this->getConfigInstance()->getConfigEntry('user_class');
-
-               // Get a user instance
-               $userInstance = call_user_func_array(array($userClass, 'createMemberByRequest'), array($requestInstance));
-
-               // Remember this new instance in registry
-               Registry::getRegistry()->addInstance('user', $userInstance);
-
-               // Is the password correct?
-               if ($userInstance->ifPasswordHashMatches($requestInstance) === false) {
-                       // Mismatching password
-                       throw new UserPasswordMismatchException(array($this, $userInstance), BaseUser::EXCEPTION_USER_PASS_MISMATCH);
-               } // END - if
-
-               // ToDo place
-
-               // Now do the real login. This can be cookie- or session-based login
-               // which depends on the admins setting then on the user's taste.
-               // 1) Get a login helper instance
-               $helperInstance = ObjectFactory::createObjectByConfiguredName('login_helper_class', array($requestInstance));
-
-               // 2) Execute the login. This will now login...
-               $helperInstance->executeLogin($responseInstance);
-       }
-
-       /**
-        * Determines wether the login was fine. This is done by checking if 'login' instance is in registry
-        *
-        * @return      $loginDone      Wether the login was fine or not
-        */
-       public function ifLoginWasSuccessfull () {
-               // Is the registry key there?
-               $loginDone = (Registry::getRegistry()->getInstance('login') instanceof Registerable);
-
-               // Return the result
-               return $loginDone;
-       }
-
-       /**
-        * Encrypt given request key or throw an exception if key was not found in
-        * request
-        *
-        * @param       $requestKey             Key in request class
-        * @return      void
-        */
-       public function encryptPassword ($requestKey) {
-               // Check if password is found in request
-               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
-                       // So encrypt the password and store it for later usage in
-                       // the request:
-
-                       // Get the plain password
-                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
-
-                       // Get user instance
-                       $userInstance = Registry::getRegistry()->getInstance('user');
-
-                       // Get a crypto helper and hash the password
-                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword, $userInstance->getPasswordHash());
-
-                       // Store the hash back in request
-                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/login/helper/.htaccess b/application/ship-simu/main/login/helper/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/login/helper/class_ShipSimuLoginHelper.php b/application/ship-simu/main/login/helper/class_ShipSimuLoginHelper.php
deleted file mode 100644 (file)
index b5c125e..0000000
+++ /dev/null
@@ -1,114 +0,0 @@
-<?php
-/**
- * A helper for Ship-Simu to login. This login helper first checks what setting
- * (cookie or session) the admin has choosen then overwrites it with the setting
- * from current user. The registry instance should hold an instance of this user
- * class at key 'user' else an exception will be thrown. After this the setting
- * from a login form will be taken as login method and be stored in database
- * for later usage.
- *
- * The user shall be able to choose "Default login method" or similar to use his
- * own login method.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLoginHelper extends BaseLoginHelper implements HelpableLogin {
-       /**
-        * The login method we shall choose
-        */
-       private $authMethod = "";
-
-       // Exception constants
-       const EXCEPTION_INVALID_USER_INSTANCE = 0x190;
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class by given request instance
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @return      $helperInstance         An instance of this helper class
-        * @throws      UserInstanceMissingException    If the user instance in registry
-        *                                                                                      is missing or invalid
-        */
-       public static final function createShipSimuLoginHelper (Requestable $requestInstance) {
-               // Get a new instance first
-               $helperInstance = new ShipSimuLoginHelper();
-
-               // Get a user instance from registry
-               $userInstance = Registry::getRegistry()->getInstance('user');
-
-               // Is this instance valid?
-               if (!$userInstance instanceof ManageableAccount) {
-                       // Thrown an exception here
-                       throw new UserInstanceMissingException (array($helperInstance, 'user'), self::EXCEPTION_INVALID_USER_INSTANCE);
-               } // END - if
-
-               // Set default login method from config
-               $helperInstance->setDefaultAuthMethod();
-
-               // Set request instance
-               $helperInstance->setRequestInstance($requestInstance);
-
-               // Return the prepared instance
-               return $helperInstance;
-       }
-
-       /**
-        * Setter for default login method from config
-        *
-        * @return      void
-        */
-       protected function setDefaultAuthMethod () {
-               $this->authMethod = $this->getConfigInstance()->getConfigEntry('auth_method_class');
-       }
-
-       /**
-        * Execute the login request by given response instance. This instance can
-        * be used for sending cookies or at least the session id out.
-        *
-        * @param       $responseInstance       An instance of a Responseable class
-        * @return      void
-        */
-       public function executeLogin (Responseable $responseInstance) {
-               // Get an instance from the login method
-               $loginInstance = ObjectFactory::createObjectByName($this->authMethod, array($responseInstance));
-
-               // Set user cookie
-               $loginInstance->setUserAuth($this->getRequestInstance()->getRequestElement('username'));
-
-               // Set password cookie
-               $loginInstance->setPasswordAuth($this->getRequestInstance()->getRequestElement('pass_hash'));
-
-               // Remember this login instance for later usage
-               Registry::getRegistry()->addInstance('login', $loginInstance);
-       }
-}
-
-//
-?>
diff --git a/application/ship-simu/main/menu/.htaccess b/application/ship-simu/main/menu/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/menu/class_ShipSimu b/application/ship-simu/main/menu/class_ShipSimu
deleted file mode 100644 (file)
index 93970de..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A ??? menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 ShipSimu???Menu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public final static function createShipSimu???Menu () {
-               // Get a new instance
-               $menuInstance = new ShipSimu???Menu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuConfirmMenu.php b/application/ship-simu/main/menu/class_ShipSimuConfirmMenu.php
deleted file mode 100644 (file)
index 1dc56b7..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A Confirm menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuConfirmMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuConfirmMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuConfirmMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuHomeMenu.php b/application/ship-simu/main/menu/class_ShipSimuHomeMenu.php
deleted file mode 100644 (file)
index ef01389..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuHomeMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuHomeMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuHomeMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuLoginAreaMenu.php b/application/ship-simu/main/menu/class_ShipSimuLoginAreaMenu.php
deleted file mode 100644 (file)
index 038b123..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLoginAreaMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuLoginAreaMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuLoginAreaMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuLoginFailedMenu.php b/application/ship-simu/main/menu/class_ShipSimuLoginFailedMenu.php
deleted file mode 100644 (file)
index 6978654..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A LoginFailed menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLoginFailedMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuLoginFailedMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuLoginFailedMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuLoginMenu.php b/application/ship-simu/main/menu/class_ShipSimuLoginMenu.php
deleted file mode 100644 (file)
index 7aa83e9..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLoginMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuLoginMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuLoginMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuLogoutMenu.php b/application/ship-simu/main/menu/class_ShipSimuLogoutMenu.php
deleted file mode 100644 (file)
index 76b6c68..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuLogoutMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuLogoutMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuLogoutMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuRegisterMenu.php b/application/ship-simu/main/menu/class_ShipSimuRegisterMenu.php
deleted file mode 100644 (file)
index d2438f2..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuRegisterMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuRegisterMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuRegisterMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/class_ShipSimuStatusMenu.php b/application/ship-simu/main/menu/class_ShipSimuStatusMenu.php
deleted file mode 100644 (file)
index fbc0434..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A Status menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuStatusMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuStatusMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuStatusMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/menu/government/.htaccess b/application/ship-simu/main/menu/government/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php b/application/ship-simu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php
deleted file mode 100644 (file)
index 0d2112c..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A menu class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuGovernmentFailedAreaMenu extends BaseMenu implements RenderableMenu {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this class
-        *
-        * @return      $menuInstance   An instance of this class
-        */
-       public static final function createShipSimuGovernmentFailedAreaMenu () {
-               // Get a new instance
-               $menuInstance = new ShipSimuGovernmentFailedAreaMenu();
-
-               // Return the prepared instance
-               return $menuInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/opening/.htaccess b/application/ship-simu/main/opening/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/opening/bank/.htaccess b/application/ship-simu/main/opening/bank/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/opening/bank/class_MoneyBankRealtimeOpening.php b/application/ship-simu/main/opening/bank/class_MoneyBankRealtimeOpening.php
deleted file mode 100644 (file)
index 5136767..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-<?php
-/**
- * A class for the money bank's opening times
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 MoneyBankRealtimeOpening extends BaseOpening {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this opening time class
-        *
-        * @param       $bankInstance           An instance of a money bank
-        * @return      $openeningInstance      An instance of this class
-        */
-       public static final function createMoneyBankRealtimeOpening (BaseBank $bankInstance) {
-               // Get a new instance
-               $openingInstance = new MoneyBankRealtimeOpening();
-
-               // Set the bank instance here
-               $openingInstance->setBankInstance($bankInstance);
-
-               // Return the prepared instance
-               return $openingInstance;
-       }
-
-       /**
-        * Checks wether we are within the opening times
-        *
-        * @return      $withinOpeningTimes             Wether we are within opening times
-        */
-       public function ifWithinOpeningTimes () {
-               $this->partialStub();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/opening/class_ b/application/ship-simu/main/opening/class_
deleted file mode 100644 (file)
index b9f1ce7..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * A ??? opening times class
- *
- * @author             Roland Haeder <webmaster@ship-simu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @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 ???Opening extends BaseOpening {
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this opening time class
-        *
-        * @return      $openeningInstance      An instance of this class
-        */
-       public final static function create???Opening () {
-               // Get a new instance
-               $openeningInstance = new ???Opening();
-
-               // Return the prepared instance
-               return $openeningInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/opening/class_BaseOpening.php b/application/ship-simu/main/opening/class_BaseOpening.php
deleted file mode 100644 (file)
index 78f8983..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-<?php
-/**
- * A general opening time class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-abstract class BaseOpening extends BaseFrameworkSystem {
-       /**
-        * A bank instance
-        */
-       private $bankInstance = null;
-
-       /**
-        * Protected constructor
-        *
-        * @param       $className      The class' real name
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Setter for bank instance
-        *
-        * @param       $bankInstance   An instance of a bank
-        * @return      void
-        */
-       protected final function setBankInstance (BaseBank $bankInstance) {
-               $this->bankInstance = $bankInstance;
-       }
-
-       /**
-        * Checks wether we are within the opening times
-        *
-        * @return      $withinOpeningTimes             Wether we are within opening times
-        */
-       public abstract function ifWithinOpeningTimes ();
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/parts/.htaccess b/application/ship-simu/main/parts/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/parts/class_BaseShipPart.php b/application/ship-simu/main/parts/class_BaseShipPart.php
deleted file mode 100644 (file)
index aca83a9..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-<?php
-/**
- * This is a general ship part which can be used for all other ship parts...
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseShipPart extends BaseSimulator {
-       // Price of this ship part
-       private $price = 0.00;
-
-       // Konstruktor
-       protected function __construct($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Setter for price
-       public final function setPrice ($price) {
-               $this->price = (float) $price;
-       }
-
-       // Getter for price
-       public final function getPrice () {
-               return $this->price;
-       }
-
-       // Remove price
-       public final function removePrice () {
-               unset($this->price);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/parts/maschineroom/.htaccess b/application/ship-simu/main/parts/maschineroom/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/parts/maschineroom/class_MaschineRoom.php b/application/ship-simu/main/parts/maschineroom/class_MaschineRoom.php
deleted file mode 100644 (file)
index bcd7b30..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-/**
- * A maschine room class for really huge ships
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 MaschineRoom extends BaseShipPart {
-       // Constructor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Maschinenraum erstellen
-       public static final function createMaschineRoom () {
-               // Get new instance
-               $roomInstance = new MaschineRoom();
-
-               // Umrechnungsfaktoren setzen
-               $roomInstance->setResizeFactorElement('width' , 1.3);
-               $roomInstance->setResizeFactorElement('height', 1.8);
-               $roomInstance->setResizeFactorElement('length', 1.3);
-
-               // Instanz zurueckgeben
-               return $roomInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/personell/.htaccess b/application/ship-simu/main/personell/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/personell/class_SimulatorPersonell.php b/application/ship-simu/main/personell/class_SimulatorPersonell.php
deleted file mode 100644 (file)
index 8ff01e7..0000000
+++ /dev/null
@@ -1,327 +0,0 @@
-<?php
-/**
- * The general simulator personell class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 SimulatorPersonell extends BasePersonell {
-       // Personell list
-       private $personellList = null;
-
-       // A cache for lists
-       private $cacheList = null;
-
-       // A string for cached conditions
-       private $cacheCond = null;
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Magic wake-up method called when unserialize() is called. This is
-        * neccessary because in this case a personell does not need to know the
-        * min/max ages range and system classes. This would anyway use more RAM
-        * what is not required.
-        *
-        * @return      void
-        */
-       public function __wakeup () {
-               // Tidy up a little
-               $this->removePersonellList();
-               $this->removeMinMaxAge();
-               $this->removeCache();
-       }
-
-       /**
-        * Generate a specified amount of personell and return the prepared instance
-        *
-        * @param               $amountPersonell                Number of personell we shall
-        *                                                              generate
-        * @return      $personellInstance              An instance of this object with a
-        *                                                              list of personells
-        */
-       public static final function createSimulatorPersonell ($amountPersonell) {
-               // Make sure only integer can pass
-               $amountPersonell = (int) $amountPersonell;
-
-               // Get a new instance
-               $personellInstance = new SimulatorPersonell();
-
-               // Debug message
-               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $personellInstance->debugOutput(sprintf("[%s:%d] Es werden <strong>%d</strong> Personal bereitgestellt.",
-                       __CLASS__,
-                       __LINE__,
-                       $amountPersonell
-               ));
-
-               // Initialize the personell list
-               $personellInstance->createPersonellList();
-
-               // Create requested amount of personell
-               for ($idx = 0; $idx < $amountPersonell; $idx++) {
-                       $personellInstance->addRandomPersonell();
-               }
-
-               // Debug message
-               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $personellInstance->debugOutput(sprintf("[%s:%d] <strong>%d</strong> Personal bereitgestellt.",
-                       __CLASS__,
-                       __LINE__,
-                       $amountPersonell
-               ));
-
-               // Tidy up a little
-               $personellInstance->removeGender();
-               $personellInstance->removeNames();
-               $personellInstance->removeBirthday();
-               $personellInstance->removeSalary();
-               $personellInstance->removeEmployed();
-               $personellInstance->removeMarried();
-               //$personellInstance->removeCache();
-
-               // Instanz zurueckgeben
-               return $personellInstance;
-       }
-
-       /**
-        * Create a SimulatorPersonell object by loading the specified personell
-        * list from an existing database backend
-        *
-        * @param       $idNumber                       The ID number (only right part) of the list
-        * @return      $personellInstance      An instance of this class
-        * @throws      InvalidIDFormatException        If the given id number
-        *                                                                              $idNumber is invalid
-        * @throws      MissingSimulatorIdException             If an ID number was not found
-        * @deprecated
-        */
-       public static final function createSimulatorPersonellByID ($idNumber) {
-               // Get instance
-               $personellInstance = new SimulatorPersonell(false);
-               $personellInstance->makeDeprecated();
-       }
-
-       // Create personell list
-       public function createPersonellList () {
-               // Is the list already created?
-               if ($this->personelllList instanceof FrameworkArrayObject) {
-                       // Throw an exception
-                       throw new PersonellListAlreadyCreatedException($this, self::EXCEPTION_DIMENSION_ARRAY_INVALID);
-               } // END - if
-
-               // Initialize the array
-               $this->personellList = new FrameworkArrayObject("FakedPersonellList");
-       }
-
-       // Remove the personell list
-       private final function removePersonellList () {
-               unset($this->personellList);
-       }
-
-       // Add new personell object to our list
-       public function addRandomPersonell () {
-               // Gender list...
-               $genders = array("M", "F");
-
-               // Create new personell members
-               $personellInstance = new SimulatorPersonell();
-
-               // Set a randomized gender
-               $personellInstance->setGender($genders[mt_rand(0, 1)]);
-
-               // Set a randomized birthday (maximum age required, see const MAX_AGE)
-               $personellInstance->createBirthday();
-
-               // Married? Same values means: married
-               if (mt_rand(0, 5) == mt_rand(0, 5)) $personellInstance->setMarried(true);
-
-               // Tidy up a little
-               $personellInstance->removePersonellList();
-               $personellInstance->removeMinMaxAge();
-               $personellInstance->removeCache();
-
-               // Add new member to the list
-               $this->personellList->append($personellInstance);
-       }
-
-       /**
-        * Get a specifyable list of our people, null or empty string will be ignored!
-        *
-        * @return      $cacheList      A list of cached personells
-        */
-       function getSpecialPersonellList ($isEmployed = null, $isMarried = null, $hasGender = "") {
-               // Serialize the conditions for checking if we can take the cache
-               $serialized = serialize(array($isEmployed, $isMarried, $hasGender));
-
-               // The same (last) conditions?
-               if (($serialized == $this->cacheCond) && (!is_null($this->cacheCond))) {
-                       if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Gecachte Liste wird verwendet.",
-                               __CLASS__,
-                               __LINE__
-                       ));
-
-                       // Return cached list
-                       return $this->cacheList;
-               }
-
-               // Output debug message
-               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Personalliste wird nach Kriterien durchsucht...",
-                       __CLASS__,
-                       __LINE__
-               ));
-
-               // Remember the conditions
-               $this->setCacheCond($serialized);
-
-               // Create cached list
-               $this->setAllCacheList(new FrameworkArrayObject('FakedCacheList'));
-
-               // Search all unemployed personells
-               for ($idx = $this->personellList->getIterator(); $idx->valid(); $idx->next()) {
-                       // Element holen
-                       $el = $idx->current();
-
-                       // Check currenylt all single conditions (combined conditions are not yet supported)
-                       if ((!is_null($isEmployed)) && ($el->isEmployed() == $isEmployed)) {
-                               // Add this one (employed status asked)
-                               $this->cacheList->append($el);
-                       } elseif ((!is_null($isMarried)) && ($el->isMarried() == $isMarried)) {
-                               // Add this one (marrital status asked)
-                               $this->cacheList->append($el);
-                       } elseif ((!empty($hasGender)) && ($el->getGender() == $hasGender)) {
-                               // Add this one (specified gender)
-                               $this->cacheList->append($el);
-                       }
-               }
-
-               // Return the completed list
-               return $this->cacheList;
-       }
-
-       /**
-        * Get amount of unemployed personell
-        *
-        * @return      $count  Amount of unemployed personell
-        */
-       public final function getAllUnemployed () {
-               // Get a temporary list
-               $list = $this->getSpecialPersonellList(false);
-
-               // Anzahl zurueckliefern
-               return $list->count();
-       }
-
-       /**
-        * Remove cache things
-        *
-        * @return      void
-        */
-       private function removeCache () {
-               // Remove cache data
-               unset($this->cacheList);
-               unset($this->cacheCond);
-       }
-
-       /**
-        * Setter for cache list
-        *
-        * @param               $cacheList      The new cache list to set or null for initialization/reset
-        * @return      void
-        */
-       private final function setAllCacheList (FrameworkArrayObject $cacheList = null) {
-               $this->cacheList = $cacheList;
-       }
-
-       /**
-        * Setter for cache conditions
-        *
-        * @param               $cacheCond      The new cache conditions to set
-        * @return      void
-        */
-       private final function setCacheCond ($cacheCond) {
-               $this->cacheCond = (string) $cacheCond;
-       }
-
-       /**
-        * Reset cache list
-        *
-        * @return      void
-        */
-       public function resetCache () {
-               $this->setAllCacheList(null);
-               $this->setCacheCond("");
-       }
-
-       /**
-        * Getter for surname. If no surname is set then default surnames are set
-        * for male and female personells.
-        *
-        * @return      $surname        The personell' surname
-        */
-       public final function getSurname () {
-               $surname = parent::getSurname();
-
-               // Make sure every one has a surname...
-               if (empty($surname)) {
-                       if ($this->isMale()) {
-                               // Typical male name
-                               $surname = "John";
-                       } else {
-                               // Typical female name
-                               $surname = "Jennifer";
-                       }
-
-                       // Set typical family name
-                       parent::setFamily("Smith");
-               } // END - if
-
-               // Return surname
-               return $surname;
-       }
-
-       /**
-        * Getter for personell list
-        *
-        * @return      $personellList          The list of all personells
-        */
-       public final function getPersonellList () {
-               return $this->personellList;
-       }
-
-       /**
-        * Loads the mostly pre-cached personell list
-        *
-        * @param       $idNumber       The ID number we shall use for looking up
-        *                                              the right data.
-        * @return      void
-        * @deprecated
-        */
-       public function loadPersonellList ($idNumber) {
-               $this->makeDeprecated();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/personell/company/.htaccess b/application/ship-simu/main/personell/company/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/personell/company/class_CompanyEmployee.php b/application/ship-simu/main/personell/company/class_CompanyEmployee.php
deleted file mode 100644 (file)
index 472692e..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-<?php
-/**
- * Campany employees may be handled and payed within this class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 CompanyEmployee extends SimulatorPersonell {
-       // Employeee list
-       private $employeeList = null;
-
-       // Constructor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Generate a specified amount of personell
-       public static final function createCompanyEmployee ($surname, $family, $gender, $year, $month, $day, $married, $salary) {
-               // Get instance
-               $personellInstance = new CompanyEmployee();
-
-               // Debug message
-               if (((defined('DEBUG_COMPANY_EMPLOYEE')) && (defined('DEBUG_PERSONELL'))) || (defined('DEBUG_ALL'))) {
-                       $personellInstance->debugOutput(sprintf("[%s:%d] Der/Die Angestellte <strong>%s %s</strong> wird angelegt.",
-                               __CLASS__,
-                               __LINE__,
-                               $surname,
-                               $family
-                       ));
-               }
-
-               // Ist the given birthday valid?
-               if ($personellInstance->isDateValid($year, $month, $day) === false) {
-                       // Something is wrong ...
-                       throw new BirthdayInvalidException(array($year, $month, $day), self::EXCEPTION_BIRTH_DATE_IS_INVALID);
-               } // END - if
-
-               // Set birthday
-               $personellInstance->setBirthday($year, $month, $day);
-
-               // Set as employed/marrital status
-               $personellInstance->setEmployed(true);
-               $personellInstance->setMarried($married);
-
-               // Set surname/family/gender
-               $personellInstance->setSurname($surname);
-               $personellInstance->setFamily($family);
-               $personellInstance->setGender($gender);
-
-               // Set salary
-               $personellInstance->increaseSalary($salary);
-
-               // Tidy up a little
-               $personellInstance->removeEmployeeList();
-               $personellInstance->removeMinMaxAge();
-
-               // Return prepared instance
-               return $personellInstance;
-       }
-
-       // Remove the employee list
-       private function removeEmployeeList () {
-               unset($this->employeeList);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/registration/.htaccess b/application/ship-simu/main/registration/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/registration/class_ShipSimuRegistration.php b/application/ship-simu/main/registration/class_ShipSimuRegistration.php
deleted file mode 100644 (file)
index 674d189..0000000
+++ /dev/null
@@ -1,207 +0,0 @@
-<?php
-/**
- * A user registration class specially for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuRegistration extends BaseRegistration implements UserRegister {
-       /**
-        * Hashed password
-        */
-       private $hashedPassword = '';
-
-       /**
-        * Elements for criteria
-        */
-       private $criteriaElements = array(
-               'username',
-               'pass_hash',
-               'email' => 'email1',
-               'surname',
-               'family',
-               'street',
-               'zip',
-               'city',
-               'icq',
-               'jabber',
-               'yahoo',
-               'aol',
-               'msn',
-               'birth_day',
-               'birth_month',
-               'birth_year'
-       );
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Create a new instance
-        *
-        * @return      $registrationInstance   An instance of this registration class
-        */
-       public static final function createShipSimuRegistration () {
-               // Get a new instance
-               $registrationInstance = new ShipSimuRegistration();
-
-               // Initialize the filter chains
-               $registrationInstance->initFilterChains();
-
-               // And return it
-               return $registrationInstance;
-       }
-
-       /**
-        * Encrypt given request key or throw an exception if key was not found in
-        * request
-        *
-        * @param       $requestKey             Key in request class
-        * @return      void
-        */
-       public function encryptPassword ($requestKey) {
-               // Check if password is found in request
-               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
-                       // So encrypt the password and store it for later usage in
-                       // the request:
-
-                       // 1.: Get the plain password
-                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
-
-                       // 2. Get a crypto helper and hash the password
-                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword);
-
-                       // 3. Store the hash back in request
-                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
-               }
-       }
-
-       /**
-        * Perform things like informing assigned affilates about new registration
-        * before registration
-        *
-        * @return      void
-        * @todo        Maybe add more things to perform
-        */
-       public function doPreRegistration () {
-               // First run all pre filters
-               $this->executePreFilters();
-       }
-
-       /**
-        * Registers the new user account by insterting the request data into the
-        * database and paying some start credits or throw exceptions if this fails
-        *
-        * @return      void
-        * @todo        Maybe add more things to perform
-        */
-       public function registerNewUser () {
-               // Get a user database wrapper
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_db_wrapper_class');
-
-               // Use this instance to insert the whole registration instance
-               $wrapperInstance->insertRegistrationObject($this);
-       }
-
-       /**
-        * Perform things like notifying partner websites after registration is done
-        *
-        * @return      void
-        * @todo        Maybe add more things to perform
-        */
-       public function doPostRegistration () {
-               // First run all post filters
-               $this->executePostFilters();
-       }
-
-       /**
-        * Do the action which is required after all registration steps are done.
-        * This can be a simple redirect to another webpage or displaying a message
-        * to the user. Or this can be a login step into the newly created account.
-        *
-        * @return      void
-        */
-       public function doPostAction () {
-               // Get an action instance from our factory
-               $actionInstance = ObjectFactory::createObjectByConfiguredName('post_registration_class');
-
-               // Execute the action
-               $actionInstance->execute($this->getRequestInstance(), $this->getResponseInstance());
-       }
-
-       /**
-        * Adds registration elements to a given dataset instance
-        *
-        * @param       $criteriaInstance       An instance of a storeable criteria
-        * @return      void
-        */
-       public function addElementsToDataSet (StoreableCriteria $criteriaInstance) {
-               // Default is unconfirmed!
-               $configEntry = 'user_status_unconfirmed';
-
-               // Is the confirmation process entirely disabled?
-               if ($this->getConfigInstance()->getConfigEntry('confirm_email_enabled') === 'N') {
-                       // No confirmation of email needed
-                       $configEntry = 'user_status_confirmed';
-               } // END - if
-
-               // Add a lot elements to the dataset criteria
-               foreach ($this->criteriaElements as $alias => $element) {
-                       // Do we have an alias?
-                       if (is_string($alias)) {
-                               // Yes, so use it
-                               $criteriaInstance->addCriteria($alias, $this->getRequestInstance()->getRequestElement($element));
-
-                               // Debug message
-                               //* DEBUG: */ $this->debugOutput('ALIAS: alias='.$alias.',element='.$element.'='.$this->getRequestInstance()->getRequestElement($element));
-                       } else {
-                               // No, default entry
-                               $criteriaInstance->addCriteria($element, $this->getRequestInstance()->getRequestElement($element));
-
-                               // Debug message
-                               //* DEBUG: */ $this->debugOutput('DEFAULT: element='.$element.'='.$this->getRequestInstance()->getRequestElement($element));
-                       }
-
-                       // Is this a guest account?
-                       if ((($element == 'username') || ($alias == 'username')) && ($this->getRequestInstance()->getRequestElement($element) == $this->getConfigInstance()->getConfigEntry('guest_login_user'))) {
-                               // Yes, then set the config entry to guest status
-                               $configEntry = 'user_status_guest';
-                       } // END - if
-               } // END - foreach
-
-               // Mark the username as unique key
-               $criteriaInstance->setUniqueKey(UserDatabaseWrapper::DB_COLUMN_USERNAME);
-
-               // Add account status as configured
-               $criteriaInstance->addConfiguredCriteria(UserDatabaseWrapper::DB_COLUMN_USER_STATUS, $configEntry);
-
-               // Include registration timestamp
-               $criteriaInstance->addCriteria('registered', date('Y-m-d H:i:s', time()));
-       }
-}
-
-//
-?>
diff --git a/application/ship-simu/main/resolver/.htaccess b/application/ship-simu/main/resolver/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/resolver/web/.htaccess b/application/ship-simu/main/resolver/web/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/resolver/web/class_WebCompanyCommandResolver.php b/application/ship-simu/main/resolver/web/class_WebCompanyCommandResolver.php
deleted file mode 100644 (file)
index e5fcfb4..0000000
+++ /dev/null
@@ -1,190 +0,0 @@
-<?php
-/**
- * A command resolver for local (non-hubbed) web commands including the failed government request
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebCompanyCommandResolver extends BaseCommandResolver implements CommandResolver {
-       /**
-        * Last successfull resolved command
-        */
-       private $lastCommandInstance = null;
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-
-               // Set prefix to "Web"
-               $this->setCommandPrefix('Web');
-       }
-
-       /**
-        * Creates an instance of a Web command resolver with a given default command
-        *
-        * @param       $commandName                            The default command we shall execute
-        * @param       $appInstance                            An instance of a manageable application helper class
-        * @return      $resolverInstance                       The prepared command resolver instance
-        * @throws      EmptyVariableException          Thrown if default command is not set
-        * @throws      InvalidInterfaceException       Thrown if command does not implement interface Commandable
-        */
-       public static final function createWebCompanyCommandResolver ($commandName, ManageableApplication $appInstance) {
-               // Create the new instance
-               $resolverInstance = new WebCompanyCommandResolver();
-
-               // Get request instance
-               $requestInstance = $appInstance->getRequestInstance();
-
-               // Is the variable $commandName set and the command is valid?
-               if (empty($commandName)) {
-                       // Then thrown an exception here
-                       throw new EmptyVariableException(array($resolverInstance, 'commandName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
-               } elseif (!$resolverInstance->resolveCommandByRequest($requestInstance) instanceof Commandable) {
-                       // Invalid command found (missing interface?)
-                       throw new InvalidInterfaceException(array($userInstance, 'ManageableMember'), self::EXCEPTION_REQUIRED_INTERFACE_MISSING);
-               }
-
-               // Set the application instance
-               $resolverInstance->setApplicationInstance($appInstance);
-
-               // Return the prepared instance
-               return $resolverInstance;
-       }
-
-       /**
-        * Returns an command instance for a given request class or null if
-        * it was not found
-        *
-        * @param       $requestInstance        An instance of a request class
-        * @return      $commandInstance        An instance of the resolved command
-        * @throws      InvalidCommandException                         Thrown if $commandName is
-        *                                                                                              invalid
-        * @throws      InvalidCommandInstanceException         Thrown if $commandInstance
-        *                                                                                              is an invalid instance
-        */
-       public function resolveCommandByRequest (Requestable $requestInstance) {
-               // Init instance
-               $commandInstance = null;
-
-               // This goes fine so let's resolv the command
-               $commandName = str_replace('-', '_', $requestInstance->getRequestElement('app')) . '_' . $requestInstance->getRequestElement('page');
-
-               // Is there a "failed" request?
-               if ($requestInstance->isRequestElementSet('failed')) {
-                       // Then include with within the command name
-                       $commandName = $commandName . '_' . $requestInstance->getRequestElement('failed');
-               } // END - if
-
-               // Is the command empty? Then fall back to default command
-               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Check if command is valid
-               if ($this->isCommandValid($commandName) === false) {
-                       // This command is invalid!
-                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Get the command
-               $commandInstance = $this->loadCommand($commandName);
-
-               // And validate it
-               if ((!is_object($commandInstance)) || (!$commandInstance instanceof Commandable)) {
-                       // This command has an invalid instance!
-                       throw new InvalidCommandInstanceException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Set last command
-               $this->lastCommandInstance = $commandInstance;
-
-               // Return the resolved command instance
-               return $commandInstance;
-       }
-
-       /**
-        * Resolves the command by its direct name and returns an instance of its class
-        *
-        * @param       $commandName            The direct command name we shall resolve
-        * @return      $commandInstance        An instance of the command class
-        * @throws      InvalidCommandException         Thrown if $commandName is invalid
-        */
-       public function resolveCommand ($commandName) {
-               // Initiate the instance variable
-               $commandInstance = null;
-
-               // Is the command empty? Then fall back to default command
-               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Check if command is valid
-               if ($this->isCommandValid($commandName) === false) {
-                       // This command is invalid!
-                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               }
-
-               // Get the command
-               $commandInstance = $this->loadCommand($commandName);
-
-               // Return the instance
-               return $commandInstance;
-       }
-
-       /**
-        * "Loads" a given command and instances it if not yet cached
-        *
-        * @param       $commandName                            A command name we shall look for
-        * @return      $commandInstance                        A loaded command instance
-        * @throws      InvalidCommandException         Thrown if even the default
-        *                                                                              command class is missing (bad!)
-        */
-       private function loadCommand ($commandName) {
-               // Cache default command
-               $defaultCommand = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Init command instance
-               $commandInstance = null;
-
-               // Get 'app' from the application
-               $app = Registry::getRegistry()->getInstance('application')->getRequestInstance()->getRequestElement('app');
-
-               // Create command class name
-               $this->setClassName(sprintf("%s%sCommand",
-                       $this->getCommandPrefix(),
-                       $this->convertToClassName($commandName)
-               ));
-
-               // Is this class loaded?
-               if (!class_exists($this->getClassName())) {
-                       // Class not found, so throw an exception
-                       throw new InvalidCommandException(array($this, $defaultCommand), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Initiate the command
-               $commandInstance = ObjectFactory::createObjectByName($this->getClassName(), array($this));
-
-               // Return the result
-               return $commandInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php b/application/ship-simu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php
deleted file mode 100644 (file)
index 9456c08..0000000
+++ /dev/null
@@ -1,187 +0,0 @@
-<?php
-/**
- * A command resolver for local (non-hubbed) web commands including the failed government request
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 WebGovernmentFailedCommandResolver extends BaseCommandResolver implements CommandResolver {
-       /**
-        * Last successfull resolved command
-        */
-       private $lastCommandInstance = null;
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-
-               // Set prefix to "Web"
-               $this->setCommandPrefix('Web');
-       }
-
-       /**
-        * Creates an instance of a Web command resolver with a given default command
-        *
-        * @param       $commandName                            The default command we shall execute
-        * @param       $appInstance                            An instance of a manageable application helper class
-        * @return      $resolverInstance                       The prepared command resolver instance
-        * @throws      EmptyVariableException          Thrown if default command is not set
-        * @throws      InvalidInterfaceException       Thrown if command does not implement interface Commandable
-        */
-       public static final function createWebGovernmentFailedCommandResolver ($commandName, ManageableApplication $appInstance) {
-               // Create the new instance
-               $resolverInstance = new WebGovernmentFailedCommandResolver();
-
-               // Get request instance
-               $requestInstance = $appInstance->getRequestInstance();
-
-               // Is the variable $commandName set and the command is valid?
-               if (empty($commandName)) {
-                       // Then thrown an exception here
-                       throw new EmptyVariableException(array($resolverInstance, 'commandName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
-               } elseif (!$resolverInstance->resolveCommandByRequest($requestInstance) instanceof Commandable) {
-                       // Invalid command found (missing interface?)
-                       throw new InvalidInterfaceException(array($userInstance, 'ManageableMember'), self::EXCEPTION_REQUIRED_INTERFACE_MISSING);
-               }
-
-               // Set the application instance
-               $resolverInstance->setApplicationInstance($appInstance);
-
-               // Return the prepared instance
-               return $resolverInstance;
-       }
-
-       /**
-        * Returns an command instance for a given request class or null if
-        * it was not found
-        *
-        * @param       $requestInstance        An instance of a request class
-        * @return      $commandInstance        An instance of the resolved command
-        * @throws      InvalidCommandException                         Thrown if $commandName is
-        *                                                                                              invalid
-        * @throws      InvalidCommandInstanceException         Thrown if $commandInstance
-        *                                                                                              is an invalid instance
-        */
-       public function resolveCommandByRequest (Requestable $requestInstance) {
-               // Init instance
-               $commandInstance = null;
-
-               // This goes fine so let's resolv the command
-               $commandName = $requestInstance->getRequestElement('page');
-
-               // Is there a "failed" request?
-               if ($requestInstance->isRequestElementSet('failed')) {
-                       // Then include with within the command name
-                       $commandName = sprintf("%s_%s", $commandName, $requestInstance->getRequestElement('failed'));
-               } // END - if
-
-               // Is the command empty? Then fall back to default command
-               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Check if command is valid
-               if ($this->isCommandValid($commandName) === false) {
-                       // This command is invalid!
-                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Get the command
-               $commandInstance = $this->loadCommand($commandName);
-
-               // And validate it
-               if ((!is_object($commandInstance)) || (!$commandInstance instanceof Commandable)) {
-                       // This command has an invalid instance!
-                       throw new InvalidCommandInstanceException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Set last command
-               $this->lastCommandInstance = $commandInstance;
-
-               // Return the resolved command instance
-               return $commandInstance;
-       }
-
-       /**
-        * Resolves the command by its direct name and returns an instance of its class
-        *
-        * @param       $commandName            The direct command name we shall resolve
-        * @return      $commandInstance        An instance of the command class
-        * @throws      InvalidCommandException         Thrown if $commandName is invalid
-        */
-       public function resolveCommand ($commandName) {
-               // Initiate the instance variable
-               $commandInstance = null;
-
-               // Is the command empty? Then fall back to default command
-               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Check if command is valid
-               if ($this->isCommandValid($commandName) === false) {
-                       // This command is invalid!
-                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
-               }
-
-               // Get the command
-               $commandInstance = $this->loadCommand($commandName);
-
-               // Return the instance
-               return $commandInstance;
-       }
-
-       /**
-        * "Loads" a given command and instances it if not yet cached
-        *
-        * @param       $commandName                            A command name we shall look for
-        * @return      $commandInstance                        A loaded command instance
-        * @throws      InvalidCommandException         Thrown if even the default
-        *                                                                              command class is missing (bad!)
-        */
-       private function loadCommand ($commandName) {
-               // Cache default command
-               $defaultCommand = $this->getConfigInstance()->getConfigEntry('default_web_command');
-
-               // Init command instance
-               $commandInstance = null;
-
-               // Create command class name
-               $this->setClassName(sprintf("%s%sCommand",
-                       $this->getCommandPrefix(),
-                       $this->convertToClassName($commandName)
-               ));
-
-               // Is this class loaded?
-               if (!class_exists($this->getClassName())) {
-                       // Class not found, so throw an exception
-                       throw new InvalidCommandException(array($this, $defaultCommand), self::EXCEPTION_INVALID_COMMAND);
-               } // END - if
-
-               // Initiate the command
-               $commandInstance = ObjectFactory::createObjectByName($this->getClassName(), array($this));
-
-               // Return the result
-               return $commandInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/ships/.htaccess b/application/ship-simu/main/ships/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/ships/class_BaseShip.php b/application/ship-simu/main/ships/class_BaseShip.php
deleted file mode 100644 (file)
index ae22ca3..0000000
+++ /dev/null
@@ -1,167 +0,0 @@
-<?php
-/**
- * A general ship class for all other kinds of ships even small sail ships
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseShip extends BaseSimulator {
-       // Name des Shipes
-       private $shipName   = "Unbekanntes Schiff";
-
-       // Anzahl Anker
-       private $numAnchor  = 0;
-
-       // Tiefgang in Meter
-       private $draught    = 0;
-
-       // Besatzung-Objekte
-       private $crewList   = null;
-
-       // Aufbauten-Objekte
-       private $structures = null;
-
-       // Namenloses Ship generieren
-       protected function __construct($className) {
-               // Call parent constructor
-               parent::__construct($className);
-
-               // Prepare array object for all structures
-               $this->createStructuresArray();
-
-               // Clean-up a little
-               $this->removePartInstance();
-       }
-
-       // Array-Objekt anlegen
-       private function createStructuresArray () {
-               $this->structures = new FrameworkArrayObject("FakedShipStructures");
-       }
-
-       // Schiffsteil generieren (kann alles sein)
-       // buildInstance = Das was in das Schiffsteil evtl. eingebaut werden soll (null = kein besonderes Teil einbauen!)
-       // partClass = Das zu konstruierende Schiffsteil
-       public function createShipPart (ConstructableShipPart $buildInstance, $partClass) {
-               if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> erh&auml;lt ein neues Schiffsteil (%s).",
-                       __CLASS__,
-                       __LINE__,
-                       $this->getShipName(),
-                       $partClass
-               ));
-
-               // Ist die gewuenschte Klasse vorhanden?
-               if (!class_exists($partClass)) {
-                       // Nicht vorhanden, dann Ausnahme werfen!
-                       throw new NoClassException($partClass, self::EXCEPTION_CLASS_NOT_FOUND);
-               } // END - if
-
-               // Get an instance back from our object factory
-               $partInstance = ObjectFactory::createObjectByName($partClass);
-
-               // Das Einbauen versuchen...
-               try {
-                       $partInstance->addShipPartToShip($this, $buildInstance);
-               } catch (MotorShipMismatchException $e) {
-                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keinen Motor erhalten! Grund: <strong>%s</strong>",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getShipName(),
-                               $e->getMessage()
-                       ));
-                       return false;
-               } catch (RoomShipMismatchException $e) {
-                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keinen Maschinenraum erhalten! Grund: <strong>%s</strong>",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getShipName(),
-                               $e->getMessage()
-                       ));
-                       return false;
-
-               } catch (StructureShipMismatchException $e) {
-                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keine Aufbauten erhalten! Grund: <strong>%s</strong>",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getShipName(),
-                               $e->getMessage()
-                       ));
-                       return false;
-               } catch (CabinShipMismatchException $e) {
-                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keine Kabine erhalten! Grund: <strong>%s</strong>",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getShipName(),
-                               $e->getMessage()
-                       ));
-                       return false;
-               } catch (DeckShipMismatchException $e) {
-                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat kein Deck erhalten! Grund: <strong>%s</strong>",
-                               __CLASS__,
-                               __LINE__,
-                               $this->getShipName(),
-                               $e->getMessage()
-                       ));
-                       return false;
-               }
-
-               // Instanz im Aufbauten-Array vermerken
-               $this->structures->append($partInstance);
-
-               // Alles klar!
-               return true;
-       }
-
-       // Getter-Methode fuer Strukturen-Array
-       public final function getStructuresArray () {
-               return $this->structures;
-       }
-
-       // STUB: Getter-Methode Anzahl Betten
-       public function calcTotalBeds () {
-               $this->partialStub("Please implement this stub in your ship!");
-       }
-
-       // Setter-Methode fuer Schiffsnamen
-       public final function setShipName ($shipName) {
-               $this->shipName = (string) $shipName;
-       }
-
-       // Getter-Methode fuer Schiffsnamen
-       public final function getShipName () {
-               return $this->shipName;
-       }
-
-       // Setter-Methode fuer Tiefgang
-       public final function setDraught ($draught) {
-               $this->draught = (int) $draught;
-       }
-
-       // Getter-Methode fuer Tiefgang
-       public final function getDraught() {
-               return $this->draught;
-       }
-
-       // Setter-Methode fuer Anzahl Anker
-       public final function setNumAnchor ($numAnchor) {
-               $this->numAnchor = (int) $numAnchor;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/ships/passenger/.htaccess b/application/ship-simu/main/ships/passenger/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/ships/passenger/class_PassengerShip.php b/application/ship-simu/main/ships/passenger/class_PassengerShip.php
deleted file mode 100644 (file)
index 70fa5ed..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-<?php
-/**
- * A passenger ship with one or more decks, cabins, bridge (replacement for the
- * captain) and many more
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 PassengerShip extends BaseShip implements ConstructableShip {
-       // Konstruktor
-       protected function __construct () {
-               // Eltern-Kontruktor aufrufen
-               parent::__construct(__CLASS__);
-       }
-
-       // Passagier-Schiff erstellen
-       public static final function createPassengerShip ($shipName) {
-               // Get new instance
-               $passInstance = new PassengerShip();
-
-               // Set ship name
-               $passInstance->setShipName($shipName);
-
-               // Instanz zurueckgeben
-               return $passInstance;
-       }
-
-       // Anzahl Betten ermitteln
-       public final function calcTotalBeds () {
-               // Struktur-Array holen
-               $struct = $this->getStructuresArray();
-
-               if (is_null($struct)) {
-                       // Empty structures list!
-                       throw new EmptyStructuresListException($this, self::EXCEPTION_EMPTY_STRUCTURES_ARRAY);
-               } // END - if
-
-               // Anzahl Betten auf 0 setzen
-               $numBeds = 0;
-
-               // Alle Strukturen nach Kabinen durchsuchen
-               for ($idx = $struct->getIterator(); $idx->valid(); $idx->next()) {
-                       // Element holen
-                       $el = $idx->current();
-
-                       // Ist es eine Kabine?
-                       if ($el->isCabin()) {
-                               // Anzahl Betten ermitteln
-                               $total = $el->calcTotalBedsByCabin();
-                               $numBeds += $total;
-
-                               // Debug-Meldung ausgeben?
-                               if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) {
-                                       // Get new instance
-                                       $cabType = "Kabine ohne Namen";
-                                       $cab = $el->getPartInstance();
-                                       if (!is_null($cab)) {
-                                               // Kabinenbeschreibung holen
-                                               $cabType = $cab->getObjectDescription();
-                                       } // END - if
-                               } // END - if
-                       } // END - if
-               } // END - for
-
-               // Anzahl zurueckliefern
-               return $numBeds;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/.htaccess b/application/ship-simu/main/structures/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/class_BaseStructure.php b/application/ship-simu/main/structures/class_BaseStructure.php
deleted file mode 100644 (file)
index 59318cb..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-<?php
-/**
- * A general construction class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseStructure extends BaseSimulator {
-       // Price of this structure
-       private $price = 0.00;
-
-       // Konstruktor (hier keine Exceptions aendern!)
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Setter for price
-       public final function setPrice ($price) {
-               $this->price = (float) $price;
-       }
-
-       // Getter for price
-       public final function getPrice () {
-               return $this->price;
-       }
-
-       // Remove price
-       public final function removePrice () {
-               unset($this->price);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/.htaccess b/application/ship-simu/main/structures/extended/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/cabines/.htaccess b/application/ship-simu/main/structures/extended/cabines/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php b/application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php
deleted file mode 100644 (file)
index b513944..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/**
- * A general cabin class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseCabin extends BaseCabinStructure {
-       // Konstruktor
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Is this a cabin?
-       public final function isCabin () {
-               return ($this->isClass("BaseCabin"));
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/cabines/ship/.htaccess b/application/ship-simu/main/structures/extended/cabines/ship/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/cabines/ship/class_EconomyCabin.php b/application/ship-simu/main/structures/extended/cabines/ship/class_EconomyCabin.php
deleted file mode 100644 (file)
index beceae8..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Cabins in the economy class may use this class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 EconomyCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Economy-Kabine erstellen
-       public static final function createEconomyCabin ($numLuxury, $numRooms, $numBeds, $dim) {
-               // Get new instance
-               $ecoInstance = new EconomyCabin();
-
-               // Abmasse extrahieren
-               $ecoInstance->extractDimensions($dim);
-
-               // Den Rest auch setzen
-               $ecoInstance->setNumCabin($numLuxury);
-               $ecoInstance->setNumRooms($numRooms);
-               $ecoInstance->setNumBeds($numBeds);
-
-               // Nicht noetig!
-               $ecoInstance->removePartInstance();
-
-               // Instanz zurueckgeben
-               return $ecoInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/cabines/ship/class_LowCabin.php b/application/ship-simu/main/structures/extended/cabines/ship/class_LowCabin.php
deleted file mode 100644 (file)
index 23b877c..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Cabins in the lower decks may use this class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 LowCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // 2-Sterne-Klasse erstellen
-       public static final function createLowCabin ($numLuxury, $numRooms, $numBeds, $dim) {
-               // Get new instance
-               $lowInstance = new LowCabin();
-
-               // Abmasse extrahieren
-               $lowInstance->extractDimensions($dim);
-
-               // Den Rest auch setzen
-               $lowInstance->setNumCabin($numLuxury);
-               $lowInstance->setNumRooms($numRooms);
-               $lowInstance->setNumBeds($numBeds);
-
-               // Nicht noetig!
-               $lowInstance->removePartInstance();
-
-               // Instanz zurueckgeben
-               return $lowInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/cabines/ship/class_LuxuryCabin.php b/application/ship-simu/main/structures/extended/cabines/ship/class_LuxuryCabin.php
deleted file mode 100644 (file)
index 78cb9c4..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Luxury class cabins  resists here
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 LuxuryCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Eine Luxuskabine erstellen
-       public static final function createLuxuryCabin ($numLuxury, $numRooms, $numBeds, $dim) {
-               // Get new instance
-               $luxuryInstance = new LuxuryCabin();
-
-               // Abmasse extrahieren
-               $luxuryInstance->extractDimensions($dim);
-
-               // Den Rest auch setzen
-               $luxuryInstance->setNumCabin($numLuxury);
-               $luxuryInstance->setNumRooms($numRooms);
-               $luxuryInstance->setNumBeds($numBeds);
-
-               // Nicht noetig!
-               $luxuryInstance->removePartInstance();
-
-               // Instanz zurueckgeben
-               return $luxuryInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/cabines/ship/class_PremierCabin.php b/application/ship-simu/main/structures/extended/cabines/ship/class_PremierCabin.php
deleted file mode 100644 (file)
index 522e301..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * So-called "premier class" cabins are constructed with this class (medium class)
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 PremierCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Premier-Kabine erstellen
-       public static final function createPremierCabin ($numLuxury, $numRooms, $numBeds, $dim) {
-               // Get new instance
-               $premierInstance = new PremierCabin();
-
-               // Abmasse extrahieren
-               $premierInstance->extractDimensions($dim);
-
-               // Den Rest auch setzen
-               $premierInstance->setNumCabin($numLuxury);
-               $premierInstance->setNumRooms($numRooms);
-               $premierInstance->setNumBeds($numBeds);
-
-               // Nicht noetig!
-               $premierInstance->removePartInstance();
-
-               // Instanz zurueckgeben
-               return $premierInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/class_ b/application/ship-simu/main/structures/extended/class_
deleted file mode 100644 (file)
index 9644fd5..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-
-       /**
-        * Limits this object with an ObjectLimits instance
-        */
-       public function limitObject (ObjectLimits $limitInstance) {
-               die("limitObject() reached! Stub!");
-       }
diff --git a/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php b/application/ship-simu/main/structures/extended/class_BaseCabinStructure.php
deleted file mode 100644 (file)
index 77a81ae..0000000
+++ /dev/null
@@ -1,135 +0,0 @@
-<?php
-/**
- * General cabin structure class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseCabinStructure extends BaseStructure {
-       // --- Besondere Eigenschaften dazufuegen: ---
-       // Anzahl der Kabinen im Schiff
-       private $numCabin = 0;
-
-       // Anzahl Raeume pro Kabine (kann auch nur 1 sein)
-       private $numRooms = 0;
-
-       // Anzahl Betten, verallgemeinert
-       private $numBeds = 0;
-
-       // Konstruktor
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Kabine hinzufuegen
-       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $cabinInstance) {
-               // Eltern-Methode aufrufen
-               parent::addShipPartToShip ($shipInstance, $cabinInstance);
-
-               // Restlichen Daten ebenfalls
-               $this->setNumCabin($cabinInstance->numCabin);
-               $this->setNumRooms($cabinInstance->numRooms);
-               $this->setNumBeds($cabinInstance->numBeds);
-
-               // Unnoetige Attribute entfernen
-               $cabinInstance->removeNumCabin();
-               $cabinInstance->removeNumRooms();
-               $cabinInstance->removeNumBeds();
-
-               // Instanz setzen
-               $this->setDeckInstance($cabinInstance);
-       }
-
-       // Wrapper fuer setDeckInstance->setPartInstance
-       public final function setDeckInstance ($deck) {
-               parent::setPartInstance($deck);
-       }
-
-       // Getter-Methode fuer Anzahl Betten
-       public final function getNumBeds () {
-               return $this->numBeds;
-       }
-
-       // Getter-Methode fuer Anzahl Kabinen
-       public final function getNumCabin () {
-               return $this->numCabin;
-       }
-
-       // Setter-Methode fuer Anzahl Betten
-       public final function setNumBeds ($numBeds) {
-               $this->numBeds = $numBeds;
-       }
-
-       // Setter-Methode fuer Anzahl Raeume
-       public final function setNumRooms ($numRooms) {
-               $this->numRooms = $numRooms;
-       }
-
-       // Setter-Methode fuer Anzahl Kabinen
-       public final function setNumCabin ($numCabin) {
-               $this->numCabin = $numCabin;
-       }
-
-       // Loesch-Methode fuer Anzahl Betten
-       public final function removeNumBeds() {
-               unset($this->numBeds);
-       }
-
-       // Loesch-Methode fuer Anzahl Kabinen
-       public final function removeNumCabin() {
-               unset($this->numCabin);
-       }
-
-       // Loesch-Methode fuer Anzahl Raeume
-       public final function removeNumRooms() {
-               unset($this->numRooms);
-       }
-
-       // Bettenanzahl pro Kabine berechnen
-       public function calcTotalBedsByCabin () {
-               // Dann Bettenanzahl holen und aufaddieren
-               $beds = $this->getNumBeds();
-               $num  = $this->getNumCabin();
-               $cabinBeds = $beds * $num;
-               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) {
-                       // Get new instance
-                       $cabType = "Kabine ohne Namen";
-                       $cab = $this->getPartInstance();
-                       if (!is_null($cab)) {
-                               // Kabinenbeschreibung holen
-                               $cabType = $cab->__toString();
-                       }
-
-                       // Debug-Meldung ausgeben
-                       $this->debugOutput(sprintf("[%s:%d] Es exisitieren <strong>%d</strong> Kabinen vom Typ <strong>%s</strong> zu je <strong>%d</strong> Betten. Das sind <strong>%d</strong> Betten.",
-                               __CLASS__,
-                               __LINE__,
-                               $num,
-                               $cabType,
-                               $beds,
-                               $cabinBeds
-                       ));
-               }
-               return $cabinBeds;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php b/application/ship-simu/main/structures/extended/class_BaseDeckStructure.php
deleted file mode 100644 (file)
index 0f44a55..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-<?php
-/**
- * A general deck structure class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseDeckStructure extends BaseStructure {
-       // Anzahl Decks
-       private $numDecks = 0;
-
-       // Konstruktor
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       // Deckstruktur dem Schiff hinzufuegen
-       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $deckInstance) {
-               // Eltern-Methode aufrufen
-               parent::addShipPartToShip($shipInstance, $deckInstance);
-
-               // Andere Daten uebertragen und von der Quelle loeschen
-               $this->setNumDecks($deckInstance->getNumDecks());
-               $deckInstance->removeNumDecks();
-       }
-
-       // Deckanzahl entfernen
-       public final function removeNumDecks() {
-               unset($this->numDecks);
-       }
-
-       // Setter-Methode fuer Anzahl Decks
-       public final function setNumDecks($numDecks) {
-               $this->numDecks = (int) $numDecks;
-       }
-
-       // Getter-Methode fuer Anzahl Decks
-       public final function getNumDecks() {
-               return $this->numDecks;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php b/application/ship-simu/main/structures/extended/class_BaseUpperStructure.php
deleted file mode 100644 (file)
index dd6934c..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * A general upper structure class.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseUpperStructure extends BaseStructure {
-       /**
-        * Constructor for all super structures on a ship
-        *
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/decks/.htaccess b/application/ship-simu/main/structures/extended/decks/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/decks/cargo/.htaccess b/application/ship-simu/main/structures/extended/decks/cargo/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/decks/cargo/class_CarDeck.php b/application/ship-simu/main/structures/extended/decks/cargo/class_CarDeck.php
deleted file mode 100644 (file)
index d87dd09..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-<?php
-/**
- * A deck class for cars with ramps and about 2.5 meters hich
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 CarDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // Autodeck erstellen
-       public static final function createCarDeck ($numDecks, $dim) {
-               // Get new instance
-               $carInstance = new CarDeck();
-
-               // Abmasse extrahieren
-               $carInstance->extractDimensions($dim);
-
-               // Andere Daten uebetragen
-               $carInstance->setNumDecks($numDecks);
-
-               // Nicht noetige Instanz
-               $carInstance->removePartInstance();
-
-               // Instanz zurueckgeben
-               return $carInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/decks/cargo/class_TrainDeck.php b/application/ship-simu/main/structures/extended/decks/cargo/class_TrainDeck.php
deleted file mode 100644 (file)
index 07410ea..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-<?php
-/**
- * A train deck with rails constructed in it
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 TrainDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // LKW-Deck erstellen
-       public static final function createTrainDeck ($numDecks, $dim) {
-               // Get new instance
-               $trainInstance = new TrainDeck();
-
-               // Abmasse extrahieren
-               $trainInstance->extractDimensions($dim);
-
-               // Andere Daten uebetragen
-               $trainInstance->setNumDecks($numDecks);
-
-               // Nicht noetige Instanz
-               $trainInstance->removePartInstance();
-
-               // Instanz zurueckliefern
-               return $trainInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/decks/cargo/class_TruckDeck.php b/application/ship-simu/main/structures/extended/decks/cargo/class_TruckDeck.php
deleted file mode 100644 (file)
index 6a87d85..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-<?php
-/**
- * A truck and bus decks. Also other vehicle may be put in here if they don't
- * match into the car deck.
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 TruckDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
-       // Konstruktor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       // LKW-Deck erstellen
-       public static final function createTruckDeck ($numDecks, $dim) {
-               // Get new instance
-               $truckInstance = new TruckDeck();
-
-               // Abmasse extrahieren
-               $truckInstance->extractDimensions($dim);
-
-               // Andere Daten uebetragen
-               $truckInstance->setNumDecks($numDecks);
-
-               // Nicht noetige Instanz
-               $truckInstance->removePartInstance();
-
-               // Instanz zurueckliefern
-               return $truckInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php b/application/ship-simu/main/structures/extended/decks/class_BaseDeck.php
deleted file mode 100644 (file)
index 7b92d68..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/**
- * A general cabin class
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 BaseDeck extends BaseDeckStructure {
-       /**
-        * Constructor for cargo decks in general
-        *
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/structures/extended/lower/.htaccess b/application/ship-simu/main/structures/extended/lower/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/upper/.htaccess b/application/ship-simu/main/structures/extended/upper/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/structures/extended/upper/class_Bridge.php b/application/ship-simu/main/structures/extended/upper/class_Bridge.php
deleted file mode 100644 (file)
index 1c3b674..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-<?php
-/**
- * The control bridge of the ship
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 Bridge extends BaseUpperStructure implements TradeableItem, ConstructableShipPart {
-       // Constructor
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-
-               // Clean up a little
-               $this->removePartInstance();
-       }
-
-       // Eine Kommandobruecke erstellen
-       public static final function createBridge ($width, $height, $length) {
-               // Get new instance
-               $bridgeInstance = new Bridge();
-
-               // Abmasse setzen
-               $bridgeInstance->setWidth($width);
-               $bridgeInstance->setHeight($height);
-               $bridgeInstance->setLength($length);
-
-               // Instanz zurueckgeben
-               return $bridgeInstance;
-       }
-
-       // Overwritten method for tradeable items
-       public function isTradeable () {
-               return true;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/user/.htaccess b/application/ship-simu/main/user/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/user/class_ShipSimuBaseUser.php b/application/ship-simu/main/user/class_ShipSimuBaseUser.php
deleted file mode 100644 (file)
index 75de2c7..0000000
+++ /dev/null
@@ -1,261 +0,0 @@
-<?php
-/**
- * A special member class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
-       /**
-        * Protected constructor
-        *
-        * @param       $className      Name of the class
-        * @return      void
-        */
-       protected function __construct ($className) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Initializes the bank instance
-        *
-        * @return      $bankInstance   A bank instance wether just created or from registry
-        */
-       protected function initBankInstance () {
-               // Init instance
-               $bankInstance = null;
-
-               try {
-                       // Get a money bank instance from registry
-                       $bankInstance = Registry::getRegistry()->getInstance('money_bank');
-               } catch (NullPointerException $e) {
-                       // Instance not found in registry
-                       // @TODO We should log this exception later
-               }
-
-               // Is it there?
-               if (is_null($bankInstance)) {
-                       // Then create a new one
-                       $bankInstance = ObjectFactory::createObjectByConfiguredName('bank_class', array($this));
-
-                       // Store it in registry
-                       Registry::getRegistry()->addInstance('money_bank', $bankInstance);
-               } // END - if
-
-               // Return the instance
-               return $bankInstance;
-       }
-
-       /**
-        * Initializes the government instance
-        *
-        * @return      $governmentInstance             A government instance
-        */
-       protected function initGovernmentInstance () {
-               // Init instance
-               $governmentInstance = null;
-
-               try {
-                       // First get a government instance from registry
-                       $governmentInstance = Registry::getRegistry()->getInstance('government');
-               } catch (NullPointerException $e) {
-                       // Instance not found in registry
-                       // @TODO We should log this exception later
-               }
-
-               // Is it there?
-               if (is_null($governmentInstance)) {
-                       // Then create a new one
-                       $governmentInstance = ObjectFactory::createObjectByConfiguredName('government_class', array($this));
-
-                       // Store it in registry
-                       Registry::getRegistry()->addInstance('government', $governmentInstance);
-               } // END - if
-
-               // Return the prepared instance
-               return $governmentInstance;
-       }
-
-       /**
-        * Checks wether the user has reached maximum allowed companies to found
-        *
-        * @return      $reached        Wether the user has reached maximum allowed companies to found
-        */
-       public function ifUserCreatedMaximumAllowedCompanies () {
-               // Get max allowed companies to found
-               $maxFound = $this->getConfigInstance()->getConfigEntry('max_allowed_companies_found');
-
-               // Now get a search criteria and set the user's name as criteria
-               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
-               $searchInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
-               $searchInstance->setLimit($maxFound);
-
-               // Get a company wrapper
-               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class');
-
-               // Do the count-select by criteria
-               $totalRows = $wrapperInstance->doSelectCountByCriteria($searchInstance);
-
-               // Does the user have reached maximum?
-               $reached = ($totalRows >= $maxFound);
-
-               // Return the result
-               return $reached;
-       }
-
-       /**
-        * Checks wether the user has the required amount of points left for the specified action
-        *
-        * @param       $action                 The action or configuration entry plus prefix the user wants to perform
-        * @return      $hasRequired    Wether the user has the required points
-        */
-       public function ifUserHasRequiredPoints ($action) {
-               // Default is that everyone is poor... ;-)
-               $hasRequired = false;
-
-               // Init instance
-               $pointsInstance = null;
-
-               try {
-                       // Get a points instance from registry
-                       $pointsInstance = Registry::getRegistry()->getInstance('points');
-               } catch (NullPointerException $e) {
-                       // Instance not found in registry
-                       // @TODO We should log this exception later
-               }
-
-               // Is there an instance?
-               if (is_null($pointsInstance)) {
-                       // Then create one
-                       $pointsInstance = ObjectFactory::createObjectByConfiguredName('user_points_class', array($this));
-
-                       // And store it in registry
-                       Registry::getRegistry()->addInstance('points', $pointsInstance);
-               } // END - if
-
-               // Just forward this request to the user points class
-               $hasRequired = $pointsInstance->ifUserHasRequiredPoints($action);
-
-               // Return the result
-               return $hasRequired;
-       }
-
-       /**
-        * Determines if government can still pay a "virtual training course" in general
-        *
-        * @return      $ifGovHelps             Wether if government helps the user with a virtual training course
-        */
-       public function ifGovernmentPaysTraining () {
-               // By default they want to help.
-               $ifGovHelps = true;
-
-               // Initialize government instance
-               $governmentInstance = $this->initGovernmentInstance();
-
-               // Then ask the government if they want to pay a "startup help" to the user
-               $ifGovHelps = ($governmentInstance->ifGovernmentAlreadyPayedTraining());
-
-               // Return result here
-               return $ifGovHelps;
-       }
-
-       /**
-        * Determines if government can still pay a "startup help" to the user
-        *
-        * @return      $ifGovHelps             Wether if government helps the user with some startup money
-        */
-       public function ifGovernmentPaysStartupHelp () {
-               // By default they want to help.
-               $ifGovHelps = true;
-
-               // Initialize government instance
-               $governmentInstance = $this->initGovernmentInstance();
-
-               // Then ask the government if they want to pay a "startup help" to the user
-               $ifGovHelps = ($governmentInstance->ifGovernmentPayedMaxmimumStartupHelp());
-
-               // Return result here
-               return $ifGovHelps;
-       }
-
-       /**
-        * Checks wether the user can take points from the money bank
-        *
-        * @return      $bankLends      Wether the money bank is able to lend money
-        * @todo        Need to implement MoneyBank::ifBankLendsMoreMoney()
-        */
-       public function ifUserAllowedTakeCreditsFromMoneyBank () {
-               // Per default the money bank cannot pay
-               $bankLends = false;
-
-               // Initialize bank instance
-               $bankInstance->initBankInstance();
-
-               // Does the money bank lend more money?
-               $bankLends = ($bankInstance->ifBankLendsMoreMoney());
-
-               // Return result
-               return $bankLends;
-       }
-
-       /**
-        * Checks wether the user has maximum credits with the money bank. This
-        * should be done seperately from checking if the user is allowed to take
-        * credits from the bank.
-        *
-        * @return      $hasMaxCredits  Wether the user has maximum credits with the bank
-        * @todo        Need to check the bank if they can lend more money
-        */
-       public function ifUserHasMaximumCreditsWithMoneyBank () {
-               // For default he can still get money
-               $hasMaxCredits = false;
-
-               // Initialize the bank instance
-               $bankInstance = $this->initBankInstance();
-
-               // Now check if the user has maximum credits
-               $hasMaxCredits = ($bankInstance->ifUserHasMaxCredits());
-
-               // Return the result
-               return $hasMaxCredits;
-       }
-
-       /**
-        * Checks wether the money bank has opened
-        *
-        * @return      $hasOpened      Wether the money bank has opened
-        */
-       public function ifMoneyBankHasOpened () {
-               // Default is not opened
-               $hasOpened = false;
-
-               // Initialize the bank instance
-               $bankInstance = $this->initBankInstance();
-
-               // Has this bank opened?
-               $hasOpened = ($bankInstance->ifMoneyBankHasOpened());
-
-               // Return result
-               return $hasOpened;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/user/extended/.htaccess b/application/ship-simu/main/user/extended/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/user/extended/class_ShipSimuGuest.php b/application/ship-simu/main/user/extended/class_ShipSimuGuest.php
deleted file mode 100644 (file)
index a66de18..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-<?php
-/**
- * A special guest class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuGuest extends ShipSimuBaseUser implements ManageableGuest {
-       // Exceptions
-       const EXCEPTION_USERNAME_NOT_FOUND   = 0x170;
-       const EXCEPTION_USER_EMAIL_NOT_FOUND = 0x171;
-       const EXCEPTION_USER_PASS_MISMATCH   = 0x172;
-
-       /**
-        * Protected constructor
-        *
-        * @param       $className      Name of the class
-        * @return      void
-        */
-       protected function __construct ($className = __CLASS__) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Creates an instance of this user class by a provided username. This
-        * factory method will check if username is already taken and if not
-        * so it will throw an exception.
-        *
-        * @param       $userName               Username we need a class instance for
-        * @return      $userInstance   An instance of this user class
-        * @throws      UsernameMissingException        If the username does not exist
-        */
-       public static final function createGuestByUsername ($userName) {
-               // Get a new instance
-               $userInstance = new ShipSimuGuest();
-
-               // Set the username
-               $userInstance->setUserName($userName);
-
-               // Check if username exists
-               if ($userInstance->ifUsernameExists() === false) {
-                       // Throw an exception here
-                       throw new UsernameMissingException(array($userInstance, $userName), self::EXCEPTION_USERNAME_NOT_FOUND);
-               } // END - if
-
-               // Return the instance
-               return $userInstance;
-       }
-
-       /**
-        * Creates an instance of this user class by a provided email address. This
-        * factory method will not check if email address is there.
-        *
-        * @param       $email                  Email address of the user
-        * @return      $userInstance   An instance of this user class
-        */
-       public static final function createGuestByEmail ($email) {
-               // Get a new instance
-               $userInstance = new ShipSimuGuest();
-
-               // Set the username
-               $userInstance->setEmail($email);
-
-               // Return the instance
-               return $userInstance;
-       }
-
-       /**
-        * Updates the last activity timestamp and last performed action in the
-        * database result. You should call flushPendingUpdates() to flush these updates
-        * to the database layer.
-        *
-        * @param       $requestInstance        A requestable class instance
-        * @return      void
-        */
-       public function updateLastActivity (Requestable $requestInstance) {
-               // No activity will be logged for guest accounts
-       }
-
-       /**
-        * Flushs all pending updates to the database layer
-        *
-        * @return      void
-        */
-       public function flushPendingUpdates () {
-               // No updates will be flushed to database!
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/user/extended/class_ShipSimuMember.php b/application/ship-simu/main/user/extended/class_ShipSimuMember.php
deleted file mode 100644 (file)
index a37ef16..0000000
+++ /dev/null
@@ -1,220 +0,0 @@
-<?php
-/**
- * A special member class for Ship-Simu
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 ShipSimuMember extends ShipSimuBaseUser implements ManageableMember, BookableAccount {
-       /**
-        * Protected constructor
-        *
-        * @param       $className      Name of the class
-        * @return      void
-        */
-       protected function __construct ($className = __CLASS__) {
-               // Call parent constructor
-               parent::__construct($className);
-       }
-
-       /**
-        * Destructor for e.g. flushing pending updates to the database
-        *
-        * @return      void
-        */
-       public function __destruct () {
-               // Flush any updated entries to the database
-               $this->flushPendingUpdates();
-
-               // Call parent destructor
-               parent::__destruct();
-       }
-
-       /**
-        * Creates an instance of this user class by a provided username. This
-        * factory method will check if username is already taken and if not
-        * so it will throw an exception.
-        *
-        * @param       $userName               Username we need a class instance for
-        * @return      $userInstance   An instance of this user class
-        * @throws      UsernameMissingException        If the username does not exist
-        */
-       public static final function createMemberByUsername ($userName) {
-               // Get a new instance
-               $userInstance = new ShipSimuMember();
-
-               // Set the username
-               $userInstance->setUserName($userName);
-
-               // Check if username exists
-               if ($userInstance->ifUsernameExists() === false) {
-                       // Throw an exception here
-                       throw new UsernameMissingException(array($userInstance, $userName), self::EXCEPTION_USERNAME_NOT_FOUND);
-               } // END - if
-
-               // Return the instance
-               return $userInstance;
-       }
-
-       /**
-        * Creates an instance of this user class by a provided email address. This
-        * factory method will not check if email address is there.
-        *
-        * @param       $email                  Email address of the user
-        * @return      $userInstance   An instance of this user class
-        */
-       public static final function createMemberByEmail ($email) {
-               // Get a new instance
-               $userInstance = new ShipSimuMember();
-
-               // Set the username
-               $userInstance->setEmail($email);
-
-               // Return the instance
-               return $userInstance;
-       }
-
-       /**
-        * Creates a user by a given request instance
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @return      $userInstance           An instance of this user class
-        * @todo        Add more ways of creating user instances
-        */
-       public static final function createMemberByRequest (Requestable $requestInstance) {
-               // Determine if by email or username
-               if (!is_null($requestInstance->getRequestElement('username'))) {
-                       // Username supplied
-                       $userInstance = self::createMemberByUserName($requestInstance->getRequestElement('username'));
-               } elseif (!is_null($requestInstance->getRequestElement('email'))) {
-                       // Email supplied
-                       $userInstance = self::createMemberByEmail($requestInstance->getRequestElement('email'));
-               } else {
-                       // Unsupported mode
-                       $userInstance = new ShipSimuMember();
-                       $userInstance->partialStub("We need to add more ways of creating user classes here.");
-                       $userInstance->debugBackTrace();
-                       exit();
-               }
-
-               // Return the prepared instance
-               return $userInstance;
-       }
-
-       /**
-        * Updates the last activity timestamp and last performed action in the
-        * database result. You should call flushPendingUpdates() to flush these updates
-        * to the database layer.
-        *
-        * @param       $requestInstance        A requestable class instance
-        * @return      void
-        */
-       public function updateLastActivity (Requestable $requestInstance) {
-               // Set last action
-               $lastAction = $requestInstance->getRequestElement('action');
-
-               // If there is no action use the default on
-               if (is_null($lastAction)) {
-                       $lastAction = $this->getConfigInstance()->getConfigEntry('login_default_action');
-               } // END - if
-
-               // Get a critieria instance
-               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
-
-               // Add search criteria
-               $searchInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
-               $searchInstance->setLimit(1);
-
-               // Now get another criteria
-               $updateInstance = ObjectFactory::createObjectByConfiguredName('update_criteria_class');
-
-               // And add our both entries
-               $updateInstance->addCriteria('last_activity', date('Y-m-d H:i:s', time()));
-               $updateInstance->addCriteria('last_action', $lastAction);
-
-               // Add the search criteria for searching for the right entry
-               $updateInstance->setSearchInstance($searchInstance);
-
-               // Set wrapper class name
-               $updateInstance->setWrapperConfigEntry('user_db_wrapper_class');
-
-               // Remember the update in database result
-               $this->getResultInstance()->add2UpdateQueue($updateInstance);
-       }
-
-       /**
-        * Books the given 'amount' in the request instance on the users 'points
-        * account'
-        *
-        * @param       $requestInstance        An instance of a Requestable class
-        * @return      void
-        */
-       public function bookAmountDirectly (Requestable $requestInstance) {
-               // Init points instance
-               $pointsInstance = null;
-
-               try {
-                       // Get the points class from registry
-                       $pointsInstance = Registry::getRegistry()->getInstance('points');
-               } catch (NullPointerException $e) {
-                       // Instance not found in registry
-                       // @TODO We should log this later
-               }
-
-               // Is the points instance null?
-               if (is_null($pointsInstance)) {
-                       // Then get a new one
-                       $pointsInstance = ObjectFactory::createObjectByConfiguredName('user_points_class', array($this));
-
-                       // And store it in registry
-                       Registry::getRegistry()->addInstance('points', $pointsInstance);
-               } // END - if
-
-               // Get the amount
-               $amount = $requestInstance->getRequestElement('amount');
-
-               // Call the method for booking points
-               $pointsInstance->bookPointsDirectly($amount);
-       }
-
-       /**
-        * Flushs all pending updates to the database layer
-        *
-        * @return      void
-        */
-       public function flushPendingUpdates () {
-               // Is the object valid?
-               if (!$this->getResultInstance() instanceof SearchableResult) {
-                       // Abort here
-                       return;
-               } // END - if
-
-               // Do we have data to update?
-               if ($this->getResultInstance()->ifDataNeedsFlush()) {
-                       // Get a database wrapper
-                       $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_db_wrapper_class');
-
-                       // Yes, then send the whole result to the database layer
-                       $wrapperInstance->doUpdateByResult($this->getResultInstance());
-               } // END - if
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/wrapper/.htaccess b/application/ship-simu/main/wrapper/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php b/application/ship-simu/main/wrapper/class_CompanyDatabaseWrapper.php
deleted file mode 100644 (file)
index 1552e67..0000000
+++ /dev/null
@@ -1,129 +0,0 @@
-<?php
-/**
- * A wrapper for database access to shipping company data
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 CompanyDatabaseWrapper extends BaseDatabaseWrapper {
-       /**
-        * Company instance
-        */
-       private $companyInstance = null;
-
-       // Constants for database tables
-       const DB_TABLE_COMPANY_DATA = 'company';
-       const DB_TABLE_COMPANY_USER = 'company_user';
-
-       // Constants for database columns
-       const DB_COLUMN_PARTICIPANT_ID = 'participant_id';
-
-       /**
-        * Protected constructor
-        *
-        * @return      void
-        */
-       protected function __construct () {
-               // Call parent constructor
-               parent::__construct(__CLASS__);
-       }
-
-       /**
-        * Creates an instance of this wrapper class
-        *
-        * @param       $companyInstance        An instance of a generic company class or null if no specific
-        * @return      $wrapperInstance        An instance of this wrapper class
-        * @todo        Find an interface which is suitable for all companies
-        */
-       public static final function createCompanyDatabaseWrapper (ShippingCompany $companyInstance = null) {
-               // Create a new instance
-               $wrapperInstance = new CompanyDatabaseWrapper();
-
-               // Set (primary!) table name
-               $wrapperInstance->setTableName(self::DB_TABLE_COMPANY_DATA);
-
-               // Set the company instance if not null
-               if (!is_null($companyInstance)) {
-                       $wrapperInstance->setCompanyInstance($companyInstance);
-               } // END - if
-
-               // Return the instance
-               return $wrapperInstance;
-       }
-
-       /**
-        * Checks wether the given user participates in a company
-        *
-        * @param       $userInstance   An instance of a user class
-        * @return      $participates   Wether the user participates at lease in one company
-        */
-       public function ifUserParticipatesInCompany (ManageableAccount $userInstance)  {
-               // By default no user owns any company... ;)
-               $participates = false;
-
-               // Get a search criteria class
-               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
-
-               // Add the user primary key as a search criteria
-               $searchInstance->addCriteria(self::DB_COLUMN_PARTICIPANT_ID, $userInstance->getPrimaryKey());
-               $searchInstance->setLimit(1);
-
-               // Set company->user table
-               $this->setTableName(self::DB_TABLE_COMPANY_USER);
-
-               // Get the result back
-               $resultInstance = $this->doSelectByCriteria($searchInstance);
-
-               // Is there a result?
-               if ($resultInstance->next()) {
-                       // Then cache it
-                       $this->setResultInstance($resultInstance);
-
-                       // Entry found for further analysis/processing
-                       $participates = true;
-               } // END - if
-
-               // Return the result
-               return $participates;
-       }
-
-       /**
-        * Setter for company instance
-        *
-        * @param       $companyInstance        An instance of a generic company
-        * @return      void
-        * @todo        Find an interface suitable for all types of companies
-        */
-       protected final function setCompanyInstance (ShippingCompany $companyInstance) {
-               $this->companyInstance = $companyInstance;
-       }
-
-       /**
-        * Getter for company instance
-        *
-        * @return      $companyInstance        An instance of a generic company
-        * @todo        Find an interface suitable for all types of companies
-        */
-       public final function getCompanyInstance () {
-               return $this->companyInstance;
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/main/wrapper/class_UserGovernmentDatabaseWrapper.php b/application/ship-simu/main/wrapper/class_UserGovernmentDatabaseWrapper.php
deleted file mode 100644 (file)
index 6392d6b..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-<?php
-/**
- * A wrapper for database access to government->user data
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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 UserGovernmentDatabaseWrapper extends BaseDatabaseWrapper {
-       // Constants for database tables
-       const DB_TABLE_USER_GOVERNMENT = 'gov_user';
-
-       // Database columns
-       const DB_COLUMN_GOV_USERID   = 'gov_uid';
-       const DB_COLUMN_GOV_ACTIVITY = 'gov_activity_status';
-
-       /**
-        * 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 static final function createUserGovernmentDatabaseWrapper () {
-               // Create a new instance
-               $wrapperInstance = new UserGovernmentDatabaseWrapper();
-
-               // Set (primary!) table name
-               $wrapperInstance->setTableName(self::DB_TABLE_USER_GOVERNMENT);
-
-               // Return the instance
-               return $wrapperInstance;
-       }
-
-       /**
-        * Registers the given startup help request with the government
-        *
-        * @param       $requestInstance        A Requestable instance
-        * @return      void
-        */
-       public function registerStartupHelpByRequest (Requestable $requestInstance) {
-               $requestInstance->debugInstance();
-       }
-}
-
-// [EOF]
-?>
diff --git a/application/ship-simu/starter.php b/application/ship-simu/starter.php
deleted file mode 100644 (file)
index 7ba3538..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-/**
- * The application launcher
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.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/>.
- */
-
-// Is there an application helper instance? We need the method main() for
-// maining the application
-$app = call_user_func_array(array(FrameworkConfiguration::getSelfInstance()->getConfigEntry('app_helper_class'), 'getSelfInstance'), array());
-
-// Some sanity checks
-if ((empty($app)) || (is_null($app))) {
-       // Something went wrong!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because the helper class <span class=\"class_name\">%s</span> is not loaded.",
-               $application,
-               FrameworkConfiguration::getSelfInstance()->getConfigEntry('app_helper_class')
-       ));
-} elseif (!is_object($app)) {
-       // No object!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because &#39;app&#39; is not an object.",
-               $application
-       ));
-} elseif (!method_exists($app, FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method'))) {
-       // Method not found!
-       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because the method <span class=\"method_name\">%s</span> is missing.",
-               $application,
-               FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method')
-       ));
-}
-
-// Call user function
-call_user_func_array(array($app, FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method')), array());
-
-// [EOF]
-?>
diff --git a/application/ship-simu/templates/.htaccess b/application/ship-simu/templates/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/de/.htaccess b/application/ship-simu/templates/de/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/de/.xml b/application/ship-simu/templates/de/.xml
deleted file mode 100644 (file)
index d7d7d08..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_company.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_company.ctp
deleted file mode 100644 (file)
index b9df5fc..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-<?php
-// Get a link helper instance
-$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'list_companies'));
-
-// Prefetch the user data
-$linkInstance->prefetchValueInstance('user');
-
-// Add link group for company founder
-$linkInstance->addLinkGroup('company_founder', "Vielleicht willst du eine Reederei gr&uuml;nden, um dich selbstst&auml;ndig zu machen?");
-
-// Maximum of allowed companies reached?
-if ($linkInstance->getValueInstance()->ifUserCreatedMaximumAllowedCompanies()) {
-       // No more companies allowed to found
-       $linkInstance->addLinkNote('company_maximum', "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
-       $linkInstance->addActionLinkById('company_found', 'found_company');
-}
-
-// Add link group for government
-$linkInstance->addLinkGroup('government', "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
-       $linkInstance->addActionLinkById('company_list', 'list_company');
-} elseif ($linkInstance->getValueInstance()->ifGovernmentPaysTraining()) {
-       // Government is able to pay a training in general
-       $linkInstance->addActionLinkById('government_training', 'list_training_by_government');
-
-       // Can the government pay startup help?
-       if ($linkInstance->getValueInstance()->ifGovernmentPaysStartupHelp()) {
-               // Add link note
-               $linkInstance->addLinkNote('government_startup_help', "Starthilfe beantragen:");
-
-               // Display link to government for startup help
-               $linkInstance->addActionLinkById('government_startup_help', 'apply_startup_help_government');
-       } // END - if
-} elseif ($linkInstance->getValueInstance()->ifGovernmentPaysStartupHelp()) {
-       // Display link to government for startup help
-       $linkInstance->addActionLinkById('government_startup_help', 'apply_startup_help_government');
-} else {
-       // Even government cannot help the gamer here
-       $linkInstance->addLinkNote('government_depleted', "Leider kann dir der Staat nicht mehr weiterhelfen, dich zu bewerben, da du zu oft Starthilfen erhalten hast oder ein Training absolviert hast. Hier muss aber noch weiter am Spiel gearbeitet werden. :-)");
-}
-
-// Checks wether the money bank has opened
-if ($linkInstance->getValueInstance()->ifMoneyBankHasOpened()) {
-       // Add link group for money bank
-       $linkInstance->addLinkGroup('moneybank', "Leihe dir zu g&uuml;nstigen Zinsen Geld aus, wenn du mehr brauchst!");
-
-       // Add link to moneybank
-       if ($linkInstance->getValueInstance()->ifUserAllowedTakeCreditsFromMoneyBank()) {
-               // Display link to money bank page
-               $linkInstance->addActionLinkById('moneybank', 'virtual_money_bank');
-       } elseif ($linkInstance->getValueInstance()->ifUserHasMaximumCreditsWithMoneyBank()) {
-               // Maximum credits reached which a money bank can lent
-               $linkInstance->addLinkNote('moneybank_depleted', "Die Spielebank kann dir kein Geld mehr leihen, bitte zahle es auch wieder zur&uuml;ck.");
-               $linkInstance->addActionLinkById('moneybank_payback_credits', 'payback_credits_to_money_bank');
-       } else {
-               // Unexpected state of the bank
-               $linkInstance->addLinkNote('moneybank_error', "Es wurde ein Fehler in der Spielebank erkannt. Bitte melde dies dem Support.");
-       }
-} else {
-       // Money bank is closed!
-       $linkInstance->addLinkGroup('moneybank', "Die Spielebank hat geschlossen.");
-       $linkInstance->addLinkNote('moneybank_closed', "Die Spielebank hat derzeit geschlossen. Bitte sp&auml;ter nochmal versuchen.");
-}
-
-// Add link group for refill page
-$linkInstance->addLinkGroup('refill_page', "Hole dir Geld von uns zu fairen Preisen!");
-
-if ($linkInstance->ifRefillPageActive()) {
-       // Display link to refill page
-       $linkInstance->addActionLinkById('refill', 'refill_virtual_money');
-} else {
-       // Refill page not active
-       $linkInstance->addLinkNote('refill_disabled', "Das Aufladen ist derzeit nicht m&ouml;glich oder gest&ouml;rt und wurde von uns deaktiviert.");
-}
-
-// Flush content to the template
-$linkInstance->flushContent();
-
-// [EOC]
-?>
-<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_footer">
-               {?list_companies?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_government_startup_help.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_government_startup_help.ctp
deleted file mode 100644 (file)
index e300a01..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-// Get form helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_government_startup'));
-
-// Prefetch user instance
-$helperInstance->prefetchValueInstance('user');
-
-// Add main form group
-$helperInstance->addFormNote('reality_warning', "WARNUNG: Bitte dieses Formular nicht mit echten Angaben ausf&uuml;llen! (Die Profildaten sollte jedoch echt sein.)");
-
-// Add group for personal data
-$helperInstance->addFormGroup('persona_data', "Deine pers&ouml;nliche Daten, die f&uuml;r die Beantragung n&ouml;tig sind:");
-
-// Display email, surname and family name
-$helperInstance->addFormNote('surname', "Vorname: <span class=\"persona_data\">".$helperInstance->getValueField('surname')."</span>");
-$helperInstance->addFormNote('family', "Nachname: <span class=\"persona_data\">".$helperInstance->getValueField('family')."</span>");
-$helperInstance->addFormNote('email', "Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
-$helperInstance->addFormNote('birthday', "Geburtstag: <span class=\"persona_data\">".(int)$helperInstance->getValueField('birth_day').".".(int)$helperInstance->getValueField('birth_month').".".(int)$helperInstance->getValueField('birth_year')."</span>");
-
-// Add link placeholder for profile page
-$helperInstance->addFormNote('profile', "Stimmen die Daten noch? {?shipsimu_profile?}");
-
-// Ask again for current account password
-$helperInstance->addFormGroup('password', "Bitte gebe zur Best&auml;tigung dein derzeitiges Passwort ein.");
-$helperInstance->addFieldText('password', "Derzeitiges Passwort:");
-$helperInstance->addInputPasswordField('password');
-
-// CAPTCHA enabled?
-if ($helperInstance->ifFormSecuredWithCaptcha()) {
-       $helperInstance->addFormGroup('captcha_user', "Die virtuelle Beantragung von Starthilfe ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du die Starthilfe beantragen kannst.");
-       $helperInstance->addCaptcha();
-} // END - if
-
-// Final notices
-$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
-$helperInstance->addInputResetButton("Alles nochmal eingeben");
-$helperInstance->addInputSubmitButton("Starthilfe beantragen");
-$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
-
-// Flush the finished form
-$helperInstance->flushContent();
-
-// Get link helper for profile link
-$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'shipsimu_profile'));
-
-// Add action
-$linkInstance->addActionLinkById('profile', 'profile');
-
-// Flush the finished form
-$linkInstance->flushContent();
-
-// [EOC]
-?>
-<div id="government_frame">
-       <div id="government_header">
-               Virtuelle Beantragung von Starthilfe
-       </div>
-
-       <div id="government_form">
-               {?shipsimu_government_startup?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_government_training.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_government_training.ctp
deleted file mode 100644 (file)
index 7c921ff..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-// Get form helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_government_training'));
-
-// Prefetch user instance
-$helperInstance->prefetchValueInstance('user');
-
-// Add main form group
-$helperInstance->addFormNote('reality_warning', "WARNUNG: Bitte dieses Formular nicht mit echten Angaben ausf&uuml;llen!");
-
-// Add group for personal data
-$helperInstance->addFormGroup('persona_data', "Deine pers&ouml;nliche Daten, die f&uuml;r die Kursusteilnahme n&ouml;tig sind:");
-
-// Ask again for current account password
-$helperInstance->addFormGroup('password', "Bitte gebe zur Best&auml;tigung dein derzeitiges Passwort ein.");
-$helperInstance->addFieldText('password', "Derzeitiges Passwort:");
-$helperInstance->addInputPasswordField('password');
-
-// Display email, surname and family name
-$helperInstance->addFormNote('surname', "Vorname: <span class=\"persona_data\">".$helperInstance->getValueField('surname')."</span>");
-$helperInstance->addFormNote('family', "Nachname: <span class=\"persona_data\">".$helperInstance->getValueField('family')."</span>");
-$helperInstance->addFormNote('email', "Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
-$helperInstance->addFormNote('birthday', "Geburtstag: <span class=\"persona_data\">".(int)$helperInstance->getValueField('birth_day').".".(int)$helperInstance->getValueField('birth_month').".".(int)$helperInstance->getValueField('birth_year')."</span>");
-
-// Add link placeholder for profile page
-$helperInstance->addFormNote('profile', "Stimmen die Daten noch? {?shipsimu_profile?}");
-
-// CAPTCHA enabled?
-if ($helperInstance->ifFormSecuredWithCaptcha()) {
-       $helperInstance->addFormGroup('captcha_user', "Die virtuelle Beantragung eines Trainingkursus ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, um den Trainingskursus zu beantragen.");
-       $helperInstance->addCaptcha();
-} // END - if
-
-// Final notices
-$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
-$helperInstance->addInputResetButton("Alles nochmal eingeben");
-$helperInstance->addInputSubmitButton("Trainingskurs beantragen");
-$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
-
-// Flush the finished form
-$helperInstance->flushContent();
-
-// Get link helper for profile link
-$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'shipsimu_profile'));
-
-// Add action
-$linkInstance->addActionLinkById('profile', 'profile');
-
-// Flush the finished form
-$linkInstance->flushContent();
-
-// [EOC]
-?>
-<div id="government_frame">
-       <div id="government_header">
-               Virtuelle Beantragung eines Training-Kursus
-       </div>
-
-       <div id="government_form">
-               {?shipsimu_government_training?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_logout.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_logout.ctp
deleted file mode 100644 (file)
index 5443af2..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout_now'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('logout_now');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'return_login'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('return_login');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="logout_box">
-       <div id="logout_header">
-               Willst du dich wirklich aus dem Spiel ausloggen?
-       </div>
-
-       <div id="logouts">
-               {?logout_now?} | {?return_login?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_profile.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_profile.ctp
deleted file mode 100644 (file)
index 8037a4e..0000000
+++ /dev/null
@@ -1,145 +0,0 @@
-<?php
-// Get helper instance for web forms. This will add the opening form-tag to
-// the helper's render cache which is simply a small variable in the class
-// BaseHelper.
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, "shipsimu_profile"));
-
-// Pre-fetch field data with a given registry key
-$helperInstance->prefetchValueInstance('user');
-
-// Password can only be changed when the old one is entered and new one twice!
-$helperInstance->addFormGroup('pass', "Neues Passwort einrichten:");
-$helperInstance->addFormSubGroup('pass', "Bitte gebe zum &Auml;ndern deines Passwortes zweimal das gew&uuml;nschte neue Passwort ein.");
-$helperInstance->addFieldText('pass1', "Neues Passwort:");
-$helperInstance->addInputPasswordField('pass1');
-$helperInstance->addFieldText('pass2', "Neues Passwort, Wiederholung:");
-$helperInstance->addInputPasswordField('pass2');
-
-// Display current email
-$helperInstance->addFormNote('current_email', "Derzeitige Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
-
-// Only for changing email address
-if ($helperInstance->ifEmailChangeAllowed()) {
-       $helperInstance->addFormGroup('email', "&Auml;nderung deiner Email-Addresse:");
-       $helperInstance->addFormSubGroup('email', "Gebe nur deine Email-Adresse zweimal ein, wenn du diese &auml;ndern m&ouml;chtest!");
-       $helperInstance->addFieldText('email1', "Email-Adresse:");
-       $helperInstance->addInputTextField('email1');
-       $helperInstance->addFieldText('email2', "Wiederholung Email-Adresse:");
-       $helperInstance->addInputTextField('email2');
-
-       if ($helperInstance->ifEmailMustBeUnique()) {
-               $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
-       } // END - if
-
-       if ($helperInstance->ifEmailChangeRequireConfirmation()) {
-               $helperInstance->addFormNote('confirm', "Es wird ein Best&auml;tigungslink an deine neue Email-Adresse gesendet. Bitte klicke diesen dann m&ouml;glichst schnell an.");
-       } // END - if
-} // END - if
-
-// Add form group for user profile
-$helperInstance->addFormGroup('profile', "Hier kannst du deine Profildaten &auml;ndern.");
-
-// Persoenliche Daten mit in der Anmeldung abfragen?
-if ($helperInstance->ifRegisterIncludesPersonaData()) {
-       $helperInstance->addFormSubGroup('persona', "Wenn du magst, dann vervollst&auml;ndige deine komplette Adresse mit deinem Namen.");
-       $helperInstance->addFieldText('surname', "Dein Vorname:");
-       $helperInstance->addInputTextFieldWithDefault('surname');
-       $helperInstance->addFieldText('family', "Dein Nachname:");
-       $helperInstance->addInputTextFieldWithDefault('family');
-       $helperInstance->addFieldText('street', "Strasse und Hausnummer:");
-       $helperInstance->addInputTextFieldWithDefault('street');
-       $helperInstance->addFieldText('city', "Wohnort:");
-       $helperInstance->addInputTextFieldWithDefault('city');
-
-       // Include birthday?
-       if ($helperInstance->ifProfileIncludesBirthDay()) {
-               $helperInstance->addFormSubGroup('birthday', "Verrate uns doch dein Geburtsdatum, als Dankesch&ouml;n erh&auml;lst du interessante Pr&auml;mien - ausschliesslich per Email - zum Geburtstag zugesandt! G&uuml;ltiges Format: TT.MM.JJJJ");
-               $helperInstance->addInputTextField('birth_day');
-               $helperInstance->addFieldText('birth_day', ".");
-               $helperInstance->addInputTextField('birth_month');
-               $helperInstance->addFieldText('birth_day', ".");
-               $helperInstance->addInputTextField('birth_year');
-       } // END - if
-} // END - if
-
-// Add sub group for zip code
-$helperInstance->addFormSubGroup('zip', "Magst du uns auch deine Postleitzahl verraten?");
-$helperInstance->addFieldText('zip', "Postleitzahl:");
-$helperInstance->addInputTextFieldWithDefault('zip');
-
-// Add sub group for chat protocols
-$helperInstance->addFormSubGroup('chat', "Gebe hier deine Nicknames bzw. Nummern an:");
-
-// Add ICQ chat?
-if ($helperInstance->ifChatEnabled('icq')) {
-       $helperInstance->addFieldText('icq', "ICQ-Nummer:");
-       $helperInstance->addInputTextFieldWithDefault('icq');
-} // END - if
-
-// Add Jabber chat?
-if ($helperInstance->ifChatEnabled('jabber')) {
-       $helperInstance->addFieldText('jabber', "Jabber:");
-       $helperInstance->addInputTextFieldWithDefault('jabber');
-} // END - if
-
-// Add Yahoo! chat?
-if ($helperInstance->ifChatEnabled('yahoo')) {
-       $helperInstance->addFieldText('yahoo', "Yahoo!:");
-       $helperInstance->addInputTextFieldWithDefault('yahoo');
-} // END - if
-
-// Add AOL chat?
-if ($helperInstance->ifChatEnabled('aol')) {
-       $helperInstance->addFieldText('aol', "AOL-Screenname:");
-       $helperInstance->addInputTextFieldWithDefault('aol');
-} // END - if
-
-// Add MSN chat?
-if ($helperInstance->ifChatEnabled('msn')) {
-       $helperInstance->addFieldText('msn', "MSN:");
-       $helperInstance->addInputTextFieldWithDefault('msn');
-} // END - if
-
-if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
-       $helperInstance->addFormExtraNote(1, "Die Benachrichtigungen per Email sind im Loginbereich verfeinerbar, welche du genau haben willst.");
-} // END - if
-
-// Rules already accepted?
-if ($helperInstance->ifRulesHaveChanged()) {
-       $helperInstance->addFormGroup('rules', "Bitte lese dir die Spieleregeln gut durch und kreuze dann &quot;Ja, ich akzeptiere die aktuellen Spielregeln&quot; an.");
-       $helperInstance->addFieldText('rules', "Ja, ich akzeptiere die aktuellen Spielregeln:");
-       $helperInstance->addInputCheckboxField('rules', false);
-} else {
-       $helperInstance->addFormNote('rules_accepted', "Du hast die aktuellen Spielregeln akzeptiert. Vielen Dank!");
-       $helperInstance->addInputHiddenField('rules', "1");
-}
-
-// CAPTCHA enabled?
-if ($helperInstance->ifFormSecuredWithCaptcha()) {
-       $helperInstance->addFormGroup('captcha_user', "Das &Auml;ndern von Profildaten ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit deine &Auml;nderungen gespeichert werden k&ouml;nnen.");
-       $helperInstance->addCaptcha();
-} // END - if
-
-// Ask again for current account password
-$helperInstance->addFormGroup('pass_old', "Bitte gebe zur Best&auml;tigung der &Auml;nderungen dein derzeitiges Passwort ein.");
-$helperInstance->addFieldText('pass_old', "Derzeitiges Passwort:");
-$helperInstance->addInputPasswordField('pass_old');
-
-// Final notices
-$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
-$helperInstance->addInputResetButton("Alles nochmal eingeben");
-$helperInstance->addInputSubmitButton("Accountdaten aktualisieren");
-$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
-
-// Flush finished form
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Deine Profildaten bearbeiten
-</div>
-
-<div id="profile_box">
-       {?shipsimu_profile?}
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_refill.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_refill.ctp
deleted file mode 100644 (file)
index fdc7c4e..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-<?php
-// Neue Helper-Instanz holen
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_refill'));
-
-// Pre-fetch payment types
-$helperInstance->prefetchValueInstance('payments');
-
-// Add form group
-$helperInstance->addFormGroup('refill_form', "Bitte w&auml;hle aus, was du nachbestellen willst und gebe die Menge an.");
-
-// Add sub group
-$helperInstance->addInputSelectField('type', "--- Bitte ausw&auml;hlen ---");
-
-// In-game currencies (if more than default add them here!)
-$helperInstance->addSelectSubOption('currencies', "--- W&auml;hrungen ---");
-$helperInstance->addSelectOption('currency', "{?currency?}");
-
-// Raw resources
-$helperInstance->addSelectSubOption('raw_resources', "--- Rohstoffe ---");
-$helperInstance->addSelectOption('raw_wood', "Holz");
-$helperInstance->addSelectOption('raw_iron', "Metall");
-$helperInstance->addSelectOption('raw_stones', "Steine");
-
-// This is needed to close the select tag
-$helperInstance->addInputSelectField('type', "");
-
-// Field for amount
-$helperInstance->addFormSubGroup('amount', "Gebe hier in ganzen Zahlen die Menge an, die du nachbestellen willst.");
-$helperInstance->addInputTextField('amount', 1000);
-
-// Add payments
-$helperInstance->getValueInstance()->addResultsToHelper($helperInstance);
-
-// Ask again for current account password
-$helperInstance->addFormGroup('pass_old', "Bitte gebe zur Best&auml;tigung der Nachbestellung dein derzeitiges Passwort ein.");
-$helperInstance->addFieldText('pass_old', "Derzeitiges Passwort:");
-$helperInstance->addInputPasswordField('pass_old');
-
-// CAPTCHA enbaled?
-if ($helperInstance->ifFormSecuredWithCaptcha()) {
-       $helperInstance->addFormGroup('captcha_refill', "Bitte wiederhole den angezeigten Code:");
-       $helperInstance->addCaptcha();
-} // END - if
-
-// Submit button
-$helperInstance->addFormGroup('buttons_refill', "Mit Absenden des Formulars wird deine Nachbestellung verbindlich!");
-$helperInstance->addInputResetButton("Eingaben l&ouml;schen");
-$helperInstance->addInputSubmitButton("Nachbestellung verbindlich aufgeben");
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="refill_frame">
-       <div class="content_header">
-               Jetzt dein {?currency?}-Konto aufladen!
-       </div>
-       <div class="content_body">
-               {?shipsimu_refill?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_status_problem.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_status_problem.ctp
deleted file mode 100644 (file)
index df4a8de..0000000
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-// Get helper instance for web forms. This will add the opening form-tag to
-// the helper's render cache which is simply a small variable in the class
-// BaseHelper.
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'resend_link'));
-
-// Pre-fetch field data with a given registry key
-$helperInstance->prefetchValueInstance('user');
-
-// Add submit button or notice
-if ($helperInstance->ifUserAccountUnconfirmed()) {
-       // Add submit button
-       $helperInstance->addInputHiddenFieldWithDefault('email');
-       $helperInstance->addInputSubmitButton("Best&auml;tigungslink erneut aussenden");
-} elseif ($helperInstance->ifUserAccountLocked()) {
-       // Account is locked
-       $helperInstance->addFormNote('status_locked', "Dein Account wurde gesperrt! Grund der Sperre:
-               <span id=\"lock_reason\">".$helperInstance->getValueField('lock_reason')."</span>
-               Bitte melde dich beim Support, damit dieser dir weiterhelfen kann."
-       );
-} elseif ($helperInstance->ifUserAccountGuest()) {
-       // Account is guest account
-       $helperInstance->addFormNote('status_guest', "G&auml;steaccounts sind in der Funktionalit&auml;t
-               leicht eingeschr&auml;nkt. Bitte melde dich an, damit du ein
-               vollwertiges Account bekommst."
-       );
-}
-
-// Flush content and automatically close the form
-$helperInstance->flushContent();
-
-// Build the form for confirmation
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'confirm_code'));
-
-// Pre-fetch field data with a given registry key
-$helperInstance->prefetchValueInstance('user');
-
-if ($helperInstance->ifUserAccountUnconfirmed()) {
-       // Add code box
-       $helperInstance->addFormGroup('code', "Bitte gebe hier den Best&auml;tigungscode aus der Willkommensemail ein. Solltest du diese nicht erhalten haben, kannst du dir diesen jetzt zusenden lassen.");
-       $helperInstance->addFieldText('code', "Best&auml;tigungscode aus der Mail:");
-       $helperInstance->addInputTextField('code');
-
-       // Add submit button
-       $helperInstance->addFormGroup('buttons', "Bitte einmal abschicken und das Ergebnis abwarten!");
-       $helperInstance->addInputResetButton("Nochmal eingeben");
-       $helperInstance->addInputSubmitButton("Best&auml;tigungscode absenden");
-} else {
-       // Add message
-       $helperInstance->addFormNote('status_not_unconfirmed', "M&ouml;glicherweise hast du einen Best&auml;tigungslink angeklickt, obwohl dein Account bereits freigegeben oder gesperrt ist.");
-}
-
-// Flush content and automatically close the form
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Problem mit deinem Account gefunden:
-</div>
-
-<div id="status_box">
-       Du bist m&ouml;glicherweise f&uuml;r deine ausgew&auml;hlte Aktion nicht
-       berechtigt oder du hast noch deine Email-Adresse nicht best&auml;tigt. Du
-       kannst dir nun den Best&auml;tigungslink erneut aussenden lassen, oder den
-       Best&auml;tigungscode unten eingeben.
-
-       <div id="resend_link_box">
-               {?resend_link?}
-       </div>
-
-       <div id="confirm_code_header">
-               Weitere M&ouml;glichkeiten:
-       </div>
-
-       <div id="confirm_code_box">
-               {?confirm_code?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/action_ship_simu_login_welcome.ctp b/application/ship-simu/templates/de/code/action_ship_simu_login_welcome.ctp
deleted file mode 100644 (file)
index 413a72a..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-<div id="news_frame">
-       {?shipsimu_login_news?}
-</div>
diff --git a/application/ship-simu/templates/de/code/block_company_data.ctp b/application/ship-simu/templates/de/code/block_company_data.ctp
deleted file mode 100644 (file)
index 9752acf..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-<?php
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'company'));
-
-// Set link text
-$helperInstance->addActionLinkById('company', 'company');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div class="user_name_div">
-       Firmenstatus: <span class="company_status">{?company_status?}</span>
-</div>
-<div class="user_profile_div">
-       {?company?}
-</div>
diff --git a/application/ship-simu/templates/de/code/block_persona_data.ctp b/application/ship-simu/templates/de/code/block_persona_data.ctp
deleted file mode 100644 (file)
index bff6bfa..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-// Get a helper instance for the profile link (and maybe later more!)
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'profile'));
-
-// Prefetch user instance
-$helperInstance->prefetchValueInstance('user');
-
-// Flush the content out
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="user_name_div" class="block_cell">
-       Spielername: <span id="user_name">{?block_username?}</span>
-</div>
-<div id="user_status_div" class="block_cell">
-       Spielerstatus: <span id="user_status">{?block_user_status?}</span>
-</div>
-<div id="user_points_div" class="block_cell">
-       {?currency?}: <span id="user_points">{?block_points?}</span>
-</div>
-<div id="user_profile_div" class="block_cell">
-       {?profile?}
-</div>
-<div id="user_registered_div" class="block_cell">
-       Angemeldet seit: <span id="registered">{?block_registered?}</span>
-</div>
diff --git a/application/ship-simu/templates/de/code/captch_graphic_code.ctp b/application/ship-simu/templates/de/code/captch_graphic_code.ctp
deleted file mode 100644 (file)
index 121fb00..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-// Get a helper instance without a form tag
-$captchaHelper = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'captcha_code', false, false));
-
-// Add input field with text for CAPTCHA code
-$captchaHelper->addFieldText('captcha_code', "Bitte wiederhole den Code:");
-$captchaHelper->addInputTextField('c_code');
-
-// Add hidden field with validation hash
-$captchaHelper->addInputHiddenField('hash', $this->readVariable('captcha_hash'));
-
-// Flush content
-$captchaHelper->flushContent();
-
-// [EOC]
-?>
-<div class="captcha_image">
-       <img src="$config[base_url]/index.php?app={?app_short_name?}&amp;page=code_captcha&amp;encrypt={?encrypted_code?}&amp;request=image"
-        alt="CAPTCHA-Bild" title="CAPTCHA-Bild" class="captcha_img" />
-</div>
-<div class="captcha_code">
-       {?captcha_code?}
-</div>
diff --git a/application/ship-simu/templates/de/code/confirm_link.ctp b/application/ship-simu/templates/de/code/confirm_link.ctp
deleted file mode 100644 (file)
index 25f6e67..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'direct_login'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('direct_login');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Best&auml;tigung Deiner Email-Adresse:
-</div>
-
-<div id="content_body">
-       Hallo <span class="data_username">{?username?}</span>! Du hast heute deine
-       Email-Addresse best&auml;tigt, wodurch alle Spielefunktionen entsperrt
-       worden sind. Viel Spass beim Spielen!
-</div>
-
-<div id="content_footer">
-       {?direct_login?}
-</div>
diff --git a/application/ship-simu/templates/de/code/emergency_exit.ctp b/application/ship-simu/templates/de/code/emergency_exit.ctp
deleted file mode 100644 (file)
index e974daf..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-{?header:title="Problem in application framework detected!"?}
-
-<div id="emergency_message">
-       $content[message]
-</div>
-
-<div id="emergency_backtrace">
-       <div id="backtrace_header">
-               File inclusion backtrace:
-       </div>
-       <div id="backtrace_content">
-               $content[backtrace]
-       </div>
-</div>
-
-<div id="stats_box">
-       <div id="stats_header">
-               Statistics
-       </div>
-       <div id="stats_objects">
-               Total objects: $content[total_objects]
-       </div>
-       <div id="stats_includes">
-               Loaded class files: $content[total_includes]
-               <span class="hint">(Including exception and interfaces.)</span>
-       </div>
-</div>
-
-{?footer_msg:footer_msg="Please contact the support and supply the full above message, if you think you are not qualified to fix this problem."?}
diff --git a/application/ship-simu/templates/de/code/footer.ctp b/application/ship-simu/templates/de/code/footer.ctp
deleted file mode 100644 (file)
index aa82e68..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-</div> <!-- masterbox //-->
-
-</body>
-</html>
diff --git a/application/ship-simu/templates/de/code/footer_msg.ctp b/application/ship-simu/templates/de/code/footer_msg.ctp
deleted file mode 100644 (file)
index fb1de36..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-       <div id="footer_message">
-               $content[footer_msg]
-       </div>
-
-</div> <!-- masterbox //-->
-
-</body>
-</html>
diff --git a/application/ship-simu/templates/de/code/government_failed_main.ctp b/application/ship-simu/templates/de/code/government_failed_main.ctp
deleted file mode 100644 (file)
index b073132..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-<?php
-///////////////////////////////
-// Assign personal user data //
-///////////////////////////////
-
-// Get a new instance for personal data
-$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'persona_data'));
-
-// Set the data source instance which must exist in registry
-$blockInstance->prefetchValueInstance('user');
-
-// Assign fields with template variables
-$blockInstance->assignField('username');
-$blockInstance->assignFieldWithFilter('user_status', "user_status_translator");
-
-// Shall we include registration date?
-if ($blockInstance->ifIncludeRegistrationStamp()) {
-       // Then assign it as well!
-       $blockInstance->assignFieldWithFilter('registered', 'formatTimestamp');
-} // END - if
-
-// Flush the content out to a template variable
-$blockInstance->flushContent();
-
-//////////////////////////////////////
-// Assign the shipping company data //
-//////////////////////////////////////
-
-// Get a new instance for personal data
-$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'company_data'));
-
-// Set the data source instance
-$blockInstance->prefetchValueInstance('company', 'user');
-
-// Assign the company name
-if ($blockInstance->getValueInstance()->ifUserIsFounder()) {
-       // User is the founder of the company
-       $blockInstance->assignMessageField('company_status', "user_is_company_founder");
-       $blockInstance->assignLinkFieldWithAction('company' , "company_overview");
-       $blockInstance->assignMessageField('company', "link_text_company_overview");
-       $blockInstance->assignMessageField('company_title', "link_title_company_overview");
-} elseif ($blockInstance->getValueInstance()->ifUserIsOwner()) {
-       // User owns the company
-       $blockInstance->assignMessageField('company_status', "user_is_company_owner");
-       $blockInstance->assignLinkFieldWithAction('company' , "company_overview");
-       $blockInstance->assignMessageField('company', "link_text_company_overview");
-       $blockInstance->assignMessageField('company_title', "link_title_company_overview");
-} elseif ($blockInstance->getValueInstance()->ifUserIsEmployee()) {
-       // User is employed in company
-       $blockInstance->assignMessageField('company_status', "user_is_employed_in_company");
-       $blockInstance->assignLinkFieldWithAction('company' , "employee_overview");
-       $blockInstance->assignMessageField('company', "link_text_employee_overview");
-       $blockInstance->assignMessageField('company_title', "link_title_employee_overview");
-} else {
-       // No company participation!
-       $blockInstance->assignMessageField('company_status', "user_not_assigned_company");
-       $blockInstance->assignLinkFieldWithAction('company' , "company");
-       $blockInstance->assignMessageField('company', "link_text_company");
-       $blockInstance->assignMessageField('company_title', "link_title_company");
-}
-
-// Flush the content out to a template variable
-$blockInstance->flushContent();
-
-// Get helper instance
-$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout'));
-
-// Add action
-$linkInstance->addActionLinkById('logout', 'logout');
-
-// Flush the content
-$linkInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Willkommen zum Staat in <span class="app_name">{?app_full_name?}</span>!
-</div>
-
-<div id="content_body">
-       {?government_failed_content?}
-</div>
-
-<div id="persona_data" title="Informationen zu Deinem Spieleaccount">
-       <div id="persona_header">
-               Account-Infos:
-       </div>
-
-       <div id="persona_body">
-               {?persona_data?}
-       </div>
-
-       <div id="logout">
-               {?logout?}
-       </div>
-</div>
-
-<div id="company_data" title="Informationen zu der aktuell ausgew&auml;hlten Reederei">
-       <div id="company_header">
-               Reederei-Infos:
-       </div>
-
-       <div id="company_body">
-               {?company_data?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/header.ctp b/application/ship-simu/templates/de/code/header.ctp
deleted file mode 100644 (file)
index ed67731..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de" lang="de">
-<head>
-       <title>
-               {?app_full_name?} - {?title?}
-       </title>
-
-       <meta name="author" content="$config[meta_author]" />
-       <meta name="publisher" content="$config[meta_publisher]" />
-       <meta name="keywords" content="$config[meta_keywords]" />
-       <meta name="robots" content="index,follow" />
-       <meta name="description" content="$config[meta_description]" />
-       <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
-       <meta http-equiv="content-style-type" content="text/css" />
-       <meta http-equiv="content-script-type" content="text/javascript" />
-       <meta http-equiv="language" content="de" />
-       {?header_extras_hook?}
-</head>
-
-<body>
-<div id="masterbox">
diff --git a/application/ship-simu/templates/de/code/header_extras_hook.ctp b/application/ship-simu/templates/de/code/header_extras_hook.ctp
deleted file mode 100644 (file)
index 4375e22..0000000
+++ /dev/null
@@ -1 +0,0 @@
-<!-- Some extra CSS/JS stuff should be added here (by script!) //-->
diff --git a/application/ship-simu/templates/de/code/home.ctp b/application/ship-simu/templates/de/code/home.ctp
deleted file mode 100644 (file)
index c530602..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<div id="content_header">
-       Willkommen zum <span class="app_name">{?app_full_name?}</span>
-</div>
-
-<div id="news_frame">
-       {?shipsimu_news?}
-</div>
diff --git a/application/ship-simu/templates/de/code/login_failed.ctp b/application/ship-simu/templates/de/code/login_failed.ctp
deleted file mode 100644 (file)
index 166c48e..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-<?php
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'login_retry'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('login_retry');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Du bist nicht mehr im Spiel eingeloggt!
-</div>
-
-<div id="content_body">
-       <div id="login_failed_header">
-               Du bist nicht mehr in <span class="app_name">{?app_full_name?}</span> eingeloggt.
-               Dies kann verschiedene Gr&uuml;nde haben:
-       </div>
-
-       <ol id="login_failed_list">
-               <li>Dein Browser nimmt keine Cookies an.</li>
-               <li>Du hast den Loginbereich aus deinen Bookmarks/Favoriten aufgerufen
-                       und die Cookies sind gel&ouml;scht.</li>
-               <li>Es besteht ein Problem mit dem Server, wof&uuml;r du meistens nichts
-                       kannst. Bitte kontaktiere den Support, falls dieses Problem
-                       weiterhin besteht.</li>
-       </ol>
-
-       <div id="login_failed_footer">
-               Wenn du den Support kontaktierst, halte bitte s&auml;mtliche relevante
-               Informationen - <span class="important_note">nicht aber dein Passwort</span>
-               - bereit. Du kannst auch einen Screenshot dieser Seite anfertigen und dem
-               Support diesen senden!
-       </div>
-</div>
-
-<div id="content_footer">
-       <div id="login_retry">
-               {?login_retry?}
-       </div>
-
-       Vielen Dank f&uuml;r deine Mitarbeit! :-)
-</div>
diff --git a/application/ship-simu/templates/de/code/login_form.ctp b/application/ship-simu/templates/de/code/login_form.ctp
deleted file mode 100644 (file)
index ae60048..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-<?php
-// Get helper instance for web forms. This will add the opening form-tag to
-// the helper's render cache which is simply a small variable in the class
-// BaseHelper.
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_user_login'));
-
-// Formular deaktiviert?
-if ($helperInstance->ifLoginIsEnabled()) {
-       // Formular ist aktiv
-       $helperInstance->addFormGroup('login', "Gebe hier deine Logindaten ein:");
-
-       // Welches Loginverfahren wurde konfiguriert?
-       if ($helperInstance->ifLoginWithUsername()) {
-               // Login mit Username
-               $helperInstance->addFormSubGroup('username', "Bitte mit deinem Nickname einloggen.");
-               $helperInstance->addFieldText('username', "Dein Nickname:");
-               $helperInstance->addInputTextField('username');
-       } elseif ($helperInstance->ifLoginWithEmail()) {
-               // Login mit Email
-               $helperInstance->addFormSubGroup('email', "Bitte mit deiner Email-Adresse einloggen.");
-               $helperInstance->addFieldText('email', "Deine Email-Addresse:");
-               $helperInstance->addInputTextField('email');
-       } else {
-               // Login mit Email/Username
-               $helperInstance->addFormSubGroup('user_email', "Bitte mit deinem Nickname oder Email-Adresse einloggen.");
-               $helperInstance->addFieldText('user_email', "Dein Nickname/Email:");
-               $helperInstance->addInputTextField('user_email');
-       }
-
-       $helperInstance->addFormSubGroup('pass', "Gebe dein Passwort von der Anmeldung ein.");
-       $helperInstance->addFieldText('pass', "Dein Passwort:");
-       $helperInstance->addInputPasswordField('pass');
-
-       // CAPTCHA enabled?
-       if ($helperInstance->ifFormSecuredWithCaptcha()) {
-               $helperInstance->addFormGroup('captcha_user', "Das Benutzer-Login ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du dich einloggen kannst.");
-               $helperInstance->addCaptcha();
-       } // END - if
-
-       // Submit buttons
-       $helperInstance->addFormGroup('buttons_user', "Alles richtig eingegeben?");
-       $helperInstance->addInputResetButton("Formular leeren");
-       $helperInstance->addInputSubmitButton("Zum Spiel einloggen");
-} else {
-       // Formular deaktiviert
-       $helperInstance->addFormNote('form_deactivated', "Einloggen in&#39;s Spiel ist derzeit administrativ deaktiviert worden. Bitte komme sp&auml;ter noch mal wieder.");
-       $helperInstance->addFormNote('admin_notice', "Nachricht vom Admin: <span id=\"disabled_reason\">".$this->getConfigInstance()->readConfig('login_disabled_reason')."</span>");
-}
-
-// Formular schliessen
-$helperInstance->flushContent();
-
-// Ist Gastlogin erlaubt?
-if ($helperInstance->ifGuestLoginAllowed()) {
-       // Neue Helper-Instanz holen
-       $helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_guest_login'));
-       $helperInstance->addInputHiddenConfiguredField('user', 'guest_login');
-       $helperInstance->addInputHiddenConfiguredField('passwd', 'guest_login');
-
-       // CAPTCHA enbaled?
-       if ($helperInstance->ifFormSecuredWithCaptcha()) {
-               $helperInstance->addFormGroup('captcha_guest', "Unser Gast-Login ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du dich einloggen kannst.");
-               $helperInstance->addCaptcha();
-       } // END - if
-
-       // Submit button
-       $helperInstance->addFormGroup('buttons_guest', "Gastlogins sind in der Funkionsweise eingeschr&auml;nkt. Mehr dazu unter &quot;Gastlogin&quot;.");
-       $helperInstance->addInputSubmitButton("Als Gast einloggen");
-       $helperInstance->flushContent();
-}
-
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'register'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('register_login');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Einloggen zu <span class="app_name">{?app_full_name?}</span>
-</div>
-
-<div id="content_body">
-       <div id="login_box">
-               {?shipsimu_user_login?}
-       </div>
-
-       <div id="guest_login">
-               {?shipsimu_guest_login?}
-       </div>
-</div>
-
-<div id="content_footer">
-       Noch kein Spieleaccount? {?register?}
-</div>
diff --git a/application/ship-simu/templates/de/code/login_main.ctp b/application/ship-simu/templates/de/code/login_main.ctp
deleted file mode 100644 (file)
index 56adbab..0000000
+++ /dev/null
@@ -1,107 +0,0 @@
-<?php
-///////////////////////////////
-// Assign personal user data //
-///////////////////////////////
-
-// Get a new instance for personal data
-$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'persona_data'));
-
-// Set the data source instance which must exist in registry
-$blockInstance->prefetchValueInstance('user', 'user_points');
-
-// Assign fields with template variables
-$blockInstance->assignField('username');
-$blockInstance->assignFieldWithFilter('user_status', 'user_status_translator');
-$blockInstance->assignFieldWithFilter('points', 'format_number');
-
-// Shall we include registration date?
-if ($blockInstance->ifIncludeRegistrationStamp()) {
-       // Then assign it as well!
-       $blockInstance->assignFieldWithFilter('registered', 'format_timestamp');
-} // END - if
-
-// Flush the content out to a template variable
-$blockInstance->flushContent();
-
-//////////////////////////////////////
-// Assign the shipping company data //
-//////////////////////////////////////
-
-// Get a new instance for personal data
-$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'company_data'));
-
-// Set the data source instance
-$blockInstance->prefetchValueInstance('company', 'user');
-
-// Assign the company name
-if ($blockInstance->getValueInstance()->ifUserIsFounder()) {
-       // User is the founder of the company
-       $blockInstance->assignMessageField('company_status', 'user_is_company_founder');
-       $blockInstance->assignLinkFieldWithAction('company' , 'company_overview');
-       $blockInstance->assignMessageField('company', 'link_text_company_overview');
-       $blockInstance->assignMessageField('company_title', 'link_title_company_overview');
-} elseif ($blockInstance->getValueInstance()->ifUserIsOwner()) {
-       // User owns the company
-       $blockInstance->assignMessageField('company_status', 'user_is_company_owner');
-       $blockInstance->assignLinkFieldWithAction('company' , 'company_overview');
-       $blockInstance->assignMessageField('company', 'link_text_company_overview');
-       $blockInstance->assignMessageField('company_title', 'link_title_company_overview');
-} elseif ($blockInstance->getValueInstance()->ifUserIsEmployee()) {
-       // User is employed in company
-       $blockInstance->assignMessageField('company_status', 'user_is_employed_in_company');
-       $blockInstance->assignLinkFieldWithAction('company' , 'employee_overview');
-       $blockInstance->assignMessageField('company', 'link_text_employee_overview');
-       $blockInstance->assignMessageField('company_title', 'link_title_employee_overview');
-} else {
-       // No company participation!
-       $blockInstance->assignMessageField('company_status', 'user_not_assigned_company');
-       $blockInstance->assignLinkFieldWithAction('company' , 'company');
-       $blockInstance->assignMessageField('company', 'link_text_company');
-       $blockInstance->assignMessageField('company_title', 'link_title_company');
-}
-
-// Flush the content out to a template variable
-$blockInstance->flushContent();
-
-// Get helper instance
-$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout'));
-
-// Add action
-$linkInstance->addActionLinkById('logout', 'logout');
-
-// Flush the content
-$linkInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Willkommen im Loginbereich von <span class="app_name">{?app_full_name?}</span>!
-</div>
-
-<div id="content_body">
-       {?login_content?}
-</div>
-
-<div id="persona_data" title="Informationen zu Deinem Spieleaccount">
-       <div id="persona_header">
-               Account-Infos:
-       </div>
-
-       <div id="persona_body">
-               {?persona_data?}
-       </div>
-
-       <div id="logout">
-               {?logout?}
-       </div>
-</div>
-
-<div id="company_data" title="Informationen zu der aktuell ausgew&auml;hlten Reederei">
-       <div id="company_header">
-               Reederei-Infos:
-       </div>
-
-       <div id="company_body">
-               {?company_data?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/logout_done.ctp b/application/ship-simu/templates/de/code/logout_done.ctp
deleted file mode 100644 (file)
index 9843f50..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-// Get helper instance
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'relogin'));
-
-// Set link text
-$helperInstance->addLinkWithTextById('relogin');
-
-// Flush the content
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Du bist jetzt aus dem Spiel ausgeloggt!
-</div>
-
-<div id="content_body">
-       Du kannst dich nun {?relogin?} oder weiter auf unseren Seiten bleiben. ;-)
-</div>
diff --git a/application/ship-simu/templates/de/code/mail_debug.ctp b/application/ship-simu/templates/de/code/mail_debug.ctp
deleted file mode 100644 (file)
index e62dd07..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<div class="debug_header">
-       Mail-Debug-Ausgabe:
-</div>
-
-<div class="mail_header">
-       <div class="mail_header_line">
-               <span class="mail_sender">Von:</span> <span class="mail_info">{?sender?}</span>
-       </div>
-       <div class="mail_header_line">
-               <span class="mail_recipient">An:</span> <span class="mail_info">{?recipient?}</span>
-       </div>
-       <div class="mail_header_line">
-               <span class="mail_subject">Betreff:</span> <span class="mail_info">{?subject?}</span>
-       </div>
-</div>
-
-<div class="mail_text_box">
-       <div class="mail_message">
-               Nachricht:
-       </div>
-
-       <div class="mail_content">
-               {?message?}
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/code/register_form.ctp b/application/ship-simu/templates/de/code/register_form.ctp
deleted file mode 100644 (file)
index 90dca57..0000000
+++ /dev/null
@@ -1,134 +0,0 @@
-<?php
-// Get helper instance for web forms. This will add the opening form-tag to
-// the helper's render cache which is simply a small variable in the class
-// BaseHelper.
-$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_register'));
-
-// Always ask at least for nickname and password
-$helperInstance->addFormGroup('login', "Bitte gebe hier gew&uuml;nschten Nickname und dein Zugangspasswort ein.");
-$helperInstance->addFormSubGroup('username', "Dein Nickname wird erst nach Absenden des Formulares gepr&uuml;ft. Sp&auml;ter bauen wir dann einen automatischen Test ein, der dir sofort zeigt, ob der Nickname bereits vergeben ist.");
-$helperInstance->addFieldText('username', "Nickname im Spiel:");
-$helperInstance->addInputTextField('username');
-$helperInstance->addFormSubGroup('pass', "Dein Passwort sollte nicht zu leicht erratbar sein. Sp&auml;ter bauen wir hier noch einen automatischen Test ein, der dir sofort die Passwortst&auml;rke anzeigt.");
-$helperInstance->addFieldText('pass1', "Passwort:");
-$helperInstance->addInputPasswordField('pass1');
-$helperInstance->addFieldText('pass2', "Passwortwiederholung:");
-$helperInstance->addInputPasswordField('pass2');
-
-// Does this registration require an email?
-if ($helperInstance->ifRegisterRequiresEmailVerification()) {
-       $helperInstance->addFormGroup('email', "Bitte gebe deine Email zweimal (ein zweites Mal zur Best&auml;tigung) ein, damit wir dir deinen Freischaltlink zusenden k&ouml;nnen.");
-       $helperInstance->addFieldText('email1', "Email-Adresse:");
-       $helperInstance->addInputTextField('email1');
-       $helperInstance->addFieldText('email2', "Wiederholung Email-Adresse:");
-       $helperInstance->addInputTextField('email2');
-
-       // Must the email address be unique in this system?
-       if ($helperInstance->ifEmailMustBeUnique()) {
-               $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
-       } // END - if
-} // END - if
-
-// Shall we also ask some personal data to complete the profile?
-if ($helperInstance->ifRegisterIncludesProfile()) {
-       $helperInstance->addFormGroup('profile', "Hier kannst du zus&auml;tzlich deine Profildaten vorweg eingeben, du kannst sie aber auch nach dem Login vervollst&auml;ndigen!");
-
-       if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
-               $helperInstance->addFormSubGroup('email', "Die Angabe deiner Email-Adresse ist nur dann n&ouml;tig, wenn du auch Email-Benachrichtigungen (<span id=\"add_note\">*1</span>) haben m&ouml;chtest.");
-               $helperInstance->addFieldText('email1', "Email-Adresse:");
-               $helperInstance->addInputTextField('email1');
-
-               // Must the email address be unique in this system?
-               if ($helperInstance->ifEmailMustBeUnique()) {
-                       $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
-               } // END - if
-       } // END - if
-
-       // Persoenliche Daten mit in der Anmeldung abfragen?
-       if ($helperInstance->ifRegisterIncludesPersonaData()) {
-               $helperInstance->addFormSubGroup('persona', "Wenn du magst, dann vervollst&auml;ndige deine komplette Adresse mit deinem Namen.");
-               $helperInstance->addFieldText('surname', "Dein Vorname:");
-               $helperInstance->addInputTextField('surname');
-               $helperInstance->addFieldText('family', "Dein Nachname:");
-               $helperInstance->addInputTextField('family');
-               $helperInstance->addFieldText('street', "Strasse und Hausnummer:");
-               $helperInstance->addInputTextField('street');
-               $helperInstance->addFieldText('city', "Wohnort:");
-               $helperInstance->addInputTextField('city');
-
-               // Include birthday?
-               if ($helperInstance->ifProfileIncludesBirthDay()) {
-                       $helperInstance->addFormSubGroup('birthday', "Verrate uns doch dein Geburtsdatum, als Dankesch&ouml;n erh&auml;lst du interessante Pr&auml;mien - ausschliesslich per Email - zum Geburtstag zugesandt! G&uuml;ltiges Format: TT.MM.JJJJ");
-                       $helperInstance->addInputTextField('birth_day');
-                       $helperInstance->addFieldText('birth_day', ".");
-                       $helperInstance->addInputTextField('birth_month');
-                       $helperInstance->addFieldText('birth_day', ".");
-                       $helperInstance->addInputTextField('birth_year');
-               } // END - if
-       } // END - if
-
-       $helperInstance->addFormSubGroup('zip', "Magst du uns auch deine Postleitzahl verraten?");
-       $helperInstance->addFieldText('zip', "Postleitzahl:");
-       $helperInstance->addInputTextField('zip');
-
-       $helperInstance->addFormSubGroup('chat', "Gebe hier deine Nicknames bzw. Nummern an:");
-
-       if ($helperInstance->ifChatEnabled('icq')) {
-               $helperInstance->addFieldText('icq', "ICQ-Nummer:");
-               $helperInstance->addInputTextField('icq');
-       } // END - if
-
-       if ($helperInstance->ifChatEnabled('jabber')) {
-               $helperInstance->addFieldText('jabber', "Jabber:");
-               $helperInstance->addInputTextField('jabber');
-       } // END - if
-
-       if ($helperInstance->ifChatEnabled('yahoo')) {
-               $helperInstance->addFieldText('yahoo', "Yahoo!:");
-               $helperInstance->addInputTextField('yahoo');
-       } // END - if
-
-       if ($helperInstance->ifChatEnabled('aol')) {
-               $helperInstance->addFieldText('aol', "AOL-Screenname:");
-               $helperInstance->addInputTextField('aol');
-       } // END - if
-
-       if ($helperInstance->ifChatEnabled('msn')) {
-               $helperInstance->addFieldText('msn', "MSN:");
-               $helperInstance->addInputTextField('msn');
-       } // END - if
-
-       if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
-               $helperInstance->addFormExtraNote(1, "Die Benachrichtigungen per sind im Loginbereich verfeinerbar, welche du genau haben willst.");
-       } // END - Extra note
-
-} // END - ask profile data
-
-// Spielregeln abfragen
-$helperInstance->addFormGroup('rules', "Bitte lese dir die Spieleregeln gut durch und kreuze dann &quot;Ja, ich akzeptiere die aktuellen Spielregeln&quot; an.");
-$helperInstance->addFieldText('rules', "Ja, ich akzeptiere die aktuellen Spielregeln:");
-$helperInstance->addInputCheckboxField('rules', false);
-
-// Add CAPTCHA?
-if ($helperInstance->ifFormSecuredWithCaptcha()) {
-       $helperInstance->addFormGroup('captcha', "Bitte wiederhole den angezeigten Code damit die Anmeldung abgeschlossen werden kann.");
-       $helperInstance->addCaptcha();
-} // END - if
-
-// Final note and submit buttons
-$helperInstance->addFormGroup('buttons', "Wenn du alle ben&ouml;tigten Felder korrekt ausgef&uuml;t hast, kannst du die Anmeldung abschliessen.");
-
-$helperInstance->addInputResetButton("Alles nochmal eingeben");
-$helperInstance->addInputSubmitButton("Anmeldung zum Spiel abschliessen");
-$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
-$helperInstance->flushContent();
-
-// [EOC]
-?>
-<div id="content_header">
-       Anmeldung bei <span class="app_name">{?app_full_name?}</span>
-</div>
-
-<div id="register_box">
-       {?shipsimu_register?}
-</div>
diff --git a/application/ship-simu/templates/de/code/shipsimu_main.ctp b/application/ship-simu/templates/de/code/shipsimu_main.ctp
deleted file mode 100644 (file)
index 3dd1296..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-{?header?}
-
-<div id="main_header">
-       {?shipsimu_header?}
-</div>
-
-<div id="menu">
-       {?menu?}
-</div>
-
-<div id="advert">
-       {?nav_advert?}
-</div>
-
-<div id="language">
-       {?language_selector?}
-</div>
-
-<div id="main_content">
-       {?content?}
-</div>
-
-<div id="main_footer">
-       {?shipsimu_footer?}
-</div>
-
-{?footer?}
diff --git a/application/ship-simu/templates/de/code/status.ctp b/application/ship-simu/templates/de/code/status.ctp
deleted file mode 100644 (file)
index 730a240..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<div id="content_header">
-       Es besteht ein Problem mit Ihrem Account
-</div>
-
-<div id="news_frame">
-       {?status_problem?}
-</div>
diff --git a/application/ship-simu/templates/de/emails/.htaccess b/application/ship-simu/templates/de/emails/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/de/emails/text_resend_link.tpl b/application/ship-simu/templates/de/emails/text_resend_link.tpl
deleted file mode 100644 (file)
index ab28bab..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<text-mail>
-       <mail-data>
-               <sender-address value="$config[admin_email]" />
-               <subject-line value="Anforderung deines Best&auml;tigungslinks" />
-               <recipient-address value="{?email?}" />
-               <message>
-               <![CDATA[Hallo {?username?}!
-
-Du (oder ein anderer) hattest soeben deinen Best&auml;tigungslink erneut angefordert. Solltest du dies nicht gewesen sein, bitten wir dich den Vorfall zu entschuldigen.
-
-Hier ist nun dein Best&auml;tigungslink. Der alte aus der Anmeldemail ist somit nicht mehr g&uuml;ltig!
-
-$config[base_url]/index.php?app={?app_short_name?}&page=confirm&username={?username?}&confirm={?confirm_hash?}
-
-Solltest du die URL nicht anklicken k&ouml;nnen, versuche diese in die Adresszeile deines Browsers zu kopieren.
-
-Alternativ kannst du im Spielebereich unter Best&auml;tigungscode den folgenden Code reinkopieren oder eingeben:
-
-{?confirm_hash?}
-
-Solltest du Fragen dazu oder Probleme mit der Best&auml;tigung haben, so melde dich bitte beim Support-Team.
-
-Mit freundlichen Gr&uuml;&szlig;en,
-  Dein {?app_short_name?}-Team
-
-{?mail_footer?}]]>
-               </message>
-       </mail-data>
-</text-mail>
diff --git a/application/ship-simu/templates/de/html/.htaccess b/application/ship-simu/templates/de/html/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/de/html/nav_advert.tpl b/application/ship-simu/templates/de/html/nav_advert.tpl
deleted file mode 100644 (file)
index 22da43b..0000000
+++ /dev/null
@@ -1 +0,0 @@
-<!-- Put your ads code here which shall be shown below the navigation //-->
diff --git a/application/ship-simu/templates/de/html/selector_ship-simu.tpl b/application/ship-simu/templates/de/html/selector_ship-simu.tpl
deleted file mode 100644 (file)
index b96640e..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<div id="selector_content">
-       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
-               Gr&uuml;nden Sie eine virtuelle Reederei an den bedeutestens
-               Welth&auml;fen! Oder treten Sie einer Reederei als Angestellter bei und
-               arbeiten Sie sich bis in die Chef-Etagge hoch!
-       </div>
-
-       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
-               Oder fangen Sie als Matrose auf einem Passagierschiff (virtuell) an zu
-               arbeiten und werden Sie nach wenigen Kreuzfahrten bald Kapit&auml;n!
-       </div>
-
-       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
-               Oder buchen Sie eine virtuelle Kreuzfahrt durch die bekannten Meeren in
-               {!POINTS!} in einer Luxus-Suite!
-       </div>
-</div>
diff --git a/application/ship-simu/templates/de/image/base_code.xml b/application/ship-simu/templates/de/image/base_code.xml
deleted file mode 100644 (file)
index 5de71be..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<image>
-       <type value="{?image_type?}" />
-       <base>
-               <name value="{?image_name?}" />
-       </base>
-       <resolution>
-               <width value="{?image_width?}" />
-               <height value="{?image_height?}" />
-       </resolution>
-       <background-color>
-               <red value="{?image_bg_red?}" />
-               <green value="{?image_bg_green?}" />
-               <blue value="{?image_bg_blue?}" />
-       </background-color>
-       <foreground-color>
-               <red value="{?image_fg_red?}" />
-               <green value="{?image_fg_green?}" />
-               <blue value="{?image_fg_blue?}" />
-       </foreground-color>
-       <image-string value="groupable">
-               <string-name value="{?image_string_name?}" />
-               <x value="{?image_x?}" />
-               <y value="{?image_y?}" />
-               <font-size value="{?image_size?}" />
-               <text value="{?image_string?}" />
-       </image-string>
-</image>
diff --git a/application/ship-simu/templates/de/image/code_captcha.img b/application/ship-simu/templates/de/image/code_captcha.img
deleted file mode 100644 (file)
index 223e4fb..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-<?php
-// Needed in every image template to initialy set the image type
-$helper = ImageHelper::createImageHelper($this, 'png');
-$helper->setImageName('code_captcha');
-$helper->setBaseImage('base_code');
-
-// Set image dimensions
-$helper->setWidth(100);
-$helper->setHeight(50);
-
-// Get random number
-$rand = $helper->getRngInstance()->randomNumber(0, 6);
-
-// Background and foreground color
-switch ($rand) {
-       case 1:
-               // First varriant
-               $helper->setBackgroundColorRedGreenBlue('rand', 0x90  , 0x00  );
-               $helper->setForegroundColorRedGreenBlue(0x00  , 0xff  , 'rand');
-               break;
-
-       case 2:
-               // Second varriant
-               $helper->setBackgroundColorRedGreenBlue(0x90  , 'rand', 0x00  );
-               $helper->setForegroundColorRedGreenBlue(0xff  , 0x00  , 'rand');
-               break;
-
-       case 3:
-               // Third varriant
-               $helper->setBackgroundColorRedGreenBlue('rand', 0x00  , 0x90  );
-               $helper->setForegroundColorRedGreenBlue(0x00  , 'rand', 0xff  );
-               break;
-
-       case 4:
-               // Forth varriant
-               $helper->setBackgroundColorRedGreenBlue(0x00  , 0x90  , 'rand');
-               $helper->setForegroundColorRedGreenBlue(0x00  , 'rand', 0xa0  );
-               break;
-
-       case 5:
-               // Fith varriant
-               $helper->setBackgroundColorRedGreenBlue('rand', 0x00  , 0x90  );
-               $helper->setForegroundColorRedGreenBlue(0x00  , 0xe0  , 'rand');
-               break;
-
-       default:
-               // Last varriant
-               $helper->setBackgroundColorRedGreenBlue(0x00  , 'rand', 0x90  );
-               $helper->setForegroundColorRedGreenBlue(0xff  , 0x00  , 'rand');
-               break;
-}
-
-// Random X/Y factors...
-$xRand = $helper->getRngInstance()->randomNumber(0, 45);
-$yRand = $helper->getRngInstance()->randomNumber(0, 25);
-
-// Add code
-$helper->addTextLine('code');
-$helper->setCoord((5 + $xRand), (5 + $yRand));
-$helper->setFontSize('rand');
-$helper->setImageString('{?decrypted_code?}');
-
-// Only for debug!
-/*
-$helper->addTextLine('debug');
-$helper->setCoord(90, 35);
-$helper->setFontSize(3);
-$helper->setImageString($rand);
-*/
-
-// Flush content to the template engine
-$helper->flushContent();
-
-// Comment this out if image is done
-//$this->debugInstance();
-
-// [EOF]
-?>
diff --git a/application/ship-simu/templates/de/image/emergency_exit.img b/application/ship-simu/templates/de/image/emergency_exit.img
deleted file mode 100644 (file)
index bf67aa7..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-<?php
-// Needed in every image template to initialy set the image type
-$helper = ImageHelper::createImageHelper($this, 'png');
-$helper->setImageName('emergency_exit');
-$helper->setBaseImage('base_exit');
-
-// Set image dimensions
-$helper->setWidth(100);
-$helper->setHeight(50);
-
-// Flush content to the template engine
-//$helper->flushContent();
-
-// Comment this out if image is done
-$this->debugInstance();
-
-// [EOF]
-?>
diff --git a/application/ship-simu/templates/de/menu/.htaccess b/application/ship-simu/templates/de/menu/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/de/menu/base_menu.xml b/application/ship-simu/templates/de/menu/base_menu.xml
deleted file mode 100644 (file)
index 1c93350..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general menu XML file. We should later on convert this into a DTD.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<menu>
-       <block-list block-count="{?block_count?}">
-               <block>
-                       <block-header>
-                               <title>
-                                       <title-id>{?menu_title_id?}</title-id>
-                                       <title-class>{!menu_title_class?}</title-class>
-                                       <title-text>{?menu_title?}</title-text>
-                               </title>
-                       </block-header>
-                       <entry-list entry-count="{?entry_count?}">
-                               <entry>
-                                       <entry-id>{?entry_id?}</entry-id>
-                                       <anchor>
-                                               <anchor-id>{?anchor_id?}</anchor-id>
-                                               <anchor-text>{?anchor_text?}</anchor-text>
-                                               <anchor-title>{?anchor_title?}</anchor-title>
-                                               <anchor-href>{?anchor_href?}</anchor-href>
-                                       </anchor>
-                               </entry>
-                       </entry-list>
-                       <block-footer>
-                               <footer-id>{!footer_id?}</footer>
-                               <footer-class>{?footer_design_class?}</footer-class>
-                               <footer-text>{?menu_footer?}</footer-text>
-                       </block-footer>
-               </block>
-       </block-list>
-</menu>
diff --git a/application/ship-simu/templates/de/menu/generic_menu_entries.xml b/application/ship-simu/templates/de/menu/generic_menu_entries.xml
deleted file mode 100644 (file)
index 65c742e..0000000
+++ /dev/null
@@ -1,113 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-Generic menu entries. You should leave this template for smooth upgrades.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<menu>
-       <block-list block-count="{?block_count?}">
-               <block>
-                       <block-header>
-                               <title>
-                                       <title-id><![CDATA[home_menu_title]]></title-id>
-                                       <title-class><![CDATA[menu_title]]></title-class>
-                                       <title-text><![CDATA[Home:]]></title-text>
-                               </title>
-                       </block-header>
-                       <entry-list entry-count="{?entry_count?}">
-                               <entry>
-                                       <entry-id><![CDATA[home_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_home]]></anchor-id>
-                                               <anchor-text><![CDATA[Home]]></anchor-text>
-                                               <anchor-title><![CDATA[Zur Startseite]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                               <entry>
-                                       <entry-id><![CDATA[login_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_login]]></anchor-id>
-                                               <anchor-text><![CDATA[Einloggen]]></anchor-text>
-                                               <anchor-title><![CDATA[Zum Spiel {?app_name?} einloggen]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=login]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                               <entry>
-                                       <entry-id><![CDATA[register_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_register]]></anchor-id>
-                                               <anchor-text><![CDATA[Anmeldung]]></anchor-text>
-                                               <anchor-title><![CDATA[Zur Anmeldeseite]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=register]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                               <entry>
-                                       <entry-id><![CDATA[pillory_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_pillory]]></anchor-id>
-                                               <anchor-text><![CDATA[Pranger]]></anchor-text>
-                                               <anchor-title><![CDATA[Zum Pranger]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=pillory]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                       </entry-list>
-                       <block-footer>
-                               <footer-id><![CDATA[home_menu_footer]]></footer-id>
-                               <footer-class><![CDATA[menu_footer]]></footer-class>
-                               <footer-text><![CDATA[Leer]]></footer-text>
-                       </block-footer>
-               </block>
-               <block>
-                       <block-header>
-                               <title>
-                                       <title-id><![CDATA[law_menu_title]]></title-id>
-                                       <title-class><![CDATA[menu_title]]></title-class>
-                                       <title-text><![CDATA[Rechtliches:]]></title-text>
-                               </title>
-                       </block-header>
-                       <entry-list entry-count="{?entry_count?}">
-                               <entry>
-                                       <entry-id><![CDATA[imprint_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_imprint]]></anchor-id>
-                                               <anchor-text><![CDATA[Impressum]]></anchor-text>
-                                               <anchor-title><![CDATA[Impressum]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=imprint]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                               <entry>
-                                       <entry-id><![CDATA[terms_entry]]></entry-id>
-                                       <anchor>
-                                               <anchor-id><![CDATA[menu_terms]]></anchor-id>
-                                               <anchor-text><![CDATA[ANBs]]></anchor-text>
-                                               <anchor-title><![CDATA[Allgemeine Nutzungsbedingungen]]></anchor-title>
-                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=terms]]></anchor-href>
-                                       </anchor>
-                               </entry>
-                       </entry-list>
-                       <block-footer>
-                               <footer-id><![CDATA[law_menu_footer]]></footer-id>
-                               <footer-class><![CDATA[menu_footer]]></footer-class>
-                               <footer-text><![CDATA[Leer]]></footer-text>
-                       </block-footer>
-               </block>
-       </block-list>
-</menu>
diff --git a/application/ship-simu/templates/game/!MISSING b/application/ship-simu/templates/game/!MISSING
deleted file mode 100644 (file)
index 57cf1de..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-<construction-company extends="{?construction_template?}" />
-<construction-contract extends="{?contract_template?}" />
diff --git a/application/ship-simu/templates/game/.htaccess b/application/ship-simu/templates/game/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/building/.htaccess b/application/ship-simu/templates/game/building/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/building/advanced_research_lab.xml b/application/ship-simu/templates/game/building/advanced_research_lab.xml
deleted file mode 100644 (file)
index 48d3e5e..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-An advanced research laboratory for conducting simple experiments.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<building extends="base_building">
-       <!-- General building data //-->
-       <building-data>
-               <!-- General data, like short name, type, level and many more. //-->
-               <building-data>
-                       <name>advanced_research_lab</name>
-                       <type>research</type>
-               </building-data>
-       </building-data>
-       <!-- We also have technology denpencies for a building. These must be
-            understand by construction companies who made contracts with the
-            shipping company to construct this building. //-->
-       <dependencies>
-               <!-- A list of required technology to construct this building. //-->
-               <!-- @TODO Find technology types //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- Arcgictecture is required. //-->
-                       <technology-dependency>
-                               <technology-name>architecture</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>10</technology-level>
-                       </technology-dependency>
-                       <!-- Labory equipment is required. //-->
-                       <technology-dependency research-dependency-count="{?research_dependency_count?}">
-                               <technology-name>laboratory_equipment</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>8</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</building>
diff --git a/application/ship-simu/templates/game/building/base_building.xml b/application/ship-simu/templates/game/building/base_building.xml
deleted file mode 100644 (file)
index 0949690..0000000
+++ /dev/null
@@ -1,169 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general building template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<building>
-       <!-- General building data //-->
-       <building-data>
-               <!-- Estimated dimensions of the building. //-->
-               <estimated-dimensions>
-                       <!-- Width of the building. //-->
-                       <width>{?width?}</width>
-                       <!-- Height of the building. //-->
-                       <height>{?height?}</height>
-                       <!-- Length of the building. //-->
-                       <length>{?length?}</length>
-               </estimated-dimensions>
-               <!--A summary for this building. //-->
-               <summary>
-                       <![CDATA[{?summary?}]]>
-               </summary>
-               <!-- A full description of this building. //-->
-               <description>
-                       <![CDATA[{?description?}]]>
-               </description>
-               <!-- General data, like short name, type, level and many more. //-->
-               <building-data>
-                       <id>{?id?}</id>
-                       <name>{?name?}</name>
-                       <type>{?type?}</type>
-                       <level>{?level?}</level>
-                       <max-floors>{?max_floors?}</max-floors>
-                       <!-- The owner of this building. //-->
-                       <owner id="{?owner_id?}" type="{?owner_type?}" owned-start="{?owner_start_timestamp?}" owned-end="{?owner_end_timestamp?}" />
-                       <!-- The occupant of this building. //-->
-                       <occupant id="{?occupant_id?}" type="{?occupant_type?}" owned-start="{?occupant_start_timestamp?}" owned-end="{?occupant_end_timestamp?}" />
-                       <!-- When this building was constructed. //-->
-                       <constructed>
-                               <!-- When construction has started. //-->
-                               <construction-started timestamp="{?construction_start_timestamp?}" />
-                               <!-- And when it was finished. //-->
-                               <construction-finished timestamp="{?construction_end_timestamp?}" />
-                       </constructed>
-                       <!-- When this building was destructed. //-->
-                       <destructed>
-                               <!-- When destruction has started. //-->
-                               <destruction-started timestamp="{?destruction_start_timestamp?}" />
-                               <!-- And when it was finished. //-->
-                               <destruction-finished timestamp="{?destruction_end_timestamp?}" />
-                               <!-- A short reason why this building must be destructed or
-                                    demolished. //-->
-                               <destruction-reason>
-                                       <![CDATA[{?destruction_reason?}]]>
-                               </destruction-reason>
-                       </deconstructed>
-               </building-data>
-       </building-data>
-       <!-- All sorts of costs for a building. //-->
-       <costs>
-               <!-- The land-price has to be payed to the simplified government. //-->
-               <land-price currency="{?land_currency?}" />
-               <!-- Construction costs may be empty when this building is bougth from
-                    an other user e.g. a broker //-->
-               <construction-costs>
-                       <currency>{?construction_currency?}</currency>
-                       <construction-company extends="{?construction_template?}">
-                               <!-- The construction company. //-->
-                               <company>
-                                       <company-id>{?construct_id?}</company-id>
-                                       <!-- A construction of a building requires personel. We
-                                            summary their salery here for simplicy. //-->
-                                       <personel-costs currency="{?personel_currency?}" />
-                                       <!-- A lot resources like steel and concrete are required
-                                            for new high buildings. Some older or futuristic may
-                                            require different resources. //-->
-                                       <resource-list extends="{?resources_template?}">
-                                               <!-- A single resource and its amount to construct this
-                                                    building. //-->
-                                               <resource>
-                                                       <resource-id>{?resource_id?}</resource-id>
-                                                       <amount>{?resource_amount?}</amount>
-                                                       <!-- The merchant dealing with this resource. //-->
-                                                       <resource-merchant extends="{?merchant_template?}">
-                                                               <merchant id="{?merchant_id?}" />
-                                                       </resource-merchant>
-                                               </resource>
-                                       </resource-list>
-                               </company>
-                               <!-- The construction contract for constructing this building. //-->
-                               <construction-contract extends="{?contract_template?}">
-                                       <construction-contract id="{?construct_contract_id?}" />
-                               </construction-contract>
-                       </construction-company>
-               </construction-costs>
-               <!-- Running costs are all costs that the owner/occupant has to pay for upkeeping
-                    it like house cleaning. simplified repair costs and in some way
-                    taxes. //-->
-               <running-costs>
-                       <!-- Taxes for the occupied lot. //-->
-                       <taxes currency="{?taxes_currency?}" />
-                       <!-- A building has mostly maintenance costs. //-->
-                       <maintenance>
-                               <!-- Almost all buildings needs to be cleaned. //-->
-                               <cleaning-costs>
-                                       <currency>{?cleaning_currency?}</currency>
-                                       <!-- The cleaning company. //-->
-                                       <cleaning-company id="{?cleaning_id?}" />
-                                       <!-- The contract for cleaning this building. //-->
-                                       <cleaning-contract contract_id="{?cleaning_contract_id?}" />
-                               </cleaning-costs>
-                               <repair-costs>
-                                       <currency>{?repair_currency?}</currency>
-                                       <repair contract_id="{?repair_contract_id?}" />
-                               </repair-costs>
-                       </maintenance>
-               </running-costs>
-               <!-- For constructing a building you sometimes need to take mortgage to
-                    fund the construction costs. //-->
-               <mortgage>
-                       <currency>{?mortgage_currency?}</currency>
-                       <!-- The bank paying the mortage, if not provided, the following
-                            mortage broker must be provided. //-->
-                       <bank id="{?bank_id?}" />
-                       <!-- A mortage broker who has payed the mortage. //-->
-                       <mortgage-broker id="{?broker_id?}" />
-                       <!-- The contract behind the mortage. //-->
-                       <contract id="{?mortage_id?}" />
-               </mortgage>
-       </costs>
-       <!-- We also have technology denpencies for a building. These must be
-            understand by construction companies who made contracts with the
-            shipping company to construct this building. //-->
-       <dependencies>
-               <!-- A list of required technology to construct this building. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A single required technology to construct this building. //-->
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-       <!-- A list of floors this building has. //-->
-       <floor-list floor-count="{?floor_count?}">
-               <!-- A single floor where we can add rooms to. //-->
-               <floor>
-               </floor>
-       </floor-list>
-</building>
diff --git a/application/ship-simu/templates/game/building/research_lab.xml b/application/ship-simu/templates/game/building/research_lab.xml
deleted file mode 100644 (file)
index 091ad0a..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general research laboratory for conducting simple experiments.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<building extends="base_building">
-       <!-- General building data //-->
-       <building-data>
-               <!-- General data, like short name, type, level and many more. //-->
-               <building-data>
-                       <name>research_lab</name>
-                       <type>research</type>
-               </building-data>
-       </building-data>
-       <!-- We also have technology denpencies for a building. These must be
-            understand by construction companies who made contracts with the
-            shipping company to construct this building. //-->
-       <dependencies>
-               <!-- A list of required technology to construct this building. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- Arcgictecture is required. //-->
-                       <technology-dependency>
-                               <technology-name>architecture</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-                       <!-- Labory equipment is required. //-->
-                       <technology-dependency>
-                               <technology-name>laboratory_equipment</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</building>
diff --git a/application/ship-simu/templates/game/chemicals/.htaccess b/application/ship-simu/templates/game/chemicals/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/company/.htaccess b/application/ship-simu/templates/game/company/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/container/.htaccess b/application/ship-simu/templates/game/container/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/container/base_container.xml b/application/ship-simu/templates/game/container/base_container.xml
deleted file mode 100644 (file)
index be79f56..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general container template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<container>
-       <!-- Some general data about this container. //-->
-       <container-data>
-               <!-- Id and type of this container. //-->
-               <id>{?id?}</id>
-               <!-- Uni* name, mostly adapted from template name, for this container. //-->
-               <name>{?name?}</name>
-               <!-- Look at container_types.xml for details. //-->
-               <type>{?type?}</type>
-               <!-- Dimension of the container. //-->
-               <dimensions>
-                       <width>{?width?}</width>
-                       <length>{?length?}</length>
-                       <height>{?height?}</height>
-               </dimensions>
-       </container-data>
-       <!-- The owner of the container, this should be a company, //-->
-       <owner>
-               <company id="{?owner_id?}" />
-       </owner>
-       <!-- The sender of the container, this should be a company and must not be
-            the owner. //-->
-       <sender>
-               <company id="{?sender_id?}" />
-       </sender>
-       <!-- The recipient of the container, this should be a company and can be the
-            owner. //-->
-       <recipient>
-               <company id="{?recipient_id?}" />
-       </recipient>
-       <!-- The transported content inside of the container. This can be more than one item. //-->
-       <content-list content-count="{?content_count?}">
-               <!-- A single content of the container which should be transportated. //-->
-               <content>
-                       <content-id>{?content_id?}</content-id>
-                       <content-type>{?content_type?}</content-type>
-                       <content-amount>{?content_amount?}</content-amount>
-               </content>
-       </content-list>
-       <!-- A system, freezer or colder or something else, which maintains a
-            constant temperature. This is useful for biological content like
-            fruits. But it is optional. You can currently specify multiple systems,
-            e.g. ventilation and maybe cooling aggregate or so. //-->
-       <maintenance-system-list maintenance-system-count="{?maintenance_system_count?}">
-               <!-- A single maintenance system. //-->
-               <maintenance-system>
-                       <maintenance-id>{?maintenance_id?}</maintenance-id>
-                       <maintenance-name>{?maintenance_name?}</maintenance-name>
-                       <maintenance-type>{?maintenance_type?}</maintenance-type>
-               </maintenance-system>
-       </maintenance-system-list>
-</container>
diff --git a/application/ship-simu/templates/game/contract/.htaccess b/application/ship-simu/templates/game/contract/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/contract/base_contract.xml b/application/ship-simu/templates/game/contract/base_contract.xml
deleted file mode 100644 (file)
index bb59563..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general contract
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<contract>
-       <!-- Parties of a contract are listed here. At least two, of course. //-->
-       <contract-party-list party-count="{?coutract_party_count?}">
-               <!-- All contract parties are enlisted with this tag. //-->
-               <contract-party>
-                       <!-- The signer's data, for signer_type please refer to signer_types.xml //-->
-                       <signer id="{?signer_id?}" type="{?signer_type?}" />
-               </contract-party>
-       </contract-party-list>
-       <!-- General contract data like data of signature or cancelation //-->
-       <contract-data id="{?id?}" type="{?type?}">
-               <!-- When this contract was signed. //-->
-               <signed timestamp="{?signed_timestamp?}" />
-               <!-- And when it was canceled. //-->
-               <canceled timestamp="{?canceled_timestamp?}" />
-               <!-- A short reason for cancelation. //-->
-               <cancelation-reason>
-                       <![CDATA[{?cancelation_reason?}]]>
-               </cancelation-reason>
-               <!-- A free-text description. //-->
-               <description>
-                       <![CDATA[{?description?}]]>
-               </description>
-       </contract-data>
-       <!-- The subject-(matter) of a contract. If this changes, the contract
-            needs to be renewed. //-->
-       <contract-subject>
-               <!-- @TODO We need to make this more XML than free text. //-->
-               <![CDATA[{?subject?}]]>
-       </contract-subject>
-</contract>
diff --git a/application/ship-simu/templates/game/drink/.htaccess b/application/ship-simu/templates/game/drink/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/drink/base_drink.xml b/application/ship-simu/templates/game/drink/base_drink.xml
deleted file mode 100644 (file)
index 6ac3a06..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general drink template for juice, mineral water, milk et cetera.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<drink>
-</drink>
diff --git a/application/ship-simu/templates/game/electronic/.htaccess b/application/ship-simu/templates/game/electronic/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/electronic/base_electronic.xml b/application/ship-simu/templates/game/electronic/base_electronic.xml
deleted file mode 100644 (file)
index 06945a5..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general electronic template. These electronics can be transported by different
-types of transportation companies. Is can be anything from cellphones over other
-communication electronics to commercial computers (default) or medical devices.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic>
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <!-- Id and type for this electronic. //-->
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>{?width?}</width>
-                       <height>{?height?}</height>
-                       <length>{?length?}</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- A list research dependencies for this electronical device. //-->
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <research-dependency>
-                               <research-id>{?research_id?}</research-id>
-                               <research-name>{?research_name?}</research-name>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/electronic/cellphone.xml b/application/ship-simu/templates/game/electronic/cellphone.xml
deleted file mode 100644 (file)
index 2c7f2d8..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A common cellular phone.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic extends="base_electronic}">
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <!-- Id and type for this electronic. //-->
-               <name>cellphone</name>
-               <type>communication</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>30</width>
-                       <height>35</height>
-                       <length>30</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <name>cellular_network</name>
-                               <level>1</level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- A list research dependencies for this electronical device. //-->
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <research-dependency>
-                               <name>electronics</name>
-                               <level>6</level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/electronic/hifi_system.xml b/application/ship-simu/templates/game/electronic/hifi_system.xml
deleted file mode 100644 (file)
index 76a1a8e..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A commercial, compact Hi-Fi (High Fidelity) sound system.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic extends="{?base_electronic?}">
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <name>hifi_system</name>
-               <type>entertainment</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>70</width>
-                       <height>70</height>
-                       <length>80</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <technology-dependency>
-                               <name>intergrated_currents</name>
-                               <level>6</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>sound_equalizer</name>
-                               <level>3</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>radio_receiving</name>
-                               <level>4</level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- A list research dependencies for this electronical device. //-->
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <!-- A single research dependency. //-->
-                       <research-dependency>
-                               <name>electronics</name>
-                               <level>4</level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/electronic/radio_receiver.xml b/application/ship-simu/templates/game/electronic/radio_receiver.xml
deleted file mode 100644 (file)
index ce5eb0d..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A commercial, simple radio receiver.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic extends="{?base_electronic?}">
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <name>radio_receiver</name>
-               <type>entertainment</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>30</width>
-                       <height>40</height>
-                       <length>20</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <technology-dependency>
-                               <name>intergrated_currents</name>
-                               <level>3</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>radio_receiving</name>
-                               <level>1</level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- A list research dependencies for this electronical device. //-->
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <!-- A single technollogy dependency. //-->
-                       <research-dependency>
-                               <name>electronics</name>
-                               <level>3</level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/electronic/surround_system.xml b/application/ship-simu/templates/game/electronic/surround_system.xml
deleted file mode 100644 (file)
index 31651a3..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A high-end surround sound system developed e.g. for home-cinema.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic extends="base_electronic">
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <!-- Id and type for this electronic. //-->
-               <name>surround_system</name>
-               <type>entertainment</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>120</width>
-                       <height>140</height>
-                       <length>120</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <technology-dependency>
-                               <name>sound_processor</name>
-                               <level>3</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>sound_equalizer</name>
-                               <level>5</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>radio_receiving</name>
-                               <level>6</level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/electronic/television.xml b/application/ship-simu/templates/game/electronic/television.xml
deleted file mode 100644 (file)
index 44da2f1..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A regular, commercial television.
-
-For simplification we have only width, length, height and total weight. This is
-in reality mostly the case because the electronics will be placed into a small
-box for transportation.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic extends="base_electronic">
-       <!-- General data of the electronics. //-->
-       <electronic-data>
-               <!-- Id and type for this electronic. //-->
-               <name>television</name>
-               <type>entertainment</type>
-               <!-- Simplified dimensions of the electronics because it will be placed
-                    into a small box for transportation. //-->
-               <dimensions>
-                       <width>100</width>
-                       <height>110</height>
-                       <length>90</length>
-               </dimensions>
-       </electronic-data>
-       <!-- An electronical device may depend on one or more technologies, at least
-            'electronics'. //-->
-       <dependencies>
-               <!-- A list technology dependencies for this electronical device. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technollogical dependency. //-->
-                       <technology-dependency>
-                               <name>video_receiving</name>
-                               <level>1</level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <name>transistor</name>
-                               <level>1</level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</electronic>
diff --git a/application/ship-simu/templates/game/engine/.htaccess b/application/ship-simu/templates/game/engine/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/engine/base_engine.xml b/application/ship-simu/templates/game/engine/base_engine.xml
deleted file mode 100644 (file)
index 675d90f..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general engine template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<engine>
-       <!-- General data about this engine. //-->
-       <engine-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <horse-power>{?horse_power?}</horse-power>
-       </engine-data>
-       <!-- Type of fuel we need. May be left out if this "engine" is e.g. a sail. //-->
-       <fuel>
-               <fuel-id>{?fuel_id?}</fuel-id>
-               <fuel-name>{?fuel_name?}</fuel-name>
-               <fuel-type>{?fuel_type?}</fuel-type>
-       </fuel>
-       <!-- Simplified dimensions of this engine. Can be left out for sails. //-->
-       <dimensions>
-               <width>{?width?}</width>
-               <height>{?height?}</height>
-               <length>{?length?}</length>
-       </dimensions>
-       <!-- Some engine require knowledge in specific technologies. //-->
-       <depenndencies>
-               <!-- A list of required technology to build this engine. A better level
-                    may increase the horse power of this engine. Some ships require
-                    higher horse power or else it won't move. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A single technology dependency. //-->
-                       <technology-dependency>
-                               <technology-id>{[?technology_id?}</technology-id>
-                               <technology-name>{[?technology_name?}</technology-name>
-                               <technology-level>{[?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </depenndencies>
-</engine>
diff --git a/application/ship-simu/templates/game/farmer/.htaccess b/application/ship-simu/templates/game/farmer/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/farmer/base_farmer.xml b/application/ship-simu/templates/game/farmer/base_farmer.xml
deleted file mode 100644 (file)
index 6542df2..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general farmer template
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<farmer>
-       <!-- General data about this farmer, like name (not the player's nickname)
-            type, birthday. //-->
-       <farmer-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <!-- The productivity may depend on the age of the farmer. //-->
-               <birthday>
-                       <month>{?month?}</month>
-                       <day>{?day?}</day>
-                       <year>{?year?}</year>
-               </birthday>
-               <!-- Productivity, experience and others. //-->
-               <productivity>{?productivity?}</productivity>
-               <experience>{?experience?}</experience>
-       </farmer-data>
-       <!-- List of all products this farmer is producing. //-->
-       <produce-list produce-count="{?produce_count?}">
-               <!-- A single produce this farmer is producing. //-->
-               <produce>
-                       <produce-id>{?produce_id?}</produce-id>
-                       <produce-name>{?produce_name?}</produce-name>
-                       <produce-type>{?produce_type?}</produce-type>
-                       <!-- A list of technology dependency required to create this
-                            produce. //-->
-                       <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                               <!-- A single technology dependency. //-->
-                               <technology-dependency>
-                                       <technology-id>{?technology_id?}</technology-id>
-                                       <technology-name>{?technology_name?}</technology-name>
-                                       <technology-level>{?technology_level?}</technology-level>
-                               </technology-dependency>
-                       </technology-dependency-list>
-               </produce>
-       </produce-list>
-</farmer>
diff --git a/application/ship-simu/templates/game/fruit/.htaccess b/application/ship-simu/templates/game/fruit/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/fruit/base_fruit.xml b/application/ship-simu/templates/game/fruit/base_fruit.xml
deleted file mode 100644 (file)
index 482faad..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general fruit template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<fruit extends="base_produce">
-</fruit>
diff --git a/application/ship-simu/templates/game/fuel/.htaccess b/application/ship-simu/templates/game/fuel/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/fuel/base_fuel.xml b/application/ship-simu/templates/game/fuel/base_fuel.xml
deleted file mode 100644 (file)
index 0f023fb..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general fuel template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<fuel>
-       <fuel-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-       </fuel-data>
-</fuel>
diff --git a/application/ship-simu/templates/game/grain/.htaccess b/application/ship-simu/templates/game/grain/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/grain/base_grain.xml b/application/ship-simu/templates/game/grain/base_grain.xml
deleted file mode 100644 (file)
index eac45e4..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general grain template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<grain>
-</grain>
diff --git a/application/ship-simu/templates/game/lifestock/.htaccess b/application/ship-simu/templates/game/lifestock/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/lifestock/base_lifestock.xml b/application/ship-simu/templates/game/lifestock/base_lifestock.xml
deleted file mode 100644 (file)
index 267077b..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general lifestock template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<lifestock>
-</lifestock>
diff --git a/application/ship-simu/templates/game/merchant/.htaccess b/application/ship-simu/templates/game/merchant/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/merchant/base_merchant.xml b/application/ship-simu/templates/game/merchant/base_merchant.xml
deleted file mode 100644 (file)
index 22d4c78..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general merchant template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<merchant>
-       <!-- General data about this merchant like id, type, summary or description. //-->
-       <merchant-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?</type>
-               <!-- A summary what this merchant is trading. //-->
-               <summary>
-                       <![CDATA[{?summary?}]]>
-               </summary>
-               <!-- A full description about this merchant. //-->
-               <description>
-                       <![CDATA[{?description?}]]>
-               </description>
-       </merchant-data>
-       <!-- The owner of this merchant. If left out the AI of the game will play
-            this merchant. //-->
-       <owner>
-               <company id="{?owner_id?}" />
-       </owner>
-       <!-- A detailed trading list of goods this merchant is trading. Amount, when
-            the first item was added or the last one was removed are being stored
-            with every goods. //-->
-       <goods-list goods-count="{?goods_count?}">
-               <!-- A single goods this merchant is trading. //-->
-               <goods>
-                       <goods-id>{?goods_id?}</goods-id>
-                       <goods-name>{?goods_name?}</goods-name>
-                       <goods-type>{?goods_type?}</goods-type>
-                       <goods-amount>{?goods_amount?}</goods-amount>
-                       <goods-first-added>{?goods_added?}</goods-first-added>
-                       <goods-last-removed>{?goods_remoed?}</goods-last-removed>
-               </goods>
-       </goods-list>
-</merchant>
diff --git a/application/ship-simu/templates/game/mineral/.htaccess b/application/ship-simu/templates/game/mineral/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/mineral/base_mineral.xml b/application/ship-simu/templates/game/mineral/base_mineral.xml
deleted file mode 100644 (file)
index 64847ff..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general mineral template. Some mineral requires technology in a specific
-level to get mined by the user. For example crystals needs drilling machines
-and undergroup drilling vehicles. These are all represented as 'technologies' so
-a mineral may have dependencies on technologies. :-)
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<mineral>
-       <!-- General data for this mineral like id, type, summary or description. //-->
-       <mineral-data>
-               <id>{?id?}</id>
-               <type>{?type?}</type>
-               <!-- A summary for this mineral. //-->
-               <mineral-summary>
-                       <![CDATA[{?summary?}]]>
-               </mineral-summary>
-               <!-- A full description for this mineral. //-->
-               <mineral-description>
-                       <![CDATA[{?description?}]]>
-               </mineral-description>
-       </mineral-data>
-       <!-- To mine some minerals some knowledge in one or two technologies is
-            required. Here you can list each technology with its required level. //-->
-       <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-               <!-- A single technology required to mine this mineral. //-->
-               <technology-dependency id="{?technology_id?}" level="{?technology_level?}" />
-       </technology-dependency-list>
-</mineral>
diff --git a/application/ship-simu/templates/game/produce/.htaccess b/application/ship-simu/templates/game/produce/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/produce/base_produce.xml b/application/ship-simu/templates/game/produce/base_produce.xml
deleted file mode 100644 (file)
index 29ca874..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general produce template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<produce>
-</produce>
diff --git a/application/ship-simu/templates/game/research/.htaccess b/application/ship-simu/templates/game/research/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/research/base_research.xml b/application/ship-simu/templates/game/research/base_research.xml
deleted file mode 100644 (file)
index 3c4d185..0000000
+++ /dev/null
@@ -1,133 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-This is a general research proposal template. A research is the theoretical
-requirement to gain a specific technology or to be able to construct special
-buildings, ships et cetera. A research may not be gainable but conductable e.g.
-in a research lab.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal>
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <max-level>{?max_level?}</max-level>
-               <!-- All researches end up with results which can be improvements to
-                    to existing technology or how research is conducted. Some research
-                    may have multiple results and they all might not be good. //-->
-               <research-result-list research-result-count="{?research_result_count?}">
-                       <!-- A single research result. //-->
-                       <research-result>
-                               <!-- A list of modified technology when this research is completed. //-->
-                               <modify-technology-list modify-technology-count="{?modify_technology_count?}">
-                                       <!-- A single technology modification. //-->
-                                       <modify-technology id="{?modify_technology_id?}" amount="{?modify_technology_amount?}" />
-                               </modify-technology-list>
-                       </research-result>
-               </research-result-list>
-               <!-- A summary for this research proposal. //-->
-               <research-summary>
-                       <![CDATA[{?summary?}]]>
-               </research-summary>
-               <!-- A full description for this research proposal. //-->
-               <research-description>
-                       <![CDATA[{?description?}]]>
-               </research-description>
-       </research-data>
-       <!-- This is somewhat a "research history". //-->
-       <research-level-list research-level-count="{?research_level_count?}">
-               <!-- A research level X has its own summary and a full description.
-                    It also can have dependencies which makes it possible to add different
-                    dependencies for higher research levels. //-->
-               <research-level>
-                       <level>{?level?}</level>
-                       <!-- When the research of this level has been started ... //-->
-                       <research-started timestamp="{?started?}" />
-                       <!-- ... and when it has ended so when the research results are
-                            available. //-->
-                       <research-finished timestamp="{?finished?}" />
-                       <!-- A summary for this research level. //-->
-                       <level-summary>
-                               <![CDATA[{?level_summary?}]]>
-                       </level-summary>
-                       <!-- A full description for this research level. //-->
-                       <level-description>
-                               <![CDATA[{?level_description?}]]>
-                       </level-description>
-                       <!-- A research level may depend on none, some or all of these
-                            'dependency types'. We are doing this this way to keep this XML
-                            simple but still flexible enougth to fit all proposal needs. //-->
-                       <level-dependencies>
-                               <level-technology-dependency-list level-technology-dependency-count="{?level_technology_dependency_count?}">
-                                       <level-technology-dependency>
-                                               <level-technology-id>{?level_technology_id?}</level-technology-id>
-                                               <level-technology-name>{?level_technology_name?}</level-technology-name>
-                                               <level-technology-type>{?level_technology_type?}</level-technology-type>
-                                               <level-technology-level>{?level_technology_level?}</level-technology-level>
-                                       </level-technology-dependency>
-                               </level-technology-dependency-list>
-                               <level-research-dependency-list level-research-dependency-count="{?level_research_dependency_count?}">
-                                       <level-research-dependency>
-                                               <level-research-id>{?level_research_id?}</level-research-id>
-                                               <level-research-name>{?level_research_name?}</level-research-name>
-                                               <level-research-type>{?level_research_type?}</level-research-type>
-                                               <level-research-level>{?level_research_level?}</level-research-level>
-                                       </level-research-dependency>
-                               </level-research-dependency-list>
-                               <level-building-dependency-list level-building-dependency-count="{?level_building_dependency_count?}">
-                                       <level-building-dependency>
-                                               <level-building-id>{?level_building_id?}</level-building-id>
-                                               <level-building-name>{?level_building_name?}</level-building-name>
-                                               <level-building-type>{?level_building_type?}</level-building-type>
-                                               <level-building-level>{?level_building_level?}</level-building-level>
-                                       </level-building-dependency>
-                               </level-building-dependency-list>
-                       </level-dependencies>
-               </research-level>
-       </research-level-list>
-       <dependencies>
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <research-dependency>
-                               <research-id>{?research_id?}</research-id>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-               <building-dependency-list building-dependency-count="{?building_dependency_count?}">
-                       <building-dependency>
-                               <building-id>{?building_id?}</building-id>
-                               <building-name>{?building_name?}</building-name>
-                               <building-type>{?building_type?}</building-type>
-                               <building-level>{?building_level?}</building-level>
-                       </building-dependency>
-               </building-dependency-list>
-       </dependencies>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/research/electricity.xml b/application/ship-simu/templates/game/research/electricity.xml
deleted file mode 100644 (file)
index c6b3480..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A electricity research proposal template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal extends="base_research">
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <name>electricity</name>
-               <type>electronics</type>
-               <max-level>10</max-level>
-       </research-data>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/research/electronics.xml b/application/ship-simu/templates/game/research/electronics.xml
deleted file mode 100644 (file)
index c2a1f6e..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A electronics research proposal template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal extends="base_research">
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <name>electronics</name>
-               <type>electronics</type>
-               <max-level>20</max-level>
-       </research-data>
-       <dependencies>
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-name>plastics</technology-name>
-                               <technology-type>chemicals</technology-type>
-                               <technology-level>2</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <research-dependency>
-                               <research-name>electricity</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>4</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/research/mathematics.xml b/application/ship-simu/templates/game/research/mathematics.xml
deleted file mode 100644 (file)
index 843c44e..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-Mathematics research purpose
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal>
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <name>mathematics</name>
-               <type>base</type>
-               <max-level>10</max-level>
-       </research-data>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/research/radio_receiving.xml b/application/ship-simu/templates/game/research/radio_receiving.xml
deleted file mode 100644 (file)
index 3428478..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A radio-receiving research proposal template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal extends="base_research">
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <name>radio_receiving</name>
-               <type>electronics</type>
-               <max-level>10</max-level>
-       </research-data>
-       <dependencies>
-               <!-- All research proposal dependencies for this research proposal. //-->
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <!-- A research proposal dependency for this research proposal. //-->
-                       <technology-dependency>
-                               <technology-name>signal_modulation</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/research/statics.xml b/application/ship-simu/templates/game/research/statics.xml
deleted file mode 100644 (file)
index 302412e..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-Statistics research purpose
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<research-proposal>
-       <!-- General data of this research like id, summar or description. //-->
-       <research-data>
-               <name>statics</name>
-               <type>construction</type>
-               <max-level>20</max-level>
-       </research-data>
-       <dependencies>
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <research-dependency-list dependency-count="{?research_dependency_count?}">
-                       <research-dependency>
-                               <technology-name>mathematics</technology-name>
-                               <technology-type>{?research_type?}</technology-type>
-                               <technology-level>4</technology-level>
-                       </research-dependency>
-               </research-dependency-list>
-               <building-dependency-list dependency-count="{?building_dependency_count?}">
-                       <building-dependency>
-                               <building-name>{?building_name?}</building-name>
-                               <building-type>{?building_type?}</building-type>
-                               <building-level>{?building_level?}</building-level>
-                       </building-dependency>
-               </building-dependency-list>
-       </dependencies>
-</research-proposal>
diff --git a/application/ship-simu/templates/game/resource/.htaccess b/application/ship-simu/templates/game/resource/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/resource/base_resource.xml b/application/ship-simu/templates/game/resource/base_resource.xml
deleted file mode 100644 (file)
index 8860210..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general resource template. Resources need to be harvested and them
-transportaed to facilities which can process them. To harvest some resources
-the player may need knowledge in some technology.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<resource>
-       <!-- General data for this resource like id, type, summary or description. //-->
-       <resource-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <!-- A summary for this resource. //-->
-               <resource-summary>
-                       <![CDATA[{?summary?}]]>
-               </resource-summary>
-               <!-- A full description for this resource. //-->
-               <resource-description>
-                       <![CDATA[{?description?}]]>
-               </resource-description>
-       </resource-data>
-       <!-- To harvest some resource some knowledge in one or two technologies is
-            required. Here you can list each technology with its required level. //-->
-       <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-               <!-- A single technology dependency to harvest this resource. //-->
-               <technology-dependency>
-                       <technology-id>{?technology_id?}</technology-id>
-                       <technology-name>{?technology_name?}</technology-name>
-                       <technology-type>{?technology_type?}</technology-type>
-                       <technology-level>{?technology_level?}</technology-level>
-               </technology-dependency>
-       </technology-dependency-list>
-</resource>
diff --git a/application/ship-simu/templates/game/ship/.htaccess b/application/ship-simu/templates/game/ship/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/ship/base_ship.xml b/application/ship-simu/templates/game/ship/base_ship.xml
deleted file mode 100644 (file)
index a33efe8..0000000
+++ /dev/null
@@ -1,134 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general ship template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<ship>
-       <!-- Some general data about this ship. Some may not be required for the
-            simulation at the moment. //-->
-       <ship-data>
-               <id>{?id?}</id>
-               <name><![CDATA[{?name?}]]></name>
-               <type>{?type?}</type>
-               <ship-propeller>{?propeller?}</ship-propeller>
-               <total-weight>{?weight?}</total-weight>
-               <total-displacement>{?displacement?}</total-displacement>
-               <!-- Some data about the construction phase, like company, contract. //-->
-               <construction>
-                       <!-- The construction company of this ship. //-->
-                       <construction-company>{?construction_id?}</construction-company>
-                       <!-- The signed construction contract for this ship. //-->
-                       <construction-contract>{?construction_contract_id?}</construction-contract>
-                       <!-- When the construction has started. //-->
-                       <construction-started>{?construction_started?}</construction-started>
-                       <!-- And when the ship was constructed. //-->
-                       <construction-finished>{?construction_finished?</construction-finished>
-               </construction>
-       </ship-data>
-       <!-- A list of shipping companies who owned this ship. //-->
-       <shipping-company-list>
-               <!-- A single company who owned this ship for a tme span. //-->
-               <shipping-company>
-                       <company-id>{?company_id?}</company-id>
-                       <!-- A time span when the company owned this ship. //-->
-                       <holder-timespan>
-                               <started>{?holder_started?}</started>
-                               <ended>{?holder_ended?}</ended>
-                       </hoolder-timespan>
-                       <!-- A contract signed for changing ownership. //-->
-                       <contract id="{?contract_id?}" />
-               </shipping-company>
-       </shipping-company-list>
-       <!-- A list of structures to build this ship. If you need more than of a
-            structure type just specify the neccessary amount. //-->
-       <ship-structure-list>
-               <!-- A single ship structure. This can be anything from the wheel house
-                    to theatre or little ships, decks and cabins. //-->
-               <ship-structure extends="{?structure_template?}">
-                       <structure-id>{?structure_id?}</structure-id>
-                       <structure-amount>{?structure_amount?}</structure-amount>
-                       <structure-type>{?structure_type?}</structure-type>
-               </ship-structure>
-       </ship-structure-list>
-       <!-- All ships require an engine, even when or 'engine' is a sail, to move
-            around. //-->
-       <engine extends="{?engine_template?}">
-               <engine-id>{?engine_id?{</engine-id>
-               <engine-type>{?engine_type?}</engine-type>
-       </engine>
-       <!-- A list of what this ship transportates. //-->
-       <transportation-list>
-               <!-- @TODO This section is not complete. //-->
-       </transportation-list>
-       <!-- A ship may require one or more of these system to operate. //-->
-       <ship-systems>
-               <!-- The electric system of latest ships has becom the most important
-                    on a ship. It powers all other systems and provides electrical
-                    power to all kind of commercials and cabins including interior and
-                    exterior lights. So you should be adviced to provide emergency
-                    systems and redudancy for this system. //-->
-               <electric-system>
-                       <!-- @TODO This section is not complete. //-->
-               </electric-system>
-               <!-- On latest ships you require to have a hydric system to operate
-                    heavy bulkheads which seperates sections on low-level decks. On
-                    passenger ships the hydraulic system have to operate front and/or
-                    rear doors to let drive vehicles in. //-->
-               <hydraulic-system>
-                       <!-- @TODO This section is not complete. //-->
-               </hydraulic-system>
-               <!-- Nearly all ships will have a navigation system. //-->
-               <navigation-system>
-                       <!-- @TODO This section is not complete. //-->
-               </navigation-system>
-               <!-- A guidance system which every ship should have... //-->
-               <guidance-system>
-                       <!-- @TODO This section is not complete. //-->
-               </guidance-system>
-               <!-- A fire reporting and fighting system. //-->
-               <fire-system>
-                       <!-- @TODO This section is not complete. //-->
-               </fire-system>
-       </ship-systems>
-       <!-- Ships depend on several technologies and maybe research proposals. //-->
-       <dependencies>
-               <!-- A list of technology dependencies for this ship. //-->
-               <technology-dependency-list>
-                       <!-- A single technology dependencies for this ship. //-->
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- A list of research proposals dependencies for this ship. //-->
-               <research-dependency-list>
-                       <!-- A single research proposals  dependencies for this ship. //-->
-                       <research-dependency>
-                               <research-id>{?research_id?}</research-id>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</ship>
diff --git a/application/ship-simu/templates/game/tank/.htaccess b/application/ship-simu/templates/game/tank/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/tank/base_tank.xml b/application/ship-simu/templates/game/tank/base_tank.xml
deleted file mode 100644 (file)
index c943576..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general tank template for different types of fuel.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<tank>
-       <tank-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-       </tank-data>
-       <content>
-               <content-id>{?content_id?}</content-id>
-               <content-name>{?content_name?}</content-name>
-               <content-type>{?content_type?}</content-type>
-       </content>
-       <dependencies>
-               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</tank>
diff --git a/application/ship-simu/templates/game/technology/.htaccess b/application/ship-simu/templates/game/technology/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/technology/architecture.xml b/application/ship-simu/templates/game/technology/architecture.xml
deleted file mode 100644 (file)
index 6547cc5..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A architecture technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>architecture</name>
-               <type>construction</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <!-- @TODO Find a technology type //-->
-                               <technology-name>drawings</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <!-- @TODO Find research types //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <research-dependency>
-                               <research-name>statics</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>3</research-level>
-                       </research-dependency>
-                       <research-dependency>
-                               <research-name>mathematics</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>6</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/base_technology.xml b/application/ship-simu/templates/game/technology/base_technology.xml
deleted file mode 100644 (file)
index 846a215..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology>
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <id>{?id?}</id>
-               <name>{?name?}</name>
-               <type>{?type?}</type>
-               <!-- The date/time when this technology was gained, e.g. by research. //-->
-               <technology-gained timestamp="{?gained?}" />
-               <!-- A summary of this technology. //-->
-               <technology-summary>
-                       <![CDATA[{?summary?}]]>
-               </technology-summary>
-               <!-- A full description of this technology. //-->
-               <technology-description>
-                       <![CDATA[{?description?}]]>
-               </technology-description>
-       </technology-data>
-       <!-- All levels of this technology are held in this tag. //-->
-       <technology-level-list>
-               <!-- A single technology level with its basic data, own summary and
-                    description. //-->
-               <technology-level>
-                       <level>{?list_level?}</level>
-                       <gained>{?level_gained?}</gained>
-                       <!-- A summary of this technology level. //-->
-                       <technology-level-summary>
-                               <![CDATA[{?level_summary?}]]>
-                       </technology-level-summary>
-                       <!--  A full description of this technology level. //-->
-                       <technology-level-description>
-                               <![CDATA[{?level_description?}]]>
-                       </technology-level-description>
-                       <!-- A specific technology level may depend on some further technologies or research
-                            proposals. //-->
-                       <level-dependencies>
-                               <!-- All technology dependencies for this technology. //-->
-                               <technology-level-dependency-list>
-                                       <!-- A technology dependency for this technology. //-->
-                                       <technology-level-dependency>
-                                               <technology-level-id>{?technology_level_id?}</technology-level-id>
-                                               <technology-level-name>{?technology_level_name?}</technology-level-name>
-                                               <technology-level-level>{?technology_level_level?}</technology-level-level>
-                                       </technology-level-dependency>
-                               </technology-level-dependency-list>
-                               <!-- All research dependencies for this technology. //-->
-                               <research-level-dependency-list>
-                                       <!-- A research dependency for this technology. //-->
-                                       <research-level-dependency>
-                                               <research-level-id>{?research_level_id?}</research-level-id>
-                                               <research-level-name>{?research_level_name?}</research-level-name>
-                                               <research-level-level>{?research_level_level?}</research-level-level>
-                                       </research-level-dependency>
-                               </research-dependency-list>
-                       </level-dependencies>
-               </technology-level>
-       </technology-level-list>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list>
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-id>{?technology_id?}</technology-id>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list>
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-id>{?research_id?}</research-id>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/cellular_network.xml b/application/ship-simu/templates/game/technology/cellular_network.xml
deleted file mode 100644 (file)
index 77f4a82..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A cellular network technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>cellular_network</name>
-               <type>communication</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- @TODO Find some technology dependencies. //-->
-                       <technology-dependency>
-                               <technology-name></technology-name>
-                               <technology-type></technology-type>
-                               <technology-level></technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <!-- @TODO Find a research type //-->
-                       <research-dependency>
-                               <technology-name>electronics</technology-name>
-                               <technology-type>{?research_type?}</technology-type>
-                               <technology-level>5</technology-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/drawings.xml b/application/ship-simu/templates/game/technology/drawings.xml
deleted file mode 100644 (file)
index 43dbf50..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A drawings technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>drawings</name>
-               <type>base</type>
-       </technology-data>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/glass_making.xml b/application/ship-simu/templates/game/technology/glass_making.xml
deleted file mode 100644 (file)
index 7679857..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A glass-making technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>glass_making</name>
-               <type>production</type>
-       </technology-data>
-       <!-- All levels of this technology are held in this tag. //-->
-       <technology-level-list technology-level-count="{?technology_level_count?}">
-               <!-- A single technology level with its basic data, own summary and
-                    description. //-->
-               <technology-level>
-                       <level>{?list_level?}</level>
-                       <!-- A specific technology level may depend on some further technologies or research
-                            proposals. //-->
-                       <level-dependencies>
-                               <!-- All technology dependencies for this technology. //-->
-                               <technology-level-dependency-list>
-                                       <!-- A technology dependency for this technology. //-->
-                                       <technology-level-dependency>
-                                               <technology-name>{?technology_level_name?}</technology-name>
-                                               <technology-type>{?technology_level_type?}</technology-type>
-                                               <technology-level>{?technology_level_level?}</technology-level>
-                                       </technology-level-dependency>
-                               </technology-level-dependency-list technology-level-dependency-count="{?technology_level_dependency_count?}">
-                               <!-- All research dependencies for this technology. //-->
-                               <research-level-dependency-list research-level-dependency-count="{?research_level_dependency_count?}">
-                                       <!-- A research dependency for this technology. //-->
-                                       <research-level-dependency>
-                                               <research-name>{?research_level_name?}</research-name>
-                                               <research-type>{?research_level_type?}</research-type>
-                                               <research-level>{?research_level_level?}</research-level>
-                                       </research-level-dependency>
-                               </research-dependency-list>
-                       </level-dependencies>
-               </technology-level>
-       </technology-level-list>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>{?technology_level?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/household_devices.xml b/application/ship-simu/templates/game/technology/household_devices.xml
deleted file mode 100644 (file)
index e19e14f..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A generic household device template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>household_devices</name>
-               <type>electronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-name>plastics</technology-name>
-                               <technology-type>chemicals</technology-type>
-                               <technology-level>3</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research proposal dependencies for this research. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- @TODO Find a research type //-->
-                       <research-dependency>
-                               <research-name>electronics</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>1</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/intergrated_currents.xml b/application/ship-simu/templates/game/technology/intergrated_currents.xml
deleted file mode 100644 (file)
index bdfebce..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A intergrated-current (IC) technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>intergrated_currents</name>
-               <type>eletronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>transistor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>10</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>silicium_mining</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>1</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/laboratory_equipment.xml b/application/ship-simu/templates/game/technology/laboratory_equipment.xml
deleted file mode 100644 (file)
index 1b40430..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A laboratory-equipment technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>laboratory_equipment</name>
-               <type>equipment</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals. //-->
-       <dependencies>
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-name>plastics</technology-name>
-                               <technology-type>chemicals</technology-type>
-                               <technology-level>3</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>glass_making</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/naval_architecture.xml b/application/ship-simu/templates/game/technology/naval_architecture.xml
deleted file mode 100644 (file)
index 5a00d72..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A naval architecture technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="architecture">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>naval_architecture</name>
-               <type>ship_construction</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <technology-dependency>
-                               <technology-name>architecture</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>3</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>statics</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>drawings</technology-name>
-                               <technology-type>{?technology_type?}</technology-type>
-                               <technology-level>6</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <research-dependency>
-                               <research-name>mathematics</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>8</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/plastics.xml b/application/ship-simu/templates/game/technology/plastics.xml
deleted file mode 100644 (file)
index 94f2720..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A plastics technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>plastics</name>
-               <type>production</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <!-- @TODO Find a chemical name and level for this technology. //-->
-                               <technology-name>{?technology_name?}</technology-name>
-                               <technology-type>chemicals</technology-type>
-                               <technology-level>{?technology_name?}</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>chemistry</research-name>
-                               <research-type>chemicals</research-type>
-                               <research-level>3</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/signal_amplifying.xml b/application/ship-simu/templates/game/technology/signal_amplifying.xml
deleted file mode 100644 (file)
index 5cc9e01..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A signal amplifying technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>signal_amplifying</name>
-               <type>electronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>transistor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>3</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>modulation</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>1</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/signal_modulation.xml b/application/ship-simu/templates/game/technology/signal_modulation.xml
deleted file mode 100644 (file)
index 186a569..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A signal modulation technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>signal_modulation</name>
-               <type>electronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>transistor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>3</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>modulation</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>1</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/sound_equalizer.xml b/application/ship-simu/templates/game/technology/sound_equalizer.xml
deleted file mode 100644 (file)
index 8d10f58..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A sound-processing technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>sound_equalizer</name>
-               <type>electronic</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>transistor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <!-- @TODO Should we find some theory behind equalizing? //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/sound_processor.xml b/application/ship-simu/templates/game/technology/sound_processor.xml
deleted file mode 100644 (file)
index d223b4f..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A sound-processing technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>sound_processor</name>
-               <type>electronic</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>intergrated_current</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>7</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>surround_mixing</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <!-- @TODO Should we find some theory behind processing? //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/surround_mixing.xml b/application/ship-simu/templates/game/technology/surround_mixing.xml
deleted file mode 100644 (file)
index 9c674de..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A sound-processing technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>surround_mixing</name>
-               <type>electronic</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>intergrated_current</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>6</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <!-- @TODO Should we find some theory behind surround mixer? //-->
-               <research-dependency-list research-dependency-count="{?research-dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <research-dependency>
-                               <research-name>{?research_name?}</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>{?research_level?}</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/transistor.xml b/application/ship-simu/templates/game/technology/transistor.xml
deleted file mode 100644 (file)
index f41d448..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A transistor technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>transistor</name>
-               <type>eletronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>semiconductor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>plastics</technology-name>
-                               <technology-type>chemicals</technology-type>
-                               <technology-level>5</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-               <!-- All research dependencies for this technology. //-->
-               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
-                       <!-- A research dependency for this technology. //-->
-                       <!-- @TODO Find a research type //-->
-                       <research-dependency>
-                               <research-name>silicium_mining</research-name>
-                               <research-type>{?research_type?}</research-type>
-                               <research-level>1</research-level>
-                       </research-dependency>
-               </research-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/technology/video_receiving.xml b/application/ship-simu/templates/game/technology/video_receiving.xml
deleted file mode 100644 (file)
index 353d40a..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A transistor technology template.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<technology extends="base_technology">
-       <!-- General technology data like type, level, summary or description. //-->
-       <technology-data>
-               <name>video_receiving</name>
-               <type>eletronics</type>
-       </technology-data>
-       <!-- A technology may depend on some other technologies or research
-            proposals to gain the first level of this technology. //-->
-       <dependencies>
-               <!-- All technology dependencies for this technology. //-->
-               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
-                       <!-- A technology dependency for this technology. //-->
-                       <technology-dependency>
-                               <technology-name>signal_amplifying</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>signal_modulation</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-                       <technology-dependency>
-                               <technology-name>transistor</technology-name>
-                               <technology-type>electronics</technology-type>
-                               <technology-level>1</technology-level>
-                       </technology-dependency>
-               </technology-dependency-list>
-       </dependencies>
-</technology>
diff --git a/application/ship-simu/templates/game/types/.htaccess b/application/ship-simu/templates/game/types/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/types/building_types.xml b/application/ship-simu/templates/game/types/building_types.xml
deleted file mode 100644 (file)
index 58da39a..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid types of buildings.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<building-type-list building-type-count="{?building_type_count?}">
-       <!-- Research buildings. //-->
-       <building type type="research" />
-</building-type-list>
diff --git a/application/ship-simu/templates/game/types/container_types.xml b/application/ship-simu/templates/game/types/container_types.xml
deleted file mode 100644 (file)
index 46a0c35..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid container types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<container-type-list container-type-count="{?container_type_count?}">
-       <!-- A large cargo container made of steel, a very usual one which can be
-            used to transport very lots of things like entertainment electronics
-            and many more. //-->
-       <container-type type="large_cargo" />
-       <!-- The smaller brother of the above large container. This container is
-            usually half size of the large one. So two of them can be placed where
-            one large container fits... //-->
-       <container-type type="medium_cargo" />
-       <!-- @TODO Add more containers. //-->
-</container-type-list>
diff --git a/application/ship-simu/templates/game/types/content_types.xml b/application/ship-simu/templates/game/types/content_types.xml
deleted file mode 100644 (file)
index f2853a6..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid content types, e.g. to be placed in container.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<content-type-list content-type-count="{?content_type_count?}">
-       <!-- All types of resources can be transportated. //-->
-       <content-type type="resource" />
-       <!-- All types of minerals can be transportated. //-->
-       <content-type type="mineral" />
-       <!-- All types of electronics can be transportated e.g. entertainment or communication electronics. //-->
-       <content-type type="electronic" />
-       <!-- @TODO Add more container content types. //-->
-</content-type-list>
diff --git a/application/ship-simu/templates/game/types/contract_types.xml b/application/ship-simu/templates/game/types/contract_types.xml
deleted file mode 100644 (file)
index 1e1ce09..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid contract types.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<contract-type-list contract-type-count="{?contract-type_count?}">
-       <!-- A construction contract, possible signers: Construction company, customer, creditor //-->
-       <contract-type type="construction_contract" max-signers="3">
-               <!-- All valid signer types for this contract //-->
-               <signer-type-list extends="signer_types" signer-type-count="{?signer_type_count?}">
-                       <signer-type type="player" slot="all" max="3" />
-                       <signer-type type="moneybank" slot="creditor" max="1" />
-                       <signer-type type="construction_company" slot="construction_company" max="1" />
-               </signer-type-list>
-               <!-- And the corresponding slot types //-->
-               <slots>
-                       <slot type="construction_company" must-have="true" />
-                       <slot type="customer" must-have="true" />
-                       <slot type="creditor" must-have="false" />
-               </slots>
-       </contract-type>
-       <!-- @TODO Add more contract types. //-->
-</contract-type-list>
diff --git a/application/ship-simu/templates/game/types/electronic_types.xml b/application/ship-simu/templates/game/types/electronic_types.xml
deleted file mode 100644 (file)
index a5248dd..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid types of electronics. This can be cellphones, computers, hifi systems
-and many many more.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<electronic-type-list electronic-type-count="{?electronic_type_count?}">
-       <!-- All common communication devices. //-->
-       <electronic-type type="communication" />
-       <!-- All commercial systems for entertainment. //-->
-       <electronic-type type="entertainment" />
-       <!-- @TODO Add more types. //-->
-</electronic-type-list>
diff --git a/application/ship-simu/templates/game/types/engine_types.xml b/application/ship-simu/templates/game/types/engine_types.xml
deleted file mode 100644 (file)
index ea42838..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid engine types.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<enngine-type-list engine-type-count="{?engine_type_count?}">
-       <!-- Modern ships has a motorized (steam, oil or diesel) engine. //-->
-       <engine-type type="motor" />
-</enngine-type-list>
diff --git a/application/ship-simu/templates/game/types/farmer_types.xml b/application/ship-simu/templates/game/types/farmer_types.xml
deleted file mode 100644 (file)
index a11f5cc..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid farmer types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<farmer-type-list farmer-type-count="{?farmer_type_count?}">
-</farmer-type-list>
diff --git a/application/ship-simu/templates/game/types/fuel_types.xml b/application/ship-simu/templates/game/types/fuel_types.xml
deleted file mode 100644 (file)
index 00399a4..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid fuel types.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<fuel-type-list fuel-type-count="{?fuel_type_count?}">
-       <!-- Fosil fuels can be oil, cerosine or diesel. //-->
-       <fuel-type type="fosil" />
-</fuel-type-list>
diff --git a/application/ship-simu/templates/game/types/merchant_types.xml b/application/ship-simu/templates/game/types/merchant_types.xml
deleted file mode 100644 (file)
index 878359f..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid merchant types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<merchant-type-list merchant-type-count="{?merchant_type_count?}">
-</merchant-type-list>
diff --git a/application/ship-simu/templates/game/types/owner_occupants.xml b/application/ship-simu/templates/game/types/owner_occupants.xml
deleted file mode 100644 (file)
index e72ceea..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All types of owners and occupants
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished definition
-
-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/>
-//-->
-<owner-occupant-type-list owner-occupant-type-count="{?owner_occupant_type_count?}">
-</owner-occupants-type-list>
diff --git a/application/ship-simu/templates/game/types/product_types.xml b/application/ship-simu/templates/game/types/product_types.xml
deleted file mode 100644 (file)
index 8c82ddc..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid product types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<product-type-list product-type-count="{?product_type_count?}">
-</product-type-list>
diff --git a/application/ship-simu/templates/game/types/research_types.xml b/application/ship-simu/templates/game/types/research_types.xml
deleted file mode 100644 (file)
index 0fc7280..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid research proposal types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<research-type-list research-type-count="{?research_type_count?}">
-       <!-- A base research proposal which all others depend on. //-->
-       <research-type type="base" />
-       <!-- An electronics research proposal. This type may conflict with the
-            same technology. This is also why it is hard to devide between
-            technology and theory in this type. //-->
-       <research-type type="electronics" />
-</technology-type-list>
diff --git a/application/ship-simu/templates/game/types/ship_types.xml b/application/ship-simu/templates/game/types/ship_types.xml
deleted file mode 100644 (file)
index 2d47c7b..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All known and valid types of ships.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          This is a very simmple list, extend it.
-
-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/>
-//-->
-<ship-type-list ship-type-count="{?ship_type_count?}">
-       <!-- A small ship for passengers used in large habors and cities. //-->
-       <ship-type type="farry" />
-       <!-- Medium to large passenger ships, used to transportate passengers, their
-            cars and trucks or trains on long distances. //-->
-       <ship-type type="passenger" />
-       <!-- Medium to large container ships to transport their cargo on long
-            distances. //-->
-       <ship-type type="container" />
-       <!-- Medium to large oil tankers for long distances. //-->
-       <ship-type type="oiltanker" />
-       <!-- Medium to large gas tankers for long distances. //-->
-       <ship-type type="gastanker" />
-       <!-- @TODO Add more ship types. //-->
-</ship-type-list>
diff --git a/application/ship-simu/templates/game/types/signer_types.xml b/application/ship-simu/templates/game/types/signer_types.xml
deleted file mode 100644 (file)
index 611853a..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid signer types and how they should translated into database and table
-names.
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@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/>
-//-->
-<signer-type-list signer-type-count="{?signer_type_count?}">
-       <!-- The type 'player' which is in facts the user. //-->
-       <signer-type type="player" table="user" column="userid" />
-       <!-- @TODO Add more types, e.g. company //-->
-</signer-types-list>
diff --git a/application/ship-simu/templates/game/types/tank_types.xml b/application/ship-simu/templates/game/types/tank_types.xml
deleted file mode 100644 (file)
index 2aa4d22..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid tank types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<tank-type-list tank-type-count="{?tank_type_count?}">
-</tank-type-list>
diff --git a/application/ship-simu/templates/game/types/technology_types.xml b/application/ship-simu/templates/game/types/technology_types.xml
deleted file mode 100644 (file)
index b139d89..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-All valid technology types
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<technology-type-list technology-type-count="{?technology_type_count?}">
-       <!-- A base technology which all others depend on. //-->
-       <technology-type type="base" />
-       <!-- Technology required for construction of buildings. //-->
-       <technology-type type="building" />
-       <!-- Different chemicals. //-->
-       <technology-type type="chemicals" />
-       <!-- Technologies for common communication devices. //-->
-       <technology-type type="communication" />
-       <!-- Technologies for different constructions. //-->
-       <technology-type type="construction" />
-       <!-- Different electronics technologies. //-->
-       <technology-type type="electronics" />
-       <!-- Different equipment technologies. //-->
-       <technology-type type="equipment" />
-       <!-- Different production technologies. //-->
-       <technology-type type="production" />
-       <!-- Technologies for different ship constructions. //-->
-       <technology-type type="ship_construction" />
-</technology-type-list>
diff --git a/application/ship-simu/templates/game/vegetable/.htaccess b/application/ship-simu/templates/game/vegetable/.htaccess
deleted file mode 100644 (file)
index 3a42882..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Deny from all
diff --git a/application/ship-simu/templates/game/vegetable/base_vegetable.xml b/application/ship-simu/templates/game/vegetable/base_vegetable.xml
deleted file mode 100644 (file)
index 80925e5..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-A general vegetable template
-
-@author                Roland Haeder <webmaster@ship-simu.org>
-@version       0.0.0
-@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
-@license       GNU GPL 3.0 or any newer version
-@link          http://www.ship-simu.org
-@todo          Unfinished template
-
-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/>
-//-->
-<vegetable extends="base_produce">
-</vegetable>
diff --git a/application/shipsimu/.htaccess b/application/shipsimu/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/admin/.htaccess b/application/shipsimu/admin/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/class_ApplicationHelper.php b/application/shipsimu/class_ApplicationHelper.php
new file mode 100644 (file)
index 0000000..7000c38
--- /dev/null
@@ -0,0 +1,227 @@
+<?php
+/**
+ * A class holding general data about the application and some methods for
+ * the management including the entry point.
+ *
+ * E.g.:
+ *
+ * index.php?app=my_app
+ *
+ * You need to create a folder in the folder "application" named "my_app"
+ * (without the quotes) and create a include file called
+ * class_ApplicationHelper.php. You have to write the same class for your
+ * application and implement the same interface called ManageableApplication
+ * because this class include file will be searched for.
+ *
+ * It is good when you avoid more GET parameters to keep URLs short and sweet.
+ * But sometimes you need some GET paramerers e.g. for your imprint or info page
+ * or other linked pages which you have to create and state some informations.
+ *
+ * Please remember that this include file is being loaded *before* the class
+ * loader is loading classes from "exceptions", "interfaces" and "main"!
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0
+ * @copyright  Copyright (c) 2007 - 2008 Roland Haeder, 2009 - 2012 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ *
+ * 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 ApplicationHelper extends BaseFrameworkSystem implements ManageableApplication, Registerable {
+       /**
+        * The version number of this application
+        */
+       private $appVersion = '';
+
+       /**
+        * The human-readable name for this application
+        */
+       private $appName = '';
+
+       /**
+        * The short uni*-like name for this application
+        */
+       private $shortName = '';
+
+       /**
+        * An instance of this class
+        */
+       private static $selfInstance = NULL;
+
+       /**
+        * Private constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Getter for an instance of this class
+        *
+        * @return      $selfInstance   An instance of this class
+        */
+       public static final function getSelfInstance () {
+               // Is the instance there?
+               if (is_null(self::$selfInstance)) {
+                       self::$selfInstance = new ApplicationHelper();
+               } // END - if
+
+               // Return the instance
+               return self::$selfInstance;
+       }
+
+       /**
+        * Getter for the version number
+        *
+        * @return      $appVersion     The application's version number
+        */
+       public final function getAppVersion () {
+               return $this->appVersion;
+       }
+       /**
+        * Setter for the version number
+        *
+        * @param       $appVersion     The application's version number
+        * @return      void
+        */
+       public final function setAppVersion ($appVersion) {
+               // Cast and set it
+               $this->appVersion = (string) $appVersion;
+       }
+
+       /**
+        * Getter for human-readable name
+        *
+        * @return      $appName        The application's human-readable name
+        */
+       public final function getAppName () {
+               return $this->appName;
+       }
+
+       /**
+        * Setter for human-readable name
+        *
+        * @param       $appName        The application's human-readable name
+        * @return      void
+        */
+       public final function setAppName ($appName) {
+               // Cast and set it
+               $this->appName = (string) $appName;;
+       }
+
+       /**
+        * Getter for short uni*-like name
+        *
+        * @return      $shortName      The application's short uni*-like name
+        */
+       public final function getAppShortName () {
+               return $this->shortName;
+       }
+
+       /**
+        * Setter for short uni*-like name
+        *
+        * @param       $shortName      The application's short uni*-like name
+        * @return      void
+        */
+       public final function setAppShortName ($shortName) {
+               // Cast and set it
+               $this->shortName = (string) $shortName;
+       }
+
+       /**
+        * Launches the application
+        *
+        * @return      void
+        */
+       public final function entryPoint () {
+               // Set this application in registry
+               Registry::getRegistry()->addInstance('app', $this);
+
+               // Default response is console
+               $response = $this->getResponseTypeFromSystem();
+               $responseType = $this->getResponseTypeFromSystem();
+
+               // Create a new request object
+               $requestInstance = ObjectFactory::createObjectByName($this->convertToClassName($response) . 'Request');
+
+               // Remember request instance here
+               $this->setRequestInstance($requestInstance);
+
+               // Do we have another response?
+               if ($requestInstance->isRequestElementSet('request')) {
+                       // Then use it
+                       $response = strtolower($requestInstance->getRequestElement('request'));
+                       $responseType = $response;
+               } // END - if
+
+               // ... and a new response object
+               $responseClass = sprintf("%sResponse", $this->convertToClassName($response));
+               $responseInstance = ObjectFactory::createObjectByName($responseClass, array($this));
+
+               // Remember response instance here
+               $this->setResponseInstance($responseInstance);
+
+               // Get the parameter from the request
+               $commandName = $requestInstance->getRequestElement('command');
+
+               // If it is null then get default command
+               if (is_null($commandName)) {
+                       // Get default command
+                       $commandName = $responseInstance->getDefaultCommand();
+
+                       // Set it in request
+                       $requestInstance->setRequestElement('command', $commandName);
+               } // END - if
+
+               // Get a controller resolver
+               $resolverClass = $this->convertToClassName($this->getAppShortName() . '_' . $responseType . '_controller_resolver');
+               $resolverInstance = ObjectFactory::createObjectByName($resolverClass, array($commandName, $this));
+
+               // Get a controller instance as well
+               $this->setControllerInstance($resolverInstance->resolveController());
+
+               // Launch the main routine here
+               $this->getControllerInstance()->handleRequest($requestInstance, $responseInstance);
+       }
+
+       /**
+        * Handle the indexed array of fatal messages and puts them out in an
+        * acceptable fasion
+        *
+        * @param       $messageList    An array of fatal messages
+        * @return      void
+        */
+       public function handleFatalMessages (array $messageList) {
+               // Walk through all messages
+               foreach ($messageList as $message) {
+                       exit(__METHOD__ . ':MSG:' . $message);
+               } // END - foreach
+       }
+
+       /**
+        * Builds the master template's name
+        *
+        * @return      $masterTemplateName             Name of the master template
+        */
+       public function buildMasterTemplateName () {
+               return 'node_main';
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/config.php b/application/shipsimu/config.php
new file mode 100644 (file)
index 0000000..b37151f
--- /dev/null
@@ -0,0 +1,539 @@
+<?php
+/**
+ * Additional/overwritten configuration parts
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Get a configuration instance for shorter lines
+$cfg = FrameworkConfiguration::getSelfInstance();
+
+// CFG: HEADER-CHARSET
+$cfg->setConfigEntry('header_charset', 'utf-8');
+
+// CFG: DEFAULT-WEB-COMMAND
+$cfg->setConfigEntry('default_web_command', 'home');
+
+// CFG: DEFAULT-IMAGE-COMMAND
+$cfg->setConfigEntry('default_image_command', 'build');
+
+// CFG: FORM-ACTION
+$cfg->setConfigEntry('form_action', 'index.php?app={?app_short_name?}&amp;page=do_form');
+
+// CFG: FORM-METHOD
+$cfg->setConfigEntry('form_method', 'post');
+
+// CFG: FORM-TARGET
+$cfg->setConfigEntry('form_target', '_self');
+
+// CFG: REGISTER-REQUIRES-EMAIL
+$cfg->setConfigEntry('register_requires_email', 'Y');
+
+// CFG: REGISTER-INCLUDES-PROFILE
+$cfg->setConfigEntry('register_includes_profile', 'Y');
+
+// CFG: REGISTER-PERSONAL-DATA
+$cfg->setConfigEntry('register_personal_data', 'Y');
+
+// CFG: REGISTER-EMAIL-UNIQUE
+$cfg->setConfigEntry('register_email_unique', 'Y');
+
+// CFG: PROFILE-INCLUDES-BIRTHDAY
+$cfg->setConfigEntry('profile_includes_birthday', 'Y');
+
+// CFG: CHAT-ENABLED-ICQ
+$cfg->setConfigEntry('chat_enabled_icq', 'Y');
+
+// CFG: CHAT-ENABLED-JABBER
+$cfg->setConfigEntry('chat_enabled_jabber', 'Y');
+
+// CFG: CHAT-ENABLED-YAHOO
+$cfg->setConfigEntry('chat_enabled_yahoo', 'Y');
+
+// CFG: CHAT-ENABLED-AOL
+$cfg->setConfigEntry('chat_enabled_aol', 'Y');
+
+// CFG: CHAT-ENABLED-MSN
+$cfg->setConfigEntry('chat_enabled_msn', 'Y');
+
+// CFG: USER-REGISTRATION
+$cfg->setConfigEntry('user_registration_class', 'ShipSimuRegistration');
+
+// CFG: USER-LOGIN-CLASS
+$cfg->setConfigEntry('user_login_class', 'ShipSimuUserLogin');
+
+// CFG: GUEST-LOGIN-CLASS
+$cfg->setConfigEntry('guest_login_class', 'ShipSimuGuestLogin');
+
+// CFG: USER-STATUS-REGISTER
+$cfg->setConfigEntry('user_status_unconfirmed', 'UNCONFIRMED');
+
+// CFG: USER-STATUS-GUEST
+$cfg->setConfigEntry('user_status_guest', 'GUEST');
+
+// CFG: USER-STATUS-CONFIRMED
+$cfg->setConfigEntry('user_status_confirmed', 'CONFIRMED');
+
+// CFG: USER-STATUS-LOCKED
+$cfg->setConfigEntry('user_status_locked', 'LOCKED');
+
+// CFG: LOGIN-HELPER-CLASS
+$cfg->setConfigEntry('login_helper_class', 'ShipSimuLoginHelper');
+
+// CFG: AUTH-METHOD-CLASS
+$cfg->setConfigEntry('auth_method_class', 'CookieAuth');
+
+// CFG: APP-LOGIN-URL
+$cfg->setConfigEntry('app_login_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: LOGIN-FAILED-URL
+$cfg->setConfigEntry('login_failed_url', 'index.php?app={?app_short_name?}&amp;page=login_failed');
+
+// CFG: LOGIN-FAILED-LOGIN-RETRY-ACTION-URL
+$cfg->setConfigEntry('login_failed_login_retry_action_url', 'index.php?app={?app_short_name?}&amp;page=login&amp;note=login_failed');
+
+// CFG: LOGOUT-DONE-URL
+$cfg->setConfigEntry('logout_done_url', 'index.php?app={?app_short_name?}&amp;page=logout_done');
+
+// CFG: ACTION-STATUS-PROBLEM
+$cfg->setConfigEntry('action_status_problem', 'status_problem');
+
+// CFG: LOGIN-USER-STATUS-URL
+$cfg->setConfigEntry('login_user_status_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=status_problem&amp;status=general');
+
+// CFG: LOGIN-USER-STATUS-GUEST-URL
+$cfg->setConfigEntry('login_user_status_guest_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=status_problem&amp;status=guest');
+
+// CFG: USER-NOT-UNCONFIRMED-URL
+$cfg->setConfigEntry('user_not_unconfirmed_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=unconfirmed_problem');
+
+// CFG: USER-UNCONFIRMED-EMAIL-MISSING-URL
+$cfg->setConfigEntry('user_unconfirmed_email_missing_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=unconfirmed_email_missing');
+
+// CFG: CONFIRM-CODE-INVALID-URL
+$cfg->setConfigEntry('confirm_code_invalid_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=confirm_code_invalid');
+
+// CFG: USER-NOT-FOUND-URL
+$cfg->setConfigEntry('user_not_found_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=status_problem&amp;status=user_not_found');
+
+// CFG: LOGIN-GOVERNMENT-STARTUP-FAILED-URL
+$cfg->setConfigEntry('login_government_startup_failed_url', 'index.php?app={?app_short_name?}&amp;page=government_failed&amp;failed=startup');
+
+// CFG: LOGIN-GOVERNMENT-TRAINING-FAILED-URL
+$cfg->setConfigEntry('login_government_training_failed_url', 'index.php?app={?app_short_name?}&amp;page=government_failed&amp;failed=training');
+
+// CFG: REFILL-PAGE-CURRENCY-DONE-URL
+$cfg->setConfigEntry('refill_page_done_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=refill_done&amp;done={?refill_done?}&amount={?amount?}');
+
+// CFG: LOGIN-DEFAULT-ACTION
+$cfg->setConfigEntry('login_default_action', 'welcome');
+
+// CFG: LOGIN-AREA-LOGOUT-ACTION-URL
+$cfg->setConfigEntry('login_area_logout_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: GOVERNMENT-FAILED-LOGOUT-ACTION-URL
+$cfg->setConfigEntry('government_failed_logout_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: LOGIN-AREA-PROFILE-ACTION-URL
+$cfg->setConfigEntry('login_area_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=profile');
+
+// CFG: GOVERNMENT-FAILED-PROFILE-ACTION-URL
+$cfg->setConfigEntry('government_failed_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;status=profile');
+
+// CFG: LOGIN-AREA-COMPANY-ACTION-URL
+$cfg->setConfigEntry('login_area_company_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: GOVERNMENT-FAILED-COMPANY-ACTION-URL
+$cfg->setConfigEntry('government_failed_company_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: LOGIN-AREA-LIST-COMPANIES-ACTION-URL
+$cfg->setConfigEntry('login_area_list_companies_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: LOGIN-AREA-LOGOUT-NOW-ACTION-URL
+$cfg->setConfigEntry('login_area_logout_now_action_url', 'index.php?app={?app_short_name?}&amp;page=logout');
+
+// CFG: LOGIN-AREA-RETURN-LOGIN-ACTION-URL
+$cfg->setConfigEntry('login_area_return_login_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: LOGIN-AREA-SHIPSIMU-PROFILE-ACTION-URL
+$cfg->setConfigEntry('login_area_shipsimu_profile_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area&amp;action=profile');
+
+// CFG: LOGOUT_DONE-RELOGIN-ACTION-URL
+$cfg->setConfigEntry('logout_done_relogin_action_url', 'index.php?app={?app_short_name?}&amp;page=login');
+
+// CFG: LOGIN-REGISTER-ACTION-URL
+$cfg->setConfigEntry('login_register_action_url', 'index.php?app={?app_short_name?}&amp;page=register');
+
+// CFG: CONFIRM-DIRECT-LOGIN-ACTION-URL
+$cfg->setConfigEntry('confirm_direct_login_action_url', 'index.php?app={?app_short_name?}&amp;page=login_area');
+
+// CFG: WEB-CMD-USER-IS-NULL-URL
+$cfg->setConfigEntry('web_cmd_user_is_null_url', 'index.php?app={?app_short_name?}&amp;page=problem&amp;problem=user_null');
+
+// CFG: NEWS-READER-HOME-CLASS
+$cfg->setConfigEntry('news_reader_home_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-CLASS
+$cfg->setConfigEntry('news_reader_login_area_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-LOGOUT-CLASS
+$cfg->setConfigEntry('news_reader_login_area_logout_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-COMPANY-CLASS
+$cfg->setConfigEntry('news_reader_login_area_company_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-REFILL-CLASS
+$cfg->setConfigEntry('news_reader_login_area_refill_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-PROFILE-CLASS
+$cfg->setConfigEntry('news_reader_login_area_profile_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-GOVERNMENT-TRAINING-CLASS
+$cfg->setConfigEntry('news_reader_login_area_government_training_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-GOVERNMENT-STARTUP-HELP-CLASS
+$cfg->setConfigEntry('news_reader_login_area_government_startup_help_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-LOGIN-AREA-STATUS-PROBLEM-CLASS
+$cfg->setConfigEntry('news_reader_login_area_status_problem_class', 'DefaultNewsReader');
+
+// CFG: NEWS-READER-GOVERNMENT-FAILED-CLASS
+$cfg->setConfigEntry('news_reader_government_failed_class', 'DefaultNewsReader');
+
+// CFG: NEWS-DOWNLOAD-FILTER
+$cfg->setConfigEntry('news_download_filter', 'NewsDownloadFilter');
+
+// CFG: NEWS-PROCESS-FILTER
+$cfg->setConfigEntry('news_process_filter', 'NewsProcessFilter');
+
+// CFG: USER-AUTH-FILTER
+$cfg->setConfigEntry('user_auth_filter', 'UserAuthFilter');
+
+// CFG: USER-UPDATE-FILTER
+$cfg->setConfigEntry('user_update_filter', 'UserUpdateFilter');
+
+// CFG: USER-STATUS-CONFIRMED-FILTER
+$cfg->setConfigEntry('user_status_confirmed_filter', 'UserStatusConfimedUpdateFilter');
+
+// CFG: CAPTCHA-ENCRYPT-VALIDATOR-FILTER
+$cfg->setConfigEntry('captcha_encrypt_validator_filter', 'CaptchaEncryptFilter');
+
+// CFG: REFILL-REQUEST-VALIDATOR-FILTER
+$cfg->setConfigEntry('refill_request_validator_filter', 'RefillRequestValidatorFilter');
+
+// CFG: CAPTCHA-GUEST-VERIFIER-FILTER
+$cfg->setConfigEntry('captcha_guest_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CAPTCHA-USER-VERIFIER-FILTER
+$cfg->setConfigEntry('captcha_user_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CAPTCHA-REGISTER-VERIFIER-FILTER
+$cfg->setConfigEntry('captcha_register_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CAPTCHA-REFILL-VERFIER-FILTER
+$cfg->setConfigEntry('captcha_refill_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CAPTCHA-GOVERNMENT-VERFIER-FILTER
+$cfg->setConfigEntry('captcha_government_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CAPTCHA-PROFILE-VERFIER-FILTER
+$cfg->setConfigEntry('captcha_profile_verifier_filter', 'GraphicalCodeCaptchaVerifierFilter');
+
+// CFG: CONFIRM-CODE-VERIFIER-FILTER
+$cfg->setConfigEntry('confirm_code_verifier_filter', 'ConfirmCodeVerifierFilter');
+
+// CFG: BIRTHDAY-REGISTER-VERIFIER-FILTER
+$cfg->setConfigEntry('birthday_register_verifier_filter', 'BirthdayVerifierFilter');
+
+// CFG: BIRTHDAY-PROFILE-VERIFIER-FILTER
+$cfg->setConfigEntry('birthday_profile_verifier_filter', 'BirthdayVerifierFilter');
+
+// CFG: REFILL-PAGE-FILTER
+$cfg->setConfigEntry('refill_page_filter', 'RefillPageFilter');
+
+// CFG: REFILL-REQUEST-CURRENCY-BOOK-FILTER
+$cfg->setConfigEntry('refill_request_currency_test_book_filter', 'RefillRequestCurrencyTestBookFilter');
+
+// CFG: PAYMENT-DISCOVERY-FILTER
+$cfg->setConfigEntry('payment_discovery_filter', 'PaymentDiscoveryFilter');
+
+// CFG: GOVERNMENT-PAYS-TRAINING-FILTER
+$cfg->setConfigEntry('government_pays_training_filter', 'ShipSimuGovernmentPaysTrainingFilter');
+
+// CFG: GOVERNMENT-PAYS-STARTUP-HELP-FILTER
+$cfg->setConfigEntry('government_pays_startup_help_filter', 'ShipSimuGovernmentPaysStartupHelpFilter');
+
+// CFG: USER-STATUS-GUEST-FILTER
+$cfg->setConfigEntry('user_status_guest_filter', 'ShipSimuUserStatusGuestFilter');
+
+// CFG: NEWS-HOME-LIMIT
+$cfg->setConfigEntry('news_home_limit', 10);
+
+// CFG: NEWS-LOGIN-AREA-LIMIT
+$cfg->setConfigEntry('news_login_area_limit', 15);
+
+// CFG: NEWS-GOVERNMENT-FAILED-LIMIT
+$cfg->setConfigEntry('news_government_failed_limit', 15);
+
+// CFG: LOGIN-ENABLED
+$cfg->setConfigEntry('login_enabled', 'Y');
+
+// CFG: CONFIRM-EMAIL-ENABLED
+$cfg->setConfigEntry('confirm_email_enabled', 'Y');
+
+// CFG: LOGIN-DISABLED-REASON
+$cfg->setConfigEntry('login_disabled_reason', 'Loginbereich befindet sich noch im Aufbau.');
+
+// CFG: LOGIN-TYPE
+$cfg->setConfigEntry('login_type', 'username'); // username, email, both
+
+// CFG: EMAIL-CHANGE-ALLOWED
+$cfg->setConfigEntry('email_change_allowed', 'Y');
+
+// CFG: EMAIL-CHANGE-CONFIRMATION
+$cfg->setConfigEntry('email_change_confirmation', 'Y');
+
+// CFG: GUEST-LOGIN-ALLOWED
+$cfg->setConfigEntry('guest_login_allowed', 'Y');
+
+// CFG: GUEST-LOGIN-USERNAME
+$cfg->setConfigEntry('guest_login_user', 'guest');
+
+// CFG: GUEST-LOGIN-PASS
+$cfg->setConfigEntry('guest_login_passwd', 'guest');
+
+// CFG: LOGIN-WELCOME-ACTION-CLASS
+$cfg->setConfigEntry('login_welcome_action_class', 'ShipSimuLoginAction');
+
+// CFG: LOGIN-LOGOUT-ACTION-CLASS
+$cfg->setConfigEntry('login_logout_action_class', 'ShipSimuLogoutAction');
+
+// CFG: LOGIN-PROFILE-ACTION-CLASS
+$cfg->setConfigEntry('login_profile_action_class', 'ShipSimuProfileAction');
+
+// CFG: SHIPSIMU-REGISTER-CAPTCHA
+$cfg->setConfigEntry('shipsimu_register_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-USER-LOGIN-CAPTCHA
+$cfg->setConfigEntry('shipsimu_user_login_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-GUEST-LOGIN-CAPTCHA
+$cfg->setConfigEntry('shipsimu_guest_login_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-PROFILE-CAPTCHA
+$cfg->setConfigEntry('shipsimu_profile_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-REFILL-CAPTCHA
+$cfg->setConfigEntry('shipsimu_refill_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-GOVERNMENT-STARTUP-CAPTCHA
+$cfg->setConfigEntry('shipsimu_government_startup_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: SHIPSIMU-GOVERNMENT-TRAINING-CAPTCHA
+$cfg->setConfigEntry('shipsimu_government_training_captcha', 'GraphicalCodeCaptcha');
+
+// CFG: CAPTCHA-STRING-LENGTH
+$cfg->setConfigEntry('captcha_string_length', 5);
+
+// CFG: CAPTCHA-SEARCH-CHARS
+$cfg->setConfigEntry('captcha_search_chars', '+/=');
+
+// CFG: RANDOM-STRING-LENGTH
+$cfg->setConfigEntry('random_string_length', 100);
+
+// CFG: SHIPSIMU-REGISTER-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_register_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-USER-LOGIN-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_user_login_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-GUEST-LOGIN-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_guest_login_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-PROFILE-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_profile_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-REFILL-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_refill_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-GOVERNMENT-STARTUP-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_government_startup_captcha_secured', 'Y');
+
+// CFG: SHIPSIMU-GOVERNMENT-TRAINING-CAPTCHA-SECURED
+$cfg->setConfigEntry('shipsimu_government_training_captcha_secured', 'Y');
+
+// CFG: BLOCK-SHOWS-REGISTRATION
+$cfg->setConfigEntry('block_shows_registration', 'Y');
+
+// CFG: COMPANY-CLASS
+$cfg->setConfigEntry('company_class', 'ShippingCompany');
+
+// CFG: COMPANY-DB-WRAPPER-CLASS
+$cfg->setConfigEntry('company_db_wrapper_class', 'CompanyDatabaseWrapper');
+
+// CFG: USER-POINTS-DB-WRAPPER-CLASS
+$cfg->setConfigEntry('user_points_db_wrapper_class', 'UserPointsDatabaseWrapper');
+
+// CFG: USER-GOVERNMENT-WRAPPER-CLASS
+$cfg->setConfigEntry('user_gov_wrapper_class', 'UserGovernmentDatabaseWrapper');
+
+// CFG: PAYMENT-DB-WRAPPER-CLASS
+$cfg->setConfigEntry('payment_db_wrapper_class', 'PaymentsDatabaseWrapper');
+
+// CFG EMAIl-TPL-RESEND-LINK
+$cfg->setConfigEntry('email_tpl_resend_link', 'text');
+
+// CFG: MAIL-TEMPLATE-CLASS
+$cfg->setConfigEntry('mail_template_class', 'MailTemplateEngine');
+
+// CFG: IMAGE-TEMPLATE-CLASS
+$cfg->setConfigEntry('image_template_class', 'ImageTemplateEngine');
+
+// CFG: MENU-TEMPLATE-CLASS
+$cfg->setConfigEntry('menu_template_class', 'MenuTemplateEngine');
+
+// CFG: MENU-TEMPLATE-EXTENSION
+$cfg->setConfigEntry('menu_template_extension', '.xml');
+
+// CFG: ADMIN-EMAIL
+$cfg->setConfigEntry('admin_email', 'you@some-hoster.invalid');
+
+// CFG: USER-CLASS
+$cfg->setConfigEntry('user_class', 'ShipSimuMember');
+
+// CFG: GUEST-CLASS
+$cfg->setConfigEntry('guest_class', 'ShipSimuGuest');
+
+// CFG: MAX-ALLOWED-COMPANIES-FOUND
+$cfg->setConfigEntry('max_allowed_companies_found', 10);
+
+// CFG: FOUND-NEW-COMPANY-ACTION-POINTS
+$cfg->setConfigEntry('found_new_company_action_points', 1000000);
+
+// CFG: WRITE-APPLICATION-ACTION-POINTS
+$cfg->setConfigEntry('write_applications_action_points', 10000);
+
+// CFG: USER-POINTS-CLASS
+$cfg->setConfigEntry('user_points_class', 'UserPoints');
+
+// CFG: GOVERNMENT-CLASS
+$cfg->setConfigEntry('government_class', 'SimplifiedGovernment');
+
+// CFG: BANK-CLASS
+$cfg->setConfigEntry('bank_class', 'MoneyBank');
+
+// CFG: REFILL-PAGE-ACTIVE
+$cfg->setConfigEntry('refill_page_active', 'Y');
+
+// CFG: REFILL-PAGE-MIN-CURRENCY-AMOUNT
+$cfg->setConfigEntry('refill_page_min_currency_amount', 1000);
+
+// CFG: SHIP-SIMU-LOGIN-FILL-PAYMENT-DISCOVERY
+$cfg->setConfigEntry('ship_simu_login_refill_payment_discovery', 'LocalPaymentDiscovery');
+
+// CFG: GOVERNMENT-STARTUP-HELP-LIMIT
+$cfg->setConfigEntry('government_startup_help_limit', 3);
+
+// CFG: GOVERNMENT-TRAINING-LIMIT
+$cfg->setConfigEntry('government_training_limit', 2);
+
+// CFG: WEB-BLOCK-HELPER
+$cfg->setConfigEntry('web_block_helper', 'WebBlockHelper');
+
+// CFG: WEB-FORM-HELPER
+$cfg->setConfigEntry('web_form_helper', 'WebFormHelper');
+
+// CFG: WEB-LINK-HELPER
+$cfg->setConfigEntry('web_link_helper', 'WebLinkHelper');
+
+// CFG: WEB-CMD-GOVERNMENT-FAILED-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_government_failed_resolver_class', 'WebGovernmentFailedCommandResolver');
+
+// CFG: WEB-CMD-LOGIN-FAILED-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_login_failed_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-COMPANY-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_company_resolver_class', 'WebCompanyCommandResolver');
+
+// CFG: WEB-CMD-HOME-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_home_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-REGISTER-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_register_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-DO-FORM-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_do_form_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-LOGIN-AREA-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_login_area_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-CONFIRM-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_confirm_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-PROBLEM-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_problem_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-LOGOUT-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_logout_resolver_class', 'WebCommandResolver');
+
+// CFG: WEB-CMD-LOGOUT-DONE-RESOLVER-CLASS
+$cfg->setConfigEntry('web_cmd_logout_done_resolver_class', 'WebCommandResolver');
+
+// CFG: REFILL-REQUEST-CURRENCY-PAYMENT-TYPE
+$cfg->setConfigEntry('refill_request_currency_payment_type', 'test');
+
+// CFG: LOGIN-REGISTER-LOGIN-FORM
+$cfg->setConfigEntry('login_register_login_form', 'index.php?app={?app_short_name?}&amp;page=register');
+
+// CFG: HOME-MENU-CLASS
+$cfg->setConfigEntry('home_menu_class', 'ShipSimuHomeMenu');
+
+// CFG: LOGIN-FAILED-MENU-CLASS
+$cfg->setConfigEntry('login_failed_menu_class', 'ShipSimuLoginFailedMenu');
+
+// CFG: STATUS-MENU-CLASS
+$cfg->setConfigEntry('status_menu_class', 'ShipSimuStatusMenu');
+
+// CFG: LOGIN-MENU-CLASS
+$cfg->setConfigEntry('login_menu_class', 'ShipSimuLoginMenu');
+
+// CFG: LOGOUT-MENU-CLASS
+$cfg->setConfigEntry('logout_menu_class', 'ShipSimuLogoutMenu');
+
+// CFG: REGISTER-MENU-CLASS
+$cfg->setConfigEntry('register_menu_class', 'ShipSimuRegisterMenu');
+
+// CFG: CONFIRM-MENU-CLASS
+$cfg->setConfigEntry('confirm_menu_class', 'ShipSimuConfirmMenu');
+
+// CFG: LOGIN-AREA-MENU-CLASS
+$cfg->setConfigEntry('login_area_menu_class', 'ShipSimuLoginAreaMenu');
+
+// CFG: GOVERNMENT-FAILED-AREA-MENU-CLASS
+$cfg->setConfigEntry('government_failed_area_menu_class', 'ShipSimuGovernmentFailedAreaMenu');
+
+// CFG: MONEYBANK-ACTIVATED
+$cfg->setConfigEntry('moneybank_activated', 'Y');
+
+// CFG: MONEYBANK-OPENING-CLASS
+$cfg->setConfigEntry('moneybank_opening_class', 'MoneyBankRealtimeOpening');
+
+// [EOF]
+?>
diff --git a/application/shipsimu/data.php b/application/shipsimu/data.php
new file mode 100644 (file)
index 0000000..efbb161
--- /dev/null
@@ -0,0 +1,51 @@
+<?php
+/**
+ * Application data
+ *
+ * Please remember that this include file is being loaded *before* the class
+ * loader is loading classes from "exceptions", "interfaces" and "main"!
+ *
+ * You can prevent adding this application to the selector by uncommenting the
+ * following line:
+ *
+ * if ((isset($this)) && (is_object($this)) && ($this->isClass("ApplicationSelector"))) { return; }
+ *
+ * isset() is required to prevent a warning and is_object() is highly required
+ * when the application itself is requested in URL (hint: index.php?app=your_app)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Get config instance
+$cfg = FrameworkConfiguration::getSelfInstance();
+
+// Get an instance of the helper
+$app = call_user_func_array(
+       array($cfg->getConfigEntry('app_helper_class'), 'getSelfInstance'),
+       array()
+);
+
+// Set application name and version
+$app->setAppName('Ship-Simu Shipping Simulator');
+$app->setAppVersion('0.0.0');
+$app->setAppShortName('shipsimu');
+
+// [EOF]
+?>
diff --git a/application/shipsimu/debug.php b/application/shipsimu/debug.php
new file mode 100644 (file)
index 0000000..11bf631
--- /dev/null
@@ -0,0 +1,61 @@
+<?php
+/**
+ * Some debugging stuff for this application
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Reederei-Objekt debuggen
+//define('DEBUG_COMPANY_OBJ', true);
+// Hafen-Objekt debuggen
+//define('DEBUG_HARBOR_OBJ', true);
+// Schiff-Objekt debuggen
+//define('DEBUG_SHIP_OBJ', true);
+// Auftrag-Objekt debuggen
+//define('DEBUG_CONTRACT_OBJ', true);
+// Haendler-Objekt debuggen
+//define('DEBUG_MERCHANT_OBJ', true);
+// Personal-Objekt debuggen
+//define('DEBUG_PERSONELL_OBJ', true);
+// Personal debuggen
+//define('DEBUG_PERSONELL', true);
+// Reederei debuggen
+//define('DEBUG_COMPANY', true);
+// Mitarbeiter debuggen
+//define('DEBUG_COMPANY_EMPLOYEE', true);
+// Hafen debuggen
+//define('DEBUG_HARBOR', true);
+// Werft debuggen
+//define('DEBUG_SHIPYARD', true);
+// Schiff debuggen
+//define('DEBUG_SHIP', true);
+// Schiffstruktur debuggen
+//define('DEBUG_STRUCTURE', true);
+// Kabinen debuggen
+//define('DEBUG_CABIN', true);
+// Decks debuggen
+//define('DEBUG_DECK', true);
+// Bauauftraege debuggen
+//define('DEBUG_CONTRACT', true);
+// Haendler debuggen
+//define('DEBUG_MERCHANT', true);
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions.php b/application/shipsimu/exceptions.php
new file mode 100644 (file)
index 0000000..d9cc8d9
--- /dev/null
@@ -0,0 +1,85 @@
+<?php
+/**
+ * The exception handler for this application
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Our own exception handler
+function __exceptionHandler (FrameworkException $e) {
+       // Call the app_die() method
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> (<span class=\"app_short_name\">%s</span>) has terminated due to an uncaught exception: <span class=\"exception_name\">%s</span> <span class=\"exception_number\">[%s]</span>: <span class=\"debug_exception\">%s</span> Backtrace: <div class=\"debug_backtrace\">%s</div>",
+               ApplicationHelper::getSelfInstance()->getAppName(),
+               ApplicationHelper::getSelfInstance()->getAppShortName(),
+               $e->__toString(),
+               $e->getHexCode(),
+               $e->getMessage(),
+               $e->getPrintableBackTrace()
+       ),
+               $e->getHexCode(),
+               $e->getExtraData()
+       );
+} // END - function
+
+// Set the new handler
+set_exception_handler('__exceptionHandler');
+
+// Error handler
+function __errorHandler ($errno, $errstr, $errfile, $errline, array $errcontext) {
+       // Construct the message
+       $message = sprintf("File: <span class=\"debug_file\">%s</span>, Line: <span class=\"debug_line\">%s</span>, Code: <span class=\"debug_code\">%s</span>, Message: <span class=\"debug_message\">%s</span>",
+               basename($errfile),
+               $errline,
+               $errno,
+               $errstr
+       );
+
+       // Throw an exception here
+       throw new FatalErrorException($message, BaseFrameworkSystem::EXCEPTION_FATAL_ERROR);
+} // END - function
+
+// Set error handler
+set_error_handler('__errorHandler');
+
+// Assertion handler
+function __assertHandler ($file, $line, $code) {
+       // Empty code?
+       if ($code === "") $code = "<em>Unknown</em>";
+
+       // Create message
+       $message = sprintf("File: <span class=\"debug_file\">%s</span>, Line: <span class=\"debug_line\">%s</span>, Code: <span class=\"debug_code\">%s</span>",
+               basename($file),
+               $line,
+               $code
+       );
+
+       // Throw an exception here
+       throw new AssertionException($message, BaseFrameworkSystem::EXCEPTION_ASSERTION_FAILED);
+} // END - function
+
+// Init assert handling
+assert_options(ASSERT_ACTIVE,     1);
+assert_options(ASSERT_WARNING,    0);
+assert_options(ASSERT_BAIL,       0);
+assert_options(ASSERT_QUIET_EVAL, 0);
+assert_options(ASSERT_CALLBACK,   '__assertHandler');
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/.htaccess b/application/shipsimu/exceptions/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/exceptions/class_BirthdayInvalidException.php b/application/shipsimu/exceptions/class_BirthdayInvalidException.php
new file mode 100644 (file)
index 0000000..ed8e189
--- /dev/null
@@ -0,0 +1,42 @@
+<?php
+/**
+ * An exception for invalid birthdays (like 13-01-2008)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BirthdayInvalidException extends FrameworkException {
+       public function __construct (array $birthArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("Das Geburtsdatum <span class=\"exception_reason\">%s</span> ist leider falsch.",
+                       date("d.m.Y", mktime(
+                               0, 0, 0,
+                               $birthArray[1],
+                               $birthArray[2],
+                               $birthArray[0]
+                       ))
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_CabinShipMismatchException.php b/application/shipsimu/exceptions/class_CabinShipMismatchException.php
new file mode 100644 (file)
index 0000000..6b9120b
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception for cabins which doesn't match the ship (why?)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 CabinShipMismatchException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ContractAllreadySignedException.php b/application/shipsimu/exceptions/class_ContractAllreadySignedException.php
new file mode 100644 (file)
index 0000000..fc17f64
--- /dev/null
@@ -0,0 +1,39 @@
+<?php
+/**
+ * An exception thrown when the contract we want to sign is already signed
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ContractAllreadySignedException extends FrameworkException {
+       public function __construct (array $classArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Die Vertragsparteien <span class=\"exception_reason\">%s</span> und <span class=\"exception_reason\">%s</span> haben den Vertrag bereits unterzeichnet!",
+                       $classArray[0]->__toString(),
+                       $classArray[1]->getCompanyName(),
+                       $classArray[2]->getCompanyName()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ContractPartnerMismatchException.php b/application/shipsimu/exceptions/class_ContractPartnerMismatchException.php
new file mode 100644 (file)
index 0000000..fce9748
--- /dev/null
@@ -0,0 +1,39 @@
+<?php
+/**
+ * An exception thrown when the contract partner did not match the excepted one
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ContractPartnerMismatchException extends FrameworkException {
+       public function __construct (array $classArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Der Vertragspartner von <span class=\"exception_reason\">%s</span> ist ung&uuml;tig (<span class=\"exception_reason\">%s</span>) und darf diesen Vertrag nicht unterzeichnen!",
+                       $classArray[0]->__toString(),
+                       $classArray[1]->getCompanyName(),
+                       $classArray[2]->getCompanyName()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_DeckShipMismatchException.php b/application/shipsimu/exceptions/class_DeckShipMismatchException.php
new file mode 100644 (file)
index 0000000..937cd6e
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception thrown when the deck mismatches the ship (why?)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 DeckShipMismatchException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_EmptyStructuresListException.php b/application/shipsimu/exceptions/class_EmptyStructuresListException.php
new file mode 100644 (file)
index 0000000..9c1eee2
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the structure list is empty
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 EmptyStructuresListException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Die Strukturen-Liste ist leer.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_InvalidContractPartnerException.php b/application/shipsimu/exceptions/class_InvalidContractPartnerException.php
new file mode 100644 (file)
index 0000000..8f4823e
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the contract partner is invalid
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 InvalidContractPartnerException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Kein g&uuml;tiger Vertragspartner.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_InvalidIDFormatException.php b/application/shipsimu/exceptions/class_InvalidIDFormatException.php
new file mode 100644 (file)
index 0000000..78e2e00
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the format of the id number is invalid
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 InvalidIDFormatException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Ung&uuml;ltige ID-Nummer &uuml;bergeben.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ItemNotInPriceListException.php b/application/shipsimu/exceptions/class_ItemNotInPriceListException.php
new file mode 100644 (file)
index 0000000..0013e92
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the requested item is not in pricing list
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 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 class=\"exception_reason\">%s</span> nicht gefunden.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ItemNotTradeableException.php b/application/shipsimu/exceptions/class_ItemNotTradeableException.php
new file mode 100644 (file)
index 0000000..074f17e
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when an item is not tradeable (maybe unneccessary)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ItemNotTradeableException extends FrameworkException {
+       public function __construct (array $classArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Object not tradeable.",
+                       $classArray[0]->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_MissingSimulatorIdException.php b/application/shipsimu/exceptions/class_MissingSimulatorIdException.php
new file mode 100644 (file)
index 0000000..09a55f3
--- /dev/null
@@ -0,0 +1,38 @@
+<?php
+/**
+ * An exception thrown when the provided simulator id is invalid
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 MissingSimulatorIdException extends FrameworkException {
+       public function __construct (array $classArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Die Simulator-ID <span class=\"exception_reason\">%s</span> scheint ung&uuml;ltig zu sein.",
+                       $classArray[0]->__toString(),
+                       $classArray[1]
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_MotorShipMismatchException.php b/application/shipsimu/exceptions/class_MotorShipMismatchException.php
new file mode 100644 (file)
index 0000000..7e688c2
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception thrown when the motor does not match the ship (why?)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 MotorShipMismatchException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_NoShippingCompanyOwnedException.php b/application/shipsimu/exceptions/class_NoShippingCompanyOwnedException.php
new file mode 100644 (file)
index 0000000..848362e
--- /dev/null
@@ -0,0 +1,46 @@
+<?php
+/**
+ * An exception thrown when a user owns no shipping companies
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 NoShippingCompanyOwnedException extends FrameworkException {
+       /**
+        * Constructor of this exception
+        *
+        * @param       $msgArray       Message array with exception data
+        * @param       $code           Exception code
+        * @return      void
+        */
+       public function __construct (array $msgArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:%d] Current user (class <span class=\"exception_reason\">%s</span>) does not own any shipping companies.",
+                       $msgArray[0]->__toString(),
+                       $this->getLine(),
+                       $msgArray[1]->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_NoShipyardsConstructedException.php b/application/shipsimu/exceptions/class_NoShipyardsConstructedException.php
new file mode 100644 (file)
index 0000000..52cf913
--- /dev/null
@@ -0,0 +1,41 @@
+<?php
+/**
+ * An exception thrown when there are no shipyards constructed yet.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 NoShipyardsConstructedException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // No class given
+               $message = sprintf("Please provide a class for <span class=\"exception_reason\">%s</span>", __CLASS__);
+               if (is_object($class)) {
+                       // Add a message around the missing class
+                       $message = sprintf("[%s:] Keine Werften gefunden!",
+                               $class->__toString()
+                       );
+               } // END - if
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_PersonellListAlreadyCreatedException.php b/application/shipsimu/exceptions/class_PersonellListAlreadyCreatedException.php
new file mode 100644 (file)
index 0000000..c89dc44
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when a crew list has already been initialized
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 PersonellListAlreadyCreatedException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Die interne Crew-Liste wurde bereits initialisiert.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_RoomShipMismatchException.php b/application/shipsimu/exceptions/class_RoomShipMismatchException.php
new file mode 100644 (file)
index 0000000..d84528c
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception thrown when a room mismatches the ship (why?)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 RoomShipMismatchException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ShipNotConstructedException.php b/application/shipsimu/exceptions/class_ShipNotConstructedException.php
new file mode 100644 (file)
index 0000000..3313c36
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception thrown when a ship is not constructed (yet)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipNotConstructedException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ShipPartNotConstructableException.php b/application/shipsimu/exceptions/class_ShipPartNotConstructableException.php
new file mode 100644 (file)
index 0000000..48b4fe7
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the ship part is not constructed yet.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipPartNotConstructableException extends FrameworkException {
+       public function __construct (array $partArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("Schiffteil <span class=\"exception_reason\">%s</span> ist nicht constrierbar!",
+                       $partArray[0]
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_StructureShipMismatchException.php b/application/shipsimu/exceptions/class_StructureShipMismatchException.php
new file mode 100644 (file)
index 0000000..62152e8
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An exception thrown when a structure does not match the ship (why?)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 StructureShipMismatchException extends FrameworkException {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_StructuresOutOfBoundsException.php b/application/shipsimu/exceptions/class_StructuresOutOfBoundsException.php
new file mode 100644 (file)
index 0000000..916207f
--- /dev/null
@@ -0,0 +1,35 @@
+<?php
+/**
+ * An exception thrown when the ship part index is out of bounds
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 StructuresOutOfBoundsException extends FrameworkException {
+       public function __construct ($idx, $code) {
+               // Add a message around the missing class
+               $message = sprintf("Der Index <span class=\"exception_reason\">%s</span> liegt ausserhalb des g&uuml;tigen Bereiches! Schiffsteil nicht auffindbar.", $idx);
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_ToMuchEmployeesException.php b/application/shipsimu/exceptions/class_ToMuchEmployeesException.php
new file mode 100644 (file)
index 0000000..a6bffb0
--- /dev/null
@@ -0,0 +1,38 @@
+<?php
+/**
+ * An exception thrown when to less people are unemployed and cannot be recruited
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ToMuchEmployeesException extends FrameworkException {
+       public function __construct (array $amountArray, $code) {
+               // Add a message around the missing class
+               $message = sprintf("<u>%d</u> Leute nicht einstellbar, da nur <u>%d</u> arbeitslos sind!",
+                       $amountArray[0],
+                       $amountArray[1]
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_TotalPriceNotCalculatedException.php b/application/shipsimu/exceptions/class_TotalPriceNotCalculatedException.php
new file mode 100644 (file)
index 0000000..7aa57ae
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * An exception thrown when the total price was not calculated
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 TotalPriceNotCalculatedException extends FrameworkException {
+       public function __construct (FrameworkInterface $class, $code) {
+               // Add a message around the missing class
+               $message = sprintf("[%s:] Gesamtpreis ist nicht ermittelbar.",
+                       $class->__toString()
+               );
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_UnsupportedLimitationPartException.php b/application/shipsimu/exceptions/class_UnsupportedLimitationPartException.php
new file mode 100644 (file)
index 0000000..ee7aa5a
--- /dev/null
@@ -0,0 +1,35 @@
+<?php
+/**
+ * An exception thrown when the limitation type is not supported
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 UnsupportedLimitationPartException extends FrameworkException {
+       public function __construct ($str, $code) {
+               // Add a message around the missing class
+               $message = sprintf("Limitierungsinformation <span class=\"exception_reason\">%s</span> wird derzeit nicht unterst&uuml;tzt.", $str);
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/exceptions/class_WrongGenderSpecifiedException.php b/application/shipsimu/exceptions/class_WrongGenderSpecifiedException.php
new file mode 100644 (file)
index 0000000..306a680
--- /dev/null
@@ -0,0 +1,35 @@
+<?php
+/**
+ * An exception thrown when a wrong gender was specified
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WrongGenderSpecifiedException extends FrameworkException {
+       public function __construct ($gender, $code) {
+               // Add a message around the missing class
+               $message = sprintf("Das Geschlecht <span class=\"exception_reason\">%s</span> Ist nicht <em>M</em> (M&auml;nnlich) oder <em>F</em> (Weiblich).", $gender);
+
+               // Call parent constructor
+               parent::__construct($message, $code);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/init.php b/application/shipsimu/init.php
new file mode 100644 (file)
index 0000000..d27a1f5
--- /dev/null
@@ -0,0 +1,47 @@
+<?php
+/**
+ * Application initializer
+ *
+ * Please remember that this include file is being loaded *before* the class
+ * loader is loading classes from "exceptions", "interfaces" and "main"!
+ *
+ * You can prevent adding this application to the selector by uncommenting the
+ * following line:
+ *
+ * if ((isset($this)) && (is_object($this)) && ($this->isClass("ApplicationSelector"))) { return; }
+ *
+ * isset() is required to prevent a warning and is_object() is highly required
+ * when the application itself is requested in URL (hint: index.php?app=your_app)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Get config instance
+$cfg = FrameworkConfiguration::getSelfInstance();
+
+// Initialize output system
+require($cfg->getConfigEntry('base_path') . 'inc/output.php');
+
+// This application needs a database connection then we have to simply include
+// the inc/database.php script
+require($cfg->getConfigEntry('base_path') . 'inc/database.php');
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/.htaccess b/application/shipsimu/interfaces/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/interfaces/class_BookableAccount.php b/application/shipsimu/interfaces/class_BookableAccount.php
new file mode 100644 (file)
index 0000000..3f3a575
--- /dev/null
@@ -0,0 +1,36 @@
+<?php
+/**
+ * An interface for bookable user accounts
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface BookableAccount extends FrameworkInterface {
+       /**
+        * Books the given 'amount' in the request instance on the users "points
+        * account"
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @return      void
+        */
+       function bookAmountDirectly (Requestable $requestInstance);
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_ConstructableShip.php b/application/shipsimu/interfaces/class_ConstructableShip.php
new file mode 100644 (file)
index 0000000..db76fd5
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An interface for constructable ships
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface ConstructableShip extends FrameworkInterface {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_ConstructableShipPart.php b/application/shipsimu/interfaces/class_ConstructableShipPart.php
new file mode 100644 (file)
index 0000000..8135bc3
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * An interface for constructable ship parts
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface ConstructableShipPart extends FrameworkInterface {
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_ContractPartner.php b/application/shipsimu/interfaces/class_ContractPartner.php
new file mode 100644 (file)
index 0000000..35b4b6d
--- /dev/null
@@ -0,0 +1,36 @@
+<?php
+/**
+ * An interface for contract partners
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface ContractPartner extends FrameworkInterface {
+       /**
+        * This is a contract partner
+        *
+        * @param       $contractInstance       Must be a valid instance of WorksContract
+        * @return      boolean                 true  = can be a contract partner,
+        *                                                      false = no partner for contracts
+        */
+       function isContractPartner (SignableContract $contractInstance);
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_Customer.php b/application/shipsimu/interfaces/class_Customer.php
new file mode 100644 (file)
index 0000000..5de5210
--- /dev/null
@@ -0,0 +1,55 @@
+<?php
+/**
+ * An interface for all customers
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface Customer extends FrameworkInterface {
+       /**
+        * Adds a contract to the customer's list
+        *
+        * @param       $contractInstance       A valid instance to WorksContract
+        * @return      void
+        */
+       function addNewWorksContract (SignableContract $contractInstance);
+
+       /**
+        * Signs a works contract.
+        *
+        * @param       $contractInstance       A valid instance to WorksContract
+        * @param       $partnerInstance        An instance the other contract partner
+        * @return      void
+        * @throws      InvalidContractPartnerException         If the in $contractInstance
+        *                                                                              set contract partner is
+        *                                                                              not the expected
+        */
+       function signContract (SignableContract $contractInstance, ContractPartner $partnerInstance);
+
+       /**
+        * Withdraw from a signed contract
+        *
+        * @param       $contractInstance       A valid instance to WorksContract
+        * @return      void
+        */
+       function withdrawFromContract (SignableContract $contractInstance);
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_Personellizer.php b/application/shipsimu/interfaces/class_Personellizer.php
new file mode 100644 (file)
index 0000000..b56df14
--- /dev/null
@@ -0,0 +1,200 @@
+<?php
+/**
+ * An interface for all personells
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface Personellizer extends FrameworkInterface {
+         ///////////////////////
+        /// General methods ///
+       ///////////////////////
+
+       /**
+        * Remove min/max age
+        *
+        * @return      void
+        */
+       function removeMinMaxAge ();
+
+       /**
+        * Create a valid birthday
+        *
+        * @return void
+        */
+       function createBirthday ();
+
+       /**
+        * Verify if given year/month/day is a valid date combination
+        *
+        * @param               $year   4-digit year (valid  : 2007, 1946,
+        *                                                    invalid: 24, 2a, aa)
+        * @param               $month  1 to 2-digit month (range: 1 to 12)
+        * @param               $day            1 to 2-digit day (range: 1 to 31/30/29/28)
+        * @return      boolean true  = date is valid,
+        *                                      false = date is invalid
+        */
+       function isDateValid ($year, $month, $day);
+
+               /////////////////////////
+        //// Status requests ////
+       /////////////////////////
+
+       /**
+        * Is the person employed?
+        *
+        * @return      boolean true  = person is employed
+        *                                      false = person is umemployed
+        */
+       function isEmployed ();
+
+       /**
+        * Is the person married? (to which one doesn't matter here)
+        *
+        * @return      boolean true  = person is married
+        *                                      false = person is not married
+        */
+       function isMarried ();
+
+       /**
+        * Is the person a male?
+        *
+        * @return      boolean true  = person is male
+        *                                      false = person is not male (maybe female? ;-))
+        */
+       function isMale ();
+
+       /**
+        * Is the person a female?
+        *
+        * @return      boolean true  = person is female
+        *                                      false = person is not female (maybe male? ;-))
+        */
+       function isFemale ();
+
+               /////////////////
+        //// Getters ////
+       /////////////////
+
+       /**
+        * Getter for surname
+        *
+        * @return      $surname        The person's surname
+        */
+       function getSurname ();
+
+       /**
+        * Getter for family name
+        *
+        * @return      $family The person's family name
+        */
+       function getFamily ();
+
+       /**
+        * Getter for gender
+        *
+        * @return      $gender The person's gender (F/M)
+        */
+       function getGender ();
+
+       /**
+        * Getter for salary
+        *
+        * @return      $salary The person's current salary
+        */
+       function getSalary ();
+
+               /////////////////
+        //// Setters ////
+       /////////////////
+
+       /**
+        * Setter for surname
+        *
+        * @param               $surname        The person's new surname as a string
+        * @return      void
+        */
+       function setSurname ($surname);
+
+       /**
+        * Setter for family name
+        *
+        * @param               $family The person's new family name as a string
+        * @return      void
+        */
+       function setFamily ($family);
+
+       /**
+        * Setter for gender. Do not use this so often... ;-)
+        * This method shall only be used when the person is "created"
+        *
+        * @param               $gender The person's new gender as a 1-char string (M/F)
+        * @return      void
+        */
+       function setGender ($gender);
+
+       /**
+        * Setter for employment status
+        *
+        * @param               $employed       The person's new employment stats
+        * @return      void
+        */
+       function setEmployed ($employed);
+
+       /**
+        * Setter for marrital status
+        *
+        * @param               $married        The person's new marrital status
+        * @return      void
+        */
+       function setMarried ($married);
+
+       /**
+        * Setter for a already validated birthday.
+        *
+        * @param               $year   The person's new year-of-birth (4 digits)
+        * @param               $month  The person's new month-of-birth (1 to 2 digits)
+        * @param               $day            The person's new day-of-birth (1 to 2 digits)
+        * @return      void
+        */
+       function setBirthday ($year, $month, $day);
+
+               /////////////////////////////////////
+        //// Methods for changing salary ////
+       /////////////////////////////////////
+
+       /**
+        * Increase person's salary by a specified amount
+        *
+        * @param               $add            Add this float amount to current salary
+        * @return      void
+        */
+       function increaseSalary ($add);
+
+       /**
+        * Decrease person's salary by a specified amount
+        *
+        * @param               $sub            Subtract this float amount to current salary
+        * @return      void
+        */
+       function decreaseSalary ($sub);
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/interfaces/class_SignableContract.php b/application/shipsimu/interfaces/class_SignableContract.php
new file mode 100644 (file)
index 0000000..a8f62ce
--- /dev/null
@@ -0,0 +1,30 @@
+<?php
+/**
+ * An interface for signable contracts
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface SignableContract extends FrameworkInterface {
+       // Sign the contract
+       function signContract (ContractPartner $partnerInstance, ContractPartner $partyInstance);
+}
+
+// [EOF]
+?>
\ No newline at end of file
diff --git a/application/shipsimu/interfaces/class_TradeableItem.php b/application/shipsimu/interfaces/class_TradeableItem.php
new file mode 100644 (file)
index 0000000..f850be2
--- /dev/null
@@ -0,0 +1,35 @@
+<?php
+/**
+ * An interface for tradeable items
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+interface TradeableItem extends FrameworkInterface {
+       /**
+        * Is this item (=object) tradeable?
+        *
+        * @return      boolean true  = is a tradeable object,
+        *                                      false = is not tradeable
+        */
+       function isTradeable ();
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/loader.php b/application/shipsimu/loader.php
new file mode 100644 (file)
index 0000000..d28600b
--- /dev/null
@@ -0,0 +1,39 @@
+<?php
+/**
+ * A specialized class loader for this class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Get config instance
+$cfg = FrameworkConfiguration::getSelfInstance();
+
+// Load all classes for the application
+foreach ($lowerClasses as $className) {
+       // Load the application classes
+       ClassLoader::getSelfInstance()->scanClassPath(sprintf("%s/%s/%s", $cfg->getConfigEntry('application_path'), $cfg->getConfigEntry('app_name'), $className));
+} // END - if
+
+// Clean up the global namespace
+unset($lowerClasses);
+unset($className);
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/.htaccess b/application/shipsimu/main/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/actions/.htaccess b/application/shipsimu/main/actions/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/actions/class_ b/application/shipsimu/main/actions/class_
new file mode 100644 (file)
index 0000000..d84fab7
--- /dev/null
@@ -0,0 +1,82 @@
+<?php
+/**
+ * 
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 ???Action extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public final static function create???Action (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new ???Action();
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here
+               $this->partialStub("You have to implement me.");
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Call parent addExtraFilters method
+               parent::addExtraFilters($controllerInstance, $requestInstance);
+
+               // Unfinished method
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/class_BaseShipSimuAction.php b/application/shipsimu/main/actions/class_BaseShipSimuAction.php
new file mode 100644 (file)
index 0000000..41dcce0
--- /dev/null
@@ -0,0 +1,62 @@
+<?php
+/**
+ * A general action class for blog
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseShipSimuAction extends BaseAction {
+       /**
+        * Protected constructor
+        *
+        * @param       $className      Name of the class
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       protected function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Add code here executed with every action
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Unfinished method
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/ship-simu/.htaccess b/application/shipsimu/main/actions/ship-simu/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/actions/ship-simu/class_ShipSimuLoginAction.php b/application/shipsimu/main/actions/ship-simu/class_ShipSimuLoginAction.php
new file mode 100644 (file)
index 0000000..2fbee37
--- /dev/null
@@ -0,0 +1,65 @@
+<?php
+/**
+ * An action class for the login welcome page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLoginAction extends BaseShipSimuAction implements PerformableAction {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createShipSimuLoginAction () {
+               // Get a new instance
+               $actionInstance = new ShipSimuLoginAction();
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Maybe we need to do something later here
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/ship-simu/class_ShipSimuProfileAction.php b/application/shipsimu/main/actions/ship-simu/class_ShipSimuProfileAction.php
new file mode 100644 (file)
index 0000000..56090bf
--- /dev/null
@@ -0,0 +1,65 @@
+<?php
+/**
+ * An action class for the profile page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuProfileAction extends BaseShipSimuAction implements PerformableAction {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createShipSimuProfileAction () {
+               // Get a new instance
+               $actionInstance = new ShipSimuProfileAction();
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Maybe we need to do something later here
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/.htaccess b/application/shipsimu/main/actions/web/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLogin b/application/shipsimu/main/actions/web/class_WebShipSimuLogin
new file mode 100644 (file)
index 0000000..d60f442
--- /dev/null
@@ -0,0 +1,82 @@
+<?php
+/**
+ * An action for 
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 WebShipSimuLogin???Action extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public final static function createWebShipSimuLogin???Action (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLogin???Action();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute parent method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginCompanyAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginCompanyAction.php
new file mode 100644 (file)
index 0000000..842d6cb
--- /dev/null
@@ -0,0 +1,82 @@
+<?php
+/**
+ * An action for shipping company page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginCompanyAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginCompanyAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginCompanyAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Maybe add fetching company list of current user here?
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some more filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentStartupHelpAction.php
new file mode 100644 (file)
index 0000000..fa62481
--- /dev/null
@@ -0,0 +1,85 @@
+<?php
+/**
+ * An action for government startup help form
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginGovernmentStartupHelpAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginGovernmentStartupHelpAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginGovernmentStartupHelpAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Check if government can pay startup help
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_startup_help_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginGovernmentTrainingAction.php
new file mode 100644 (file)
index 0000000..fcbc711
--- /dev/null
@@ -0,0 +1,85 @@
+<?php
+/**
+ * An action for trainings payed by government
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginGovernmentTrainingAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginGovernmentTrainingAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginGovernmentTrainingAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some more filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Check if government can pay a training
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_training_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginLogoutAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginLogoutAction.php
new file mode 100644 (file)
index 0000000..9b066a9
--- /dev/null
@@ -0,0 +1,81 @@
+<?php
+/**
+ * An action for logout
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginLogoutAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginLogoutAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginLogoutAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginProfileAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginProfileAction.php
new file mode 100644 (file)
index 0000000..58d6745
--- /dev/null
@@ -0,0 +1,82 @@
+<?php
+/**
+ * An action for profile (editing) page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginProfileAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginProfileAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginProfileAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginRefillAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginRefillAction.php
new file mode 100644 (file)
index 0000000..31c7337
--- /dev/null
@@ -0,0 +1,87 @@
+<?php
+/**
+ * An action for money refill page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginRefillAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginRefillAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginRefillAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Is the refill page active?
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_page_filter'));
+
+               // Add payment discovery filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('payment_discovery_filter', array($this)));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginStatusProblemAction.php
new file mode 100644 (file)
index 0000000..8b26b8f
--- /dev/null
@@ -0,0 +1,82 @@
+<?php
+/**
+ * An action for 
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginStatusProblemAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginStatusProblemAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginStatusProblemAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Check for user status by default
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php b/application/shipsimu/main/actions/web/class_WebShipSimuLoginWelcomeAction.php
new file mode 100644 (file)
index 0000000..d839bd1
--- /dev/null
@@ -0,0 +1,81 @@
+<?php
+/**
+ * An action for the welcome page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuLoginWelcomeAction extends BaseShipSimuAction implements Commandable, Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this action
+        *
+        * @param       $resolverInstance       An instance of an action resolver
+        * @return      $actionInstance         An instance of this action class
+        */
+       public static final function createWebShipSimuLoginWelcomeAction (ActionResolver $resolverInstance) {
+               // Get a new instance
+               $actionInstance = new WebShipSimuLoginWelcomeAction();
+
+               // Set the resolver instance
+               $actionInstance->setResolverInstance($resolverInstance);
+
+               // Return the instance
+               return $actionInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Call parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Add your code here...
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some filters here
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Unfinished method
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/bank/.htaccess b/application/shipsimu/main/bank/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/bank/class_BaseBank.php b/application/shipsimu/main/bank/class_BaseBank.php
new file mode 100644 (file)
index 0000000..21ae0d5
--- /dev/null
@@ -0,0 +1,60 @@
+<?php
+/**
+ * A general bank class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.org
+ * @todo               Find an instance for all banks and move the abstract functions there
+ *
+ * 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/>.
+ */
+abstract class BaseBank extends BaseFrameworkSystem {
+       /**
+        * Protected constructor
+        *
+        * @param       $className      The class' real name
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Checks wether the bank lends more money to the current user
+        *
+        * @return      $lendsMoreMoney         Wether this bank lends more money to the user
+        */
+       public abstract function ifBankLendsMoreMoney ();
+
+       /**
+        * Checks wethert the current user has maximum allowed credits with this bank
+        *
+        * @return      $hasMaximumCredits      Wether the user has maximum allowed credits
+        */
+       public abstract function ifUserHasMaxCredits ();
+
+       /**
+        * Checks wether this money bank has opened
+        *
+        * @return      $hasOpened      Wether this money bank has opened
+        */
+       public abstract function ifMoneyBankHasOpened ();
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/bank/money/class_MoneyBank.php b/application/shipsimu/main/bank/money/class_MoneyBank.php
new file mode 100644 (file)
index 0000000..11d4d9e
--- /dev/null
@@ -0,0 +1,94 @@
+<?php
+/**
+ * A money bank which may lend points to the user
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 MoneyBank extends BaseBank implements Registerable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this money bank class
+        *
+        * @param       $userInstance   A class instance of a user object
+        * @return      $bankInstance   An instance of this class
+        */
+       public static final function createMoneyBank (ManageableAccount $userInstance) {
+               // Get a new instance
+               $moneyInstance = new MoneyBank();
+
+               // Set the user instance
+               $moneyInstance->setUserInstance($userInstance);
+
+               // Return the prepared instance
+               return $moneyInstance;
+       }
+
+       /**
+        * Checks wether the bank lends more money to the current user
+        *
+        * @return      $lendsMoreMoney         Wether this bank lends more money to the user
+        */
+       public function ifBankLendsMoreMoney () {
+               $this->partialStub();
+       }
+
+       /**
+        * Checks wethert the current user has maximum allowed credits with this bank
+        *
+        * @return      $hasMaximumCredits      Wether the user has maximum allowed credits
+        */
+       public function ifUserHasMaxCredits () {
+               $this->partialStub();
+       }
+
+       /**
+        * Checks wether this money bank has opened
+        *
+        * @return      $hasOpened      Wether this money bank has opened
+        */
+       public function ifMoneyBankHasOpened () {
+               // Has not opened by default
+               $hasOpened = false;
+
+               // Is the money bank activated in config?
+               if ($this->getConfigInstance()->getConfigEntry('moneybank_activated')) {
+                       // Okay, does the user ask within the opening times? To find this out we need a OpeningTimes class
+                       $openingInstance = ObjectFactory::createObjectByConfiguredName('moneybank_opening_class', array($this));
+
+                       // Then we simply "ask" the opening time instance if the user asks within the opening time
+                       $hasOpened = $openingInstance->ifWithinOpeningTimes();
+               } // END - if
+
+               // Return status
+               return $hasOpened;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/class_ b/application/shipsimu/main/class_
new file mode 100644 (file)
index 0000000..956f6c5
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * 
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 ??? extends BaseFrameworkSystem {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this money bank class
+        *
+        * @return      $???Instance    An instance of this class
+        */
+       public final static function create??? () {
+               // Get a new instance
+               $???Instance = new ???();
+
+               // Return the prepared instance
+               return $???Instance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/class_BasePersonell.php b/application/shipsimu/main/class_BasePersonell.php
new file mode 100644 (file)
index 0000000..8e08ec3
--- /dev/null
@@ -0,0 +1,246 @@
+<?php
+/**
+ * A general class for personell
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BasePersonell extends BaseFrameworkSystem implements Personellizer {
+       // Maximum/minimum age
+       private $MIN_AGE = 21;
+       private $MAX_AGE = 40;
+
+       // Male/female
+       private $gender     = ""; // M=Male, F=Female, empty=uninitialized
+
+       // Year/month/day of birth
+       private $yearBirth  = 0;
+       private $monthBirth = 0;
+       private $dayBirth   = 0;
+
+       // Surname/family name
+       private $surname    = "";
+       private $family     = "";
+
+       // Employed?
+       private $employed   = false;
+
+       // Married?
+       private $married    = false;
+
+       // Her/his salary
+       private $salary     = 0.00;
+
+       // Constructor
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Remove min/max ages
+       public final function removeMinMaxAge () {
+               unset($this->MIN_AGE);
+               unset($this->MAX_AGE);
+       }
+
+       // Generates a birthday based on MAX_AGE/MIN_AGE and the current date
+       public final function createBirthday () {
+               // Is the birthday already set?
+               if ($this->isDateValid($this->yearBirth, $this->monthBirth, $this->dayBirth)) return false;
+
+               // Get current year
+               $currYear = date("Y", time());
+
+               // Generate random year/month/day
+               $year = mt_rand(($currYear - $this->MIN_AGE), ($currYear - $this->MAX_AGE));
+               $month = 0;
+               $day = 0;
+               while ($this->isDateValid($year, $month, $day) === false) {
+                       $month = mt_rand(1, 12);
+                       switch ($month) {
+                       case 1:
+                       case 3:
+                       case 5:
+                       case 7:
+                       case 8:
+                       case 10:
+                       case 12:
+                               $day   = mt_rand(1, 31);
+                               break;
+
+                       case 4:
+                       case 6:
+                       case 9:
+                       case 11:
+                               $day   = mt_rand(1, 30);
+                               break;
+
+                       case 2: // February
+                               if ($year % 4 == 0) {
+                                       // Is a "Schaltjahr"
+                                       $day = mt_rand(1, 29);
+                               } else {
+                                       // Regular year
+                                       $day = mt_rand(1, 28);
+                               }
+                               break;
+                       } // END - switch
+               } // END - while
+
+               // Set the new birthday
+               $this->setBirthday($year, $month, $day);
+       }
+
+       // Is the current day valid?
+       public final function isDateValid ($year, $month, $day) {
+               // Create timestamp
+               $stamp = mktime(0, 0, 0, $month, $day, $year);
+
+               // Get year/month/day back
+               $y = date("Y", $stamp);
+               $m = date("m", $stamp);
+               $d = date("d", $stamp);
+
+               // Compare all
+               return (($y == $year) && ($m == $month) && ($d == $day));
+       }
+
+       // Employed?
+       public final function isEmployed () {
+               return $this->employed;
+       }
+
+       // Married?
+       public final function isMarried () {
+               return $this->married;
+       }
+
+       // Male?
+       public final function isMale () {
+               return ($this->gender == "M");
+       }
+
+       // Female
+       public final function isFemale () {
+               return ($this->gender == "F");
+       }
+
+       // Setter for surname
+       public final function setSurname ($surname) {
+               $this->surname = (string) $surname;
+       }
+
+       // Getter for surname
+       public function getSurname () {
+               return $this->surname;
+       }
+
+       // Setter for family name
+       public final function setFamily ($family) {
+               $this->family = (string) $family;
+       }
+
+       // Getter for family name
+       public final function getFamily () {
+               return $this->family;
+       }
+
+       // Setter for gender
+       public final function setGender ($gender) {
+               // Set random gender here
+               if (($gender == "M") || ($gender == "F") || ((empty($gender)) && ($this->getSurname() == ""))) {
+                       $this->gender = $gender;
+               } else {
+                       throw new WrongGenderSpecifiedException($gender, self::EXCEPTION_GENDER_IS_WRONG);
+               }
+       }
+
+       // Getter for gender
+       public final function getGender () {
+               return $this->gender;
+       }
+
+       // Setter for employment status
+       public final function setEmployed ($employed) {
+               $this->employed = (boolean) $employed;
+       }
+
+       // Setter for marriage status
+       public final function setMarried ($married) {
+               $this->married = (boolean) $married;
+       }
+
+       // Getter for salary
+       public final function getSalary () {
+               return $this->salary;
+       }
+
+       // Increase salary
+       public final function increaseSalary ($add) {
+               $this->salary += (float) abs($add);
+       }
+
+       // Decrease salary
+       public final function decreaseSalary ($sub) {
+               $this->salary -= (float) abs($sub);
+       }
+
+       // Setter for birthday
+       public final function setBirthday ($year, $month, $day) {
+               $this->yearBirth  = (int) abs($year);
+               $this->monthBirth = (int) abs($month);
+               $this->dayBirth   = (int) abs($day);
+       }
+
+       // Remove gender
+       public final function removeGender () {
+               unset($this->gender);
+       }
+
+       // Remove both names
+       public final function removeNames () {
+               unset($this->surname);
+               unset($this->family);
+       }
+
+       // Remove complete birthday
+       public final function removeBirthday () {
+               unset($this->yearBirth);
+               unset($this->monthBirth);
+               unset($this->dayBirth);
+       }
+
+       // Remove salary
+       public final function removeSalary () {
+               unset($this->salary);
+       }
+
+       // Remove employment status
+       public final function removeEmployed () {
+               unset($this->employed);
+       }
+
+       // Remove marrital status
+       public final function removeMarried () {
+               unset($this->married);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/class_BaseSimulator.php b/application/shipsimu/main/class_BaseSimulator.php
new file mode 100644 (file)
index 0000000..e460013
--- /dev/null
@@ -0,0 +1,302 @@
+<?php
+/**
+ * The general simulator class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseSimulator extends BaseFrameworkSystem {
+       // Schiffsteilinstanz
+       private $partInstance = null;
+
+       // Abmasse (Breite/Hoehe/Laenge)
+       private $width  = 0;
+       private $height = 0;
+       private $length = 0;
+
+       // Aktuelles Schiff und Schiffsteil
+       private $currShip = null;
+       private $currPart = null;
+
+       // Faktoren zur Erweiterung der Masse. Beispielsweise soll der Maschinenraum groesser wie der Motor sein
+       private $resizeFactorArray = array(
+               'width'  => 1,
+               'height' => 1,
+               'length' => 1
+       );
+
+       // Konstruktor
+       protected function __construct ($className) {
+               // Call highest constructor
+               parent::__construct($className);
+
+               // Clean up a little, dies sollte ganz zum Schluss erfolgen!
+               $this->removeResizeFactorArray();
+               $this->removeCurrPart();
+               $this->removeCurrShip();
+       }
+
+       // Setter-Methode fuer Laenge
+       public final function setLength ($length) {
+               $this->length = (float) $length;
+       }
+
+       // Setter-Methode fuer Breite
+       public final function setWidth ($width) {
+               $this->width = (float) $width;
+       }
+
+       // Setter-Methode fuer Hoehe
+       public final function setHeight ($height) {
+               $this->height = (float) $height;
+       }
+
+       // Getter-Methode fuer Laenge
+       public final function getLength () {
+               return $this->length;
+       }
+
+       // Getter-Methode fuer Breite
+       public final function getWidth () {
+               return $this->width;
+       }
+
+       // Getter-Methode fuer Hoehe
+       public final function getHeight () {
+               return $this->height;
+       }
+
+       // Setter-Methode fuer Teil-Instanz
+       public final function setPartInstance (ConstructableShipPart $partInstance) {
+               $this->partInstance = $partInstance;
+       }
+
+       // Getter-Methode fuer Teil-Instanz
+       public final function getPartInstance () {
+               if (!isset($this->partInstance)) {
+                       return null;
+               }
+               return $this->partInstance;
+       }
+
+       // Remover-Methode fuer die Teil-Instanz
+       public final function removePartInstance () {
+               unset($this->partInstance);
+       }
+
+       // Prueft ob all Umberechnungsfaktoren gesetzt sind
+       private function isResizeFactorValid () {
+               return (($this->getResizeFactorElement('width')  > 1)
+                       || ($this->getResizeFactorElement('height') > 1)
+                       || ($this->getResizeFactorElement('length') > 1)
+               );
+       }
+
+       // Baut einen Motor in das Schiff ein
+       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $partInstance) {
+               // Schiff/-steil merken
+               $this->currShip = $shipInstance;
+               $this->currPart = $partInstance;
+
+               // Passt ueberhaupt das Schiffsteil in's Schiff?
+               if ($this->isShipPartSizeValid()) {
+                       // Muessen die Masse angepasst werden?
+                       if ($this->isResizeFactorValid()) {
+                               // Neue Angaben berechnen (wir lassen etwas Lust fuer Kabelbaeume, Roehren, Maschinisten, etc.)
+                               $this->newWidth  = (float) $this->getCurrPart()->getWidth()  * $this->resizeFactorArray['width'];
+                               $this->newHeight = (float) $this->getCurrPart()->getHeight() * $this->resizeFactorArray['height'];
+                               $this->newLength = (float) $this->getCurrPart()->getLength() * $this->resizeFactorArray['length'];
+
+                               // Passt dies nun immer noch?
+                               if ($this->isNewSizeValid()) {
+                                       // Das passt auch, dann Werte setzen und Motor-Instanz merken
+                                       $this->setWidth($this->newWidth);
+                                       $this->setHeight($this->newHeight);
+                                       $this->setLength($this->newLength);
+
+                                       // Einige Dinge entfernen...
+                                       $this->removeAllNewAttr();
+                               } else {
+                                       // Passt nicht! Also wieder Exception werfen...
+                                       throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <strong>%s</strong> vom Typ <strong>%s</strong> ist zu gross f&uuml;r das Schiff!",
+                                               $this->getCurrPart()->__toString(),
+                                               $this->getCurrPart()->getObjectDescription(),
+                                               $this->getCurrPart()->__toString()
+                                       ), 2);
+                               }
+                       } elseif ($this->currPart != null) {
+                               // Aktuelle Masse setzen
+                               $this->setWidth($this->getCurrPart()->getWidth());
+                               $this->setHeight($this->getCurrPart()->getHeight());
+                               $this->setLength($this->getCurrPart()->getLength());
+                       }
+
+                       // Existiert ein Schiffsteil?
+                       if (!is_null($this->currPart)) {
+                               // Schiffsteil-Instanz setzen
+                               $this->setPartInstance($this->currPart);
+
+                               // Instanzen entfernen
+                               $this->getCurrPart()->removeCurrShip();
+                               $this->getCurrPart()->removeCurrPart();
+                               $this->getCurrPart()->removePartInstance();
+                               $this->getCurrPart()->removeResizeFactorArray();
+                       }
+               } else {
+                       // Exception werfen!
+                       throw new StructureShipMismatchException(sprintf("[%s:] Das Schiffsteil <u>%s</u> vom Typ <u>%s</u> passt nicht in das Schiff!",
+                               $this->getCurrPart()->realClass,
+                               $this->getCurrPart()->getObjectDescription(),
+                               $this->getCurrPart()->__toString()
+                       ), 1);
+               }
+
+               // Nochmals Clean up a little
+               $this->removeResizeFactorArray();
+               $this->removeCurrShip();
+               $this->removeCurrPart();
+       }
+
+       // Array fuer Umrechnungstabelle entfernen
+       public final function removeResizeFactorArray () {
+               unset($this->resizeFactorArray);
+       }
+
+       /**
+        * Remove all new*** attributes
+        *
+        * @return      void
+        */
+       public final function removeAllNewAttr () {
+               unset($this->newWidth);
+               unset($this->newHeight);
+               unset($this->newLength);
+       }
+
+       /**
+        * Remove current ship instance
+        *
+        * @return      void
+        */
+       public final function removeCurrShip () {
+               unset($this->currShip);
+       }
+
+       // Aktuelle Schiffsteil-Instanz entfernen
+       public final function removeCurrPart () {
+               unset($this->currPart);
+       }
+
+       // Breite entfernen
+       public final function removeWidth () {
+               unset($this->width);
+       }
+
+       // Hoehe entfernen
+       public final function removeHeight () {
+               unset($this->height);
+       }
+
+       // Laenge entfernen
+       public final function removeLength () {
+               unset($this->length);
+       }
+
+       // Tiefgang entfernen
+       public final function removeDraught () {
+               unset($this->draught);
+       }
+
+       // Getter-Methode fuer Element aus resizeFactor
+       public final function getResizeFactorElement ($el) {
+               if (isset($this->resizeFactorArray[$el])) {
+                       // Element gefunden
+                       return $this->resizeFactorArray[$el];
+               } else {
+                       // Element nicht gefunden!
+                       return null;
+               }
+       }
+
+       // Setter-Methode fuer Element in resizeFactor
+       public final function setResizeFactorElement ($el, $value) {
+               $this->resizeFactorArray[$el] = (float) $value;
+       }
+
+       // Kontrolliert, ob die Abmasse Schiffsteil->Schiff stimmen
+       public function isShipPartSizeValid () {
+               return (
+                       (
+                               ( // Already defined ship messurings
+                                                ($this->getCurrPart()->getWidth()  < $this->currShip->getWidth())
+                                       && ($this->getCurrPart()->getHeight() < $this->currShip->getDraught())
+                                       && ($this->getCurrPart()->getLength() < $this->currShip->getLength())
+                               ) || ( // Ship messurings shall be calculated
+                                                ($this->currShip->getWidth()  == 0)
+                                       && ($this->currShip->getHeight() == 0)
+                                       && ($this->currShip->getLength() == 0)
+                               )
+                       // The inserted part must be messured!
+                       ) && ($this->getCurrPart()->getWidth()  > 0)
+                               && ($this->getCurrPart()->getHeight() > 0)
+                               && ($this->getCurrPart()->getLength() > 0)
+               );
+       }
+
+       // Kontrolliert, ob die Abmasse Maschinenraum->Schiff stimmen
+       public function isNewSizeValid () {
+               return (
+                       ( // Already defined ship messurings
+                                        ($this->newWidth  < $this->currShip->getWidth())
+                               && ($this->newHeight < $this->currShip->getDraught())
+                               && ($this->newLength < $this->currShip->getLength())
+                       ) || ( // Ship messurings shall be calculated
+                                        ($this->currShip->getWidth()  == 0)
+                               && ($this->currShip->getHeight() == 0)
+                               && ($this->currShip->getLength() == 0)
+                       )
+               );
+       }
+
+       // Masse extrahieren
+       public function extractDimensions ($dim) {
+               // Abmasse setzen
+               if ((isset($dim)) && (is_array($dim)) && (count($dim) == 3)) {
+                       // Abmasse aus Array holen
+                       $this->setWidth($dim[0]);
+                       $this->setHeight($dim[1]);
+                       $this->setLength($dim[2]);
+               } else {
+                       // Nicht gefundene Abmasse!
+                       throw new DimNotFoundInArrayException($this, self::EXCEPTION_DIMENSION_ARRAY_INVALID);
+               }
+       }
+
+       /**
+        * Getter for current part instance
+        *
+        * @return              $currPart       Instance of the current ship part object
+        */
+       public final function getCurrPart () {
+               return $this->currPart;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/class_Merchant.php b/application/shipsimu/main/class_Merchant.php
new file mode 100644 (file)
index 0000000..648e299
--- /dev/null
@@ -0,0 +1,109 @@
+<?php
+/**
+ * A class for merchants which can trade items
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Merchant extends BaseFrameworkSystem {
+       // Name des Haendlers
+       private $merchantName   = "Namenloser H&auml;ndler";
+
+       // Preislite (Objekte wiedermal!)
+       private $priceList      = null;
+
+       // Zugewiesener Hafen
+       private $harborInstance = null;
+
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Haendler mit Namen erzeugen
+       public static final function createMerchant ($merchantName, Harbor $harborInstance) {
+               // String absichern
+               $merchantName = (string) $merchantName;
+
+               // Get new instance
+               $merchantInstance = new Merchant();
+
+               // Debug message
+               if ((defined('DEBUG_MERCHANT')) || (defined('DEBUG_ALL'))) {
+                       $merchantInstance->debugOutput(sprintf("[%s:%d] Ein H&auml;ndler <strong>%s</strong> wird angelegt und soll sich am <strong>%s</strong> niederlassen.",
+                               __CLASS__,
+                               __LINE__,
+                               $merchantName,
+                               $harborInstance->getHarborName()
+                       ));
+               }
+
+               // Haendlernamen setzen
+               $merchantInstance->setMerchantName($merchantName);
+
+               // In dem angegebenen Hafen den Haendler ansiedeln
+               $merchantInstance->setHarborInstance($harborInstance);
+
+               // Preisliste initialisieren
+               $merchantInstance->createPriceList();
+
+               // Instanz zurueckliefern
+               return $merchantInstance;
+       }
+
+       // Initialize pricing list
+       private function createPriceList () {
+               $this->priceList = new FrameworkArrayObject("FakedPriceList");
+       }
+
+       // Setter for merchant name
+       public final function setMerchantName ($merchantName) {
+               // Debug message
+               $this->merchantName = (string) $merchantName;
+       }
+
+       // Getter for merchant name
+       public final function getMerchantName () {
+               return $this->merchantName;
+       }
+
+       // Setter for harbor instance
+       public final function setHarborInstance (Harbor $harborInstance) {
+               $this->harborInstance = $harborInstance;
+       }
+
+       // Getter for harbor instance
+       public final function getHarborInstance () {
+               return $this->harborInstance;
+       }
+
+       // Add new item to merchant's price list
+       public function addItemToPriceList (TradeableItem $itemInstance, $price) {
+               $this->makeDeprecated();
+       }
+
+       // Get a price from the merchant's list
+       public final function getPriceFromList (TradeableItem $itemInstance) {
+               $this->makeDeprecated();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/class_WorksContract.php b/application/shipsimu/main/class_WorksContract.php
new file mode 100644 (file)
index 0000000..bbe2f35
--- /dev/null
@@ -0,0 +1,329 @@
+<?php
+/**
+ * The work constract class which can be used for contract parties
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WorksContract extends BaseFrameworkSystem implements SignableContract {
+       // Zukuenftiger Schiffsname
+       private $shipName         = "";
+
+       // Instanz zum Schiffstypen
+       private $shipInstance     = null;
+
+       // Contract partner
+       private $contractPartner  = null;
+
+       // Other contract partner
+       private $contractParty    = null;
+
+       // Is the contract signed?
+       private $signed           = false;
+
+       // Merchant instance
+       private $merchantInstance = null;
+
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Neuen Bauvertrag generieren
+       public static final function createWorksContract ($shipType, $shipName, ContractPartner $partnerInstance) {
+               // Strings absichern
+               $shipType = (string) $shipType;
+               $shipName = (string) $shipName;
+
+               // Get new instance
+               $contractInstance = new WorksContract();
+
+               // Schiffsnamen setzen
+               $contractInstance->setShipName($shipName);
+
+               // Existiert die Klasse ueberhaupt?
+               if (!class_exists($shipType)) {
+                       // Klasse nicht gefunden
+                       throw new NoClassException ($shipType, self::EXCEPTION_CLASS_NOT_FOUND);
+               }
+
+               // Schiff-Instanz temporaer erzeugen und in den Bauvertrag einfuegen
+               $shipInstance = ObjectFactory::createObjectByName($shipType, array($shipName));
+               $contractInstance->setShipInstance($shipInstance);
+
+               // Remove the ship instance
+               unset($shipInstance);
+
+               // Set itself as contract partner
+               $contractInstance->setContractPartner($partnerInstance);
+
+               // Instanz zurueckgeben
+               return $contractInstance;
+       }
+
+       // Setter for ship instance
+       private final function setShipInstance (ConstructableShip $shipInstance) {
+               $this->shipInstance = $shipInstance;
+       }
+
+       // Setter for ship name
+       private final function setShipName ($shipName) {
+               $this->shipName = (string) $shipName;
+       }
+
+       // Getter for ship name
+       public final function getShipName () {
+               return $this->shipName;
+       }
+
+       // Getter for ship instance
+       public final function getShipInstance () {
+               return $this->shipInstance;
+       }
+
+       // Add detail to the contract
+       public function addContractDetails ($shipPart, $parentPart, array $dataArray) {
+               // Secure strings
+               $shipPart   = (string) $shipPart;
+               $parentPart = (string) $parentPart;
+
+               // Debug message
+               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiffsteil <strong>%s</strong> wird zusammen mit dem Konstruktionsteil <strong>%s</strong> in den Bauvertrag aufgenommen.",
+                       __CLASS__,
+                       __LINE__,
+                       $shipPart,
+                       $parentPart
+               ));
+
+               // Initialize the instance (shall not be done within dynamic part)
+               $partInstance = null;
+
+               // Try to get an instance for this ship part
+               try {
+                       $partInstance = ObjectFactory::createObjectByName($shipPart, $dataArray);
+               } catch (DimNotFoundInArrayException $e) {
+                       $this->debugOutput(sprintf("[main:] Die <strong>%s</strong> konnte nicht vervollst&auml;ndigt werden. Grund: <strong>%s</strong><br />",
+                               $this->getShipInstance()->getShipName(),
+                               $e->getMessage()
+                       ));
+
+                       // Debug message
+                       if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Versuche ein Schiffsteil in den Bauvertrag aufzunehmen.",
+                               __CLASS__,
+                               __LINE__
+                       ));
+
+                       // Is this ship part constructable?
+                       if (!$partInstance instanceof ConstructableShipPart) {
+                               // Ship part not constructable!
+                               throw new ShipPartNotConstructableException(array($shipPart), self::EXCEPTION_NOT_CONSTRUCTABLE);
+                       } elseif ($this->getShipInstance()->createShipPart($partInstance, $parentPart) === false) {
+                               // Schiff konnte nicht gebaut werden!
+                               throw new ShipNotConstructedException(sprintf("Das Schiff <strong>%s</strong> konnte wegen eines Fehlers nicht gebaut werden. Siehe obere Meldungen.",
+                                       $this->getShipInstance()->getShipName()
+                               ));
+                       }
+               } catch (NoClassException $e) {
+                       // Throw it again...
+                       throw new NoClassException($e->getMessage(), $e->getCode());
+               }
+
+               // Get price for this item
+               $price = $this->getMerchantInstance()->getPriceFromList($partInstance);
+
+               // Add price
+               $partInstance->setPrice($price);
+       }
+
+       // Setter for contract partner
+       public final function setContractPartner (ContractPartner $partnerInstance) {
+               $this->contractPartner = $partnerInstance;
+       }
+
+       // Getter for contract partner
+       public final function getContractPartner () {
+               return $this->contractPartner;
+       }
+
+       // Setter for contract party
+       public final function setContractParty (ContractPartner $partyInstance) {
+               $this->contractParty = $partyInstance;
+       }
+
+       // Getter for contract party
+       public final function getContractParty () {
+               return $this->contractParty;
+       }
+
+       // Setter for signature
+       public final function setSigned ($signed) {
+               $this->signed = (boolean) $signed;
+       }
+
+       // Getter for signature
+       public function isSigned () {
+               return $this->signed;
+       }
+
+       // Sign the contract
+       public function signContract (ContractPartner $partnerInstance, ContractPartner $partyInstance) {
+               // Is this contract already signed?
+               if ($this->isSigned()) {
+                       // Throw an exception
+                       throw new ContractAllreadySignedException(array($this, $this->getContractPartner(), $this->getContractParty()), self::EXCEPTION_CONTRACT_ALREADY_SIGNED);
+               }
+
+               // Is the first contract partner still the same?
+               if ($partnerInstance->equals($this->getContractPartner())) {
+                       // Set contract party (other partner is already set)
+                       $this->setContractParty($partyInstance);
+
+                       // Finally sign it
+                       $this->setSigned(true);
+               } else {
+                       // Throw an exception
+                       throw new ContractPartnerMismatchException(array($this, $this->getContractPartner(), $partyInstance), self::EXCEPTION_CONTRACT_PARTNER_MISMATCH);
+               }
+
+               // Debug message
+               if ((defined('DEBUG_CONTRACT')) || (defined('DEBUG_ALL'))) {
+                       if ($partnerInstance->equals($partyInstance)) {
+                               // With itself
+                               $this->debugOutput(sprintf("[%s:%d] Die <strong>%s</strong> <em><strong>%s</strong></em> stimmt einem Bauvertrag &uuml;ber das <strong>%s</strong> <em><strong>%s</strong></em> zu.",
+                                       __CLASS__,
+                                       __LINE__,
+                                       $partnerInstance->getObjectDescription(),
+                                       $partnerInstance->getCompanyName(),
+                                       $this->getShipInstance()->getObjectDescription(),
+                                       $this->getShipInstance()->getShipName()
+                               ));
+                       } else {
+                               // Other contract party
+                               $this->debugOutput(sprintf("[%s:%d] Die <strong>%s</strong> <em><strong>%s</strong></em> geht mit der <strong>%s</strong> <em><strong>%s</strong></em> einen Bauvertrag &uuml;ber das <strong>%s</strong> <em><strong>%s</strong></em> ein.",
+                                       __CLASS__,
+                                       __LINE__,
+                                       $partnerInstance->getObjectDescription(),
+                                       $partnerInstance->getCompanyName(),
+                                       $partyInstance->getObjectDescription(),
+                                       $partyInstance->getCompanyName(),
+                                       $this->getShipInstance()->getObjectDescription(),
+                                       $this->getShipInstance()->getShipName()
+                               ));
+                       }
+               }
+       }
+
+       // Setter for merchant instance
+       public final function setMerchantInstance (Merchant $merchantInstance) {
+               $this->merchantInstance = $merchantInstance;
+       }
+
+       // Getter for merchant instance
+       public final function getMerchantInstance () {
+               return $this->merchantInstance;
+       }
+
+       // Getter for total price
+       public final function getTotalPrice () {
+               // Get ship instance
+               $shipInstance = $this->getShipInstance();
+
+               // Is this a ship?
+               if (is_null($shipInstance)) {
+                       // Opps! Empty partner instance?
+                       throw new NullPointerException($shipInstance, self::EXCEPTION_IS_NULL_POINTER);
+               } elseif (!is_object($shipInstance)) {
+                       // Not an object! ;-(
+                       throw new InvalidObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
+               } elseif (!$shipInstance instanceof ConstructableShip) {
+                       // Does not have the required feature (method)
+                       throw new ShipIsInvalidException(array($shipInstance), self::EXCEPTION_INVALID_SHIP_INSTANCE);
+               }
+
+               // Get the structure array
+               $struct = $shipInstance->getStructuresArray();
+
+               // Is this a ship?
+               if (is_null($struct)) {
+                       // Opps! Empty partner instance?
+                       throw new EmptyStructuresListException($this, self::EXCEPTION_EMPTY_STRUCTURES_ARRAY);
+               }
+
+               // Init total price
+               $totalPrice = 0;
+
+               // Iterate through the list
+               for ($iter = $struct->getIterator(); $iter->valid(); $iter->next()) {
+                       // Get item
+                       $item = $iter->current();
+
+                       // Is this a ship?
+                       if (is_null($item)) {
+                               // Opps! Empty partner instance?
+                               throw new NullPointerException($item, self::EXCEPTION_IS_NULL_POINTER);
+                       } elseif (!is_object($item)) {
+                               // Not an object! ;-(
+                               throw new InvalidObjectException($item, self::EXCEPTION_IS_NO_OBJECT);
+                       } elseif (!$item instanceof BaseSimulator) {
+                               // Does not have the required feature (method)
+                               throw new MissingMethodException(array($item, 'getPartInstance'), self::EXCEPTION_MISSING_METHOD);
+                       }
+
+                       // Get part instance
+                       $part = $item->getPartInstance();
+
+                       // Is this a ship?
+                       if (is_null($part)) {
+                               // Opps! Empty partner instance?
+                               throw new NullPointerException($part, self::EXCEPTION_IS_NULL_POINTER);
+                       } elseif (!is_object($part)) {
+                               // Not an object! ;-(
+                               throw new InvalidObjectException($part, self::EXCEPTION_IS_NO_OBJECT);
+                       } elseif (!method_exists($part, 'getPrice')) {
+                               // Does not have the required feature (method)
+                               throw new MissingMethodException(array($part, 'getPrice'), self::EXCEPTION_MISSING_METHOD);
+                       }
+
+                       // Get price for one item
+                       $price = $part->getPrice();
+
+                       // Is there numCabin() available?
+                       if (method_exists($item, 'getNumCabin')) {
+                               // Get total cabin and multiply it with the price
+                               $price = $price * $item->getNumCabin();
+                       }
+
+                       // Add price to total price
+                       $totalPrice += $price;
+               }
+
+               // Total price calculated?
+               if ($totalPrice === 0) {
+                       // Throw exception
+                       throw new TotalPriceNotCalculatedException($this, self::EXCEPTION_TOTAL_PRICE_NOT_CALCULATED);
+               }
+
+               // Return total price
+               return $totalPrice;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/.htaccess b/application/shipsimu/main/commands/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/commands/web/.htaccess b/application/shipsimu/main/commands/web/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/commands/web/class_WebShipsimuGuestLoginCommand.php b/application/shipsimu/main/commands/web/class_WebShipsimuGuestLoginCommand.php
new file mode 100644 (file)
index 0000000..14015a3
--- /dev/null
@@ -0,0 +1,112 @@
+<?php
+/**
+ * A command for guest logins
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuGuestLoginCommand extends BaseCommand implements Commandable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipsimuGuestLoginCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipsimuGuestLoginCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // First get a GuestLogin instance
+               $loginInstance = ObjectFactory::createObjectByConfiguredName('guest_login_class');
+
+               // First set request and response instance
+               $loginInstance->setRequestInstance($requestInstance);
+
+               // Encrypt the password
+               $loginInstance->encryptPassword('passwd');
+
+               // Do the login here
+               $loginInstance->doLogin($requestInstance, $responseInstance);
+
+               // Was the login fine? Then redirect here
+               if ($loginInstance->ifLoginWasSuccessfull()) {
+                       // Try to redirect here
+                       try {
+                               // Redirect...
+                               $responseInstance->redirectToConfiguredUrl('app_login');
+
+                               // Exit here
+                               exit();
+                       } catch (FrameworkException $e) {
+                               // Something went wrong here!
+                               $responseInstance->addFatalMessage($e->getMessage());
+                       }
+               } else {
+                       // Attach error message to the response
+                       $responseInstance->addFatalMessage('failed_user_login');
+               }
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add more filters
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add username verifier filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_guest_verifier_filter'));
+
+               // Add password verifier filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('passwd_guest_verifier_filter'));
+
+               // Add CAPTCHA verifier code
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_guest_verifier_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/class_WebShipsimuProfileCommand.php b/application/shipsimu/main/commands/web/class_WebShipsimuProfileCommand.php
new file mode 100644 (file)
index 0000000..a266f26
--- /dev/null
@@ -0,0 +1,153 @@
+<?php
+/**
+ * A command for profile-update handling
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuProfileCommand extends BaseCommand implements Commandable {
+       /**
+        * Filtered request data
+        */
+       private $requestData = array();
+
+       /**
+        * Allowed profile data to pass through
+        */
+       private $allowedData = array(
+               'pass'  => 'pass1',
+               'email' => 'email1',
+               'surname',
+               'family',
+               'street',
+               'city',
+               'zip',
+               'icq',
+               'jabber',
+               'yahoo',
+               'aol',
+               'msn',
+               'rules',
+               'birth_day',
+               'birth_month',
+               'birth_year'
+       );
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipsimuProfileCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipsimuProfileCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Add functionality here
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Make sure only allowed values are comming through
+               foreach ($this->allowedData as $alias => $element) {
+                       // Get data
+                       $data = $requestInstance->getRequestElement($element);
+
+                       // Silently skip empty fields
+                       if (empty($data)) continue;
+
+                       // Do we have an alias?
+                       if (is_string($alias)) {
+                               // Yes, so use it
+                               $this->requestData[$alias]   = $data;
+                       } else {
+                               // No, default entry
+                               $this->requestData[$element] = $data;
+                       }
+               } // END - foreach
+
+               // Remove the array, we don't need it anymore
+               unset($this->allowedData);
+
+               // Unfinished!
+               $this->partialStub("Unfinished work.");
+               $this->debugBackTrace();
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some more pre/post filters to the controller
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add user auth filter (we don't need an update of the user here because it will be redirected)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // User status filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // User status if not 'guest' filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_guest_filter'));
+
+               // Updated rules accepted
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('rules_accepted_filter'));
+
+               // Account password validation
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
+
+               // Validate CAPTCHA input
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_profile_verifier_filter'));
+
+               // Validate birthday input
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('birthday_profile_verifier_filter'));
+
+               // Email changed
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_change_filter'));
+
+               // Password changed
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_change_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/class_WebShipsimuRefillCommand.php b/application/shipsimu/main/commands/web/class_WebShipsimuRefillCommand.php
new file mode 100644 (file)
index 0000000..1c9bd8e
--- /dev/null
@@ -0,0 +1,112 @@
+<?php
+/**
+ * A command for the money refill page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuRefillCommand extends BaseCommand implements Commandable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipsimuRefillCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipsimuRefillCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get template instance
+               $templateInstance = $responseInstance->getTemplateInstance();
+
+               // Set amount and type as variables
+               $templateInstance->assignVariable('refill_done', $requestInstance->getRequestElement('type'));
+               $templateInstance->assignVariable('amount'     , $requestInstance->getRequestElement('amount'));
+
+               // This method does currently redirect if all goes right. Booking is done in filters
+               $responseInstance->redirectToConfiguredUrl('refill_page_done');
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add user auth filter (we don't need an update of the user here because it will be redirected)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // Add user status filter here
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Is the refill page active?
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_page_filter'));
+
+               // Verify password
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
+
+               // Verify CAPTCHA code
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_refill_verifier_filter'));
+
+               // Verify refill request
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('refill_request_validator_filter'));
+
+               // Construct config entry for wether automatic payment from API or waiting for approval
+               $paymentTypeConfig = sprintf("refill_request_%s_payment_type", $requestInstance->getRequestElement('type'));
+
+               // Prepare a filter based on the requested type we shall refill
+               $filterName = sprintf("refill_request_%s_%s_book_filter",
+                       $requestInstance->getRequestElement('type'),
+                       $this->getConfigInstance()->getConfigEntry($paymentTypeConfig)
+               );
+
+               // Now, try to load that filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName($filterName));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/class_WebShipsimuRegisterCommand.php b/application/shipsimu/main/commands/web/class_WebShipsimuRegisterCommand.php
new file mode 100644 (file)
index 0000000..181ce2f
--- /dev/null
@@ -0,0 +1,117 @@
+<?php
+/**
+ * A command for registration handling
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuRegisterCommand extends BaseCommand implements Commandable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipsimuRegisterCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipsimuRegisterCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // First get a UserRegistration instance
+               $registerInstance = ObjectFactory::createObjectByConfiguredName('user_registration_class');
+
+               // First set request and response instance
+               $registerInstance->setRequestInstance($requestInstance);
+               $registerInstance->setResponseInstance($responseInstance);
+
+               // Encrypt the password
+               $registerInstance->encryptPassword('pass1');
+
+               // Do things before registration
+               $registerInstance->doPreRegistration();
+
+               // Register the new user
+               $registerInstance->registerNewUser();
+
+               // Do things after registration like notifying partner pages or queueing
+               // them for notification
+               $registerInstance->doPostRegistration();
+
+               // Redirect or login after registration
+               $registerInstance->doPostAction();
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add some more pre/post filters to the controller
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Validate email address (if configured: check on double email addresses)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_validator_filter'));
+
+               // Validate username and check if it does not exist
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_validator_filter'));
+
+               // Validate if username is "guest" and not taken
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_is_guest_filter'));
+
+               // Validate if password is set
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_validator_filter'));
+
+               // Check if rules where accepted
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('rules_accepted_filter'));
+
+               // Validate CAPTCHA input
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_register_verifier_filter'));
+
+               // Validate birthday
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('birthday_register_verifier_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/class_WebShipsimuUserLoginCommand.php b/application/shipsimu/main/commands/web/class_WebShipsimuUserLoginCommand.php
new file mode 100644 (file)
index 0000000..2a33a8f
--- /dev/null
@@ -0,0 +1,124 @@
+<?php
+/**
+ * A command for user login
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuUserLoginCommand extends BaseCommand implements Commandable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipsimuUserLoginCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipsimuUserLoginCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // First get a UserLogin instance
+               $loginInstance = ObjectFactory::createObjectByConfiguredName('user_login_class');
+
+               // First set request and response instance
+               $loginInstance->setRequestInstance($requestInstance);
+
+               // Encrypt the password
+               $loginInstance->encryptPassword('pass');
+
+               // Do the login here
+               $loginInstance->doLogin($requestInstance, $responseInstance);
+
+               // Was the login fine? Then redirect here
+               if ($loginInstance->ifLoginWasSuccessfull()) {
+                       // Try to redirect here
+                       try {
+                               // Redirect...
+                               $responseInstance->redirectToConfiguredUrl('app_login');
+
+                               // Exit here
+                               exit();
+                       } catch (FrameworkException $e) {
+                               // Something went wrong here!
+                               $responseInstance->addFatalMessage($e->getMessage());
+                       }
+               } else {
+                       // Attach error message to the response
+                       $responseInstance->addFatalMessage('failed_user_login');
+               }
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Add more filters
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Which login type do we have?
+               switch ($this->getConfigInstance()->getConfigEntry('login_type')) {
+                       case 'username': // Login via username
+                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_verifier_filter'));
+                               break;
+
+                       case 'email': // Login via email
+                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('email_verifier_filter'));
+                               break;
+
+                       default: // Wether username or email is set
+                               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('username_email_verifier_filter'));
+                               break;
+               }
+
+               // Password verifier filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('password_verifier_filter'));
+
+               // Add filter for CAPTCHA
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_user_verifier_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/company/.htaccess b/application/shipsimu/main/commands/web/company/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/commands/web/company/class_WebShipSimuCompanyCommand.php b/application/shipsimu/main/commands/web/company/class_WebShipSimuCompanyCommand.php
new file mode 100644 (file)
index 0000000..7fed46f
--- /dev/null
@@ -0,0 +1,88 @@
+<?php
+/**
+ * A command for the money refill page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipSimuCompanyCommand extends BaseCommand implements Commandable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this command and sets the resolver instance
+        *
+        * @param       $resolverInstance       An instance of a command resolver
+        * @return      $commandInstance        The created command instance
+        */
+       public static final function createWebShipSimuCompanyCommand (CommandResolver $resolverInstance) {
+               // Get a new instance
+               $commandInstance = new WebShipSimuCompanyCommand();
+
+               // Set the resolver instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get template instance
+               $templateInstance = $responseInstance->getTemplateInstance();
+
+               // Set amount and type as variables
+               $templateInstance->assignVariable('refill_done', $requestInstance->getRequestElement('type'));
+               $templateInstance->assignVariable('amount'     , $requestInstance->getRequestElement('amount'));
+
+               // This method does currently redirect if all goes right
+               $responseInstance->redirectToConfiguredUrl('refill_page_done');
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add user auth filter (we don't need an update of the user here because it will be redirected)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // Add user status filter here
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/government/.htaccess b/application/shipsimu/main/commands/web/government/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php b/application/shipsimu/main/commands/web/government/class_WebGovernmentFailedStartupCommand.php
new file mode 100644 (file)
index 0000000..e720850
--- /dev/null
@@ -0,0 +1,146 @@
+<?php
+/**
+ * A command for a failed startup request. This may happen when the user
+ * "knows" the correct URL but government refuses to pay.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebGovernmentFailedStartupCommand extends BaseCommand implements Commandable {
+       /**
+        * 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      $commandInstance        An instance a prepared command class
+        */
+       public static final function createWebGovernmentFailedStartupCommand (CommandResolver $resolverInstance) {
+               // Get new instance
+               $commandInstance = new WebGovernmentFailedStartupCommand();
+
+               // Set the application instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the given command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get the action instance from registry
+               $actionInstance = Registry::getRegistry()->getInstance('action');
+
+               // Do we have an action here?
+               if ($actionInstance instanceof PerformableAction) {
+                       // Execute the action (shall not output anything, see below why)
+                       $actionInstance->execute($requestInstance, $responseInstance);
+               } // END - if
+
+               // Get the application instance
+               $appInstance = $this->getResolverInstance()->getApplicationInstance();
+
+               // Prepare a template instance
+               $templateInstance = $this->prepareTemplateInstance($appInstance);
+
+               // Assign base URL
+               $templateInstance->assignConfigVariable('base_url');
+
+               // Assign all the application's data with template variables
+               $templateInstance->assignApplicationData($appInstance);
+
+               // Load the master template
+               $masterTemplate = $appInstance->buildMasterTemplateName();
+
+               // Load header template
+               $templateInstance->loadCodeTemplate('header');
+
+               // Compile and assign it with a variable
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('header', 'header');
+
+               // Load footer template
+               $templateInstance->loadCodeTemplate('footer');
+
+               // Compile and assign it with a variable
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('footer', 'footer');
+
+               // Load main template
+               $templateInstance->loadCodeTemplate('government_failed_main');
+
+               // Assign the main template with the master template as a content ... ;)
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('government_failed_main', 'content');
+
+               // Load the master template
+               $templateInstance->loadCodeTemplate($masterTemplate);
+
+               // Set title
+               $templateInstance->assignVariable('title', $this->getLanguageInstance()->getMessage($requestInstance->getRequestElement('page') . '_' . $requestInstance->getRequestElement('failed') . '_title'));
+
+               // Construct the menu in every command. We could do this in BaseCommand class. But this means
+               // *every* command has a navigation system and that is want we don't want.
+               $menuInstance = ObjectFactory::createObjectByConfiguredName('government_failed_area_menu_class', array($appInstance));
+
+               // Render the menu
+               $menuInstance->renderMenu();
+
+               // Transfer it to the template engine instance
+               $menuInstance->transferContentToTemplateEngine();
+
+               // ... and all variables. This should be merged together in a pattern
+               // to make things easier. A cache mechanism should be added between
+               // these two calls to cache compiled templates.
+               $templateInstance->compileVariables();
+
+               // Get the content back from the template engine and put it in response class
+               $templateInstance->transferToResponse($responseInstance);
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Maybe we need some filters here?
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Empty for now
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php b/application/shipsimu/main/commands/web/government/class_WebGovernmentFailedTrainingCommand.php
new file mode 100644 (file)
index 0000000..45bcc32
--- /dev/null
@@ -0,0 +1,146 @@
+<?php
+/**
+ * A command for a failed training request. This may happen when the user
+ * "knows" the correct URL but government refuses to pay.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebGovernmentFailedTrainingCommand extends BaseCommand implements Commandable {
+       /**
+        * 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      $commandInstance        An instance a prepared command class
+        */
+       public static final function createWebGovernmentFailedTrainingCommand (CommandResolver $resolverInstance) {
+               // Get new instance
+               $commandInstance = new WebGovernmentFailedTrainingCommand();
+
+               // Set the application instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the given command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get the action instance from registry
+               $actionInstance = Registry::getRegistry()->getInstance('action');
+
+               // Do we have an action here?
+               if ($actionInstance instanceof PerformableAction) {
+                       // Execute the action (shall not output anything, see below why)
+                       $actionInstance->execute($requestInstance, $responseInstance);
+               } // END - if
+
+               // Get the application instance
+               $appInstance = $this->getResolverInstance()->getApplicationInstance();
+
+               // Prepare a template instance
+               $templateInstance = $this->prepareTemplateInstance($appInstance);
+
+               // Assign base URL
+               $templateInstance->assignConfigVariable('base_url');
+
+               // Assign all the application's data with template variables
+               $templateInstance->assignApplicationData($appInstance);
+
+               // Load the master template
+               $masterTemplate = $appInstance->buildMasterTemplateName();
+
+               // Load header template
+               $templateInstance->loadCodeTemplate('header');
+
+               // Compile and assign it with a variable
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('header', 'header');
+
+               // Load footer template
+               $templateInstance->loadCodeTemplate('footer');
+
+               // Compile and assign it with a variable
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('footer', 'footer');
+
+               // Load main template
+               $templateInstance->loadCodeTemplate('government_failed_main');
+
+               // Assign the main template with the master template as a content ... ;)
+               $templateInstance->compileTemplate();
+               $templateInstance->assignTemplateWithVariable('government_failed_main', 'content');
+
+               // Load the master template
+               $templateInstance->loadCodeTemplate($masterTemplate);
+
+               // Set title
+               $templateInstance->assignVariable('title', $this->getLanguageInstance()->getMessage($requestInstance->getRequestElement('page') . '_' . $requestInstance->getRequestElement('failed') . '_title'));
+
+               // Construct the menu in every command. We could do this in BaseCommand class. But this means
+               // *every* command has a navigation system and that is want we don't want.
+               $menuInstance = ObjectFactory::createObjectByConfiguredName('government_failed_area_menu_class', array($appInstance));
+
+               // Render the menu
+               $menuInstance->renderMenu();
+
+               // Transfer it to the template engine instance
+               $menuInstance->transferContentToTemplateEngine();
+
+               // ... and all variables. This should be merged together in a pattern
+               // to make things easier. A cache mechanism should be added between
+               // these two calls to cache compiled templates.
+               $templateInstance->compileVariables();
+
+               // Get the content back from the template engine and put it in response class
+               $templateInstance->transferToResponse($responseInstance);
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Maybe we need some filters here?
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Empty for now
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php b/application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentStartupCommand.php
new file mode 100644 (file)
index 0000000..3153962
--- /dev/null
@@ -0,0 +1,96 @@
+<?php
+/**
+ * A command for a failed startup request. This may happen when the user
+ * "knows" the correct URL but government refuses to pay.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuGovernmentStartupCommand extends BaseCommand implements Commandable {
+       /**
+        * 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      $commandInstance        An instance a prepared command class
+        */
+       public static final function createWebShipsimuGovernmentStartupCommand (CommandResolver $resolverInstance) {
+               // Get new instance
+               $commandInstance = new WebShipsimuGovernmentStartupCommand();
+
+               // Set the application instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the given command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get a wrapper instance
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
+
+               // Register the startup help
+               $wrapperInstance->registerStartupHelpByRequest($requestInstance);
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Maybe we need some filters here?
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add user auth filter (we don't need an update of the user here because it will be redirected)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // Add user status filter here
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Check if government can pay startup help
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_startup_help_filter'));
+
+               // Verify password
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
+
+               // Verify CAPTCHA code
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_government_verifier_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php b/application/shipsimu/main/commands/web/government/class_WebShipsimuGovernmentTrainingCommand.php
new file mode 100644 (file)
index 0000000..035e5e8
--- /dev/null
@@ -0,0 +1,94 @@
+<?php
+/**
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebShipsimuGovernmentTrainingCommand extends BaseCommand implements Commandable {
+       /**
+        * 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      $commandInstance        An instance a prepared command class
+        */
+       public static final function createWebShipsimuGovernmentTrainingCommand (CommandResolver $resolverInstance) {
+               // Get new instance
+               $commandInstance = new WebShipsimuGovernmentTrainingCommand();
+
+               // Set the application instance
+               $commandInstance->setResolverInstance($resolverInstance);
+
+               // Return the prepared instance
+               return $commandInstance;
+       }
+
+       /**
+        * Executes the given command with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Get a wrapper instance
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
+
+               // Register the training
+               $wrapperInstance->registerTrainingByRequest($requestInstance);
+       }
+
+       /**
+        * Adds extra filters to the given controller instance
+        *
+        * @param       $controllerInstance             A controller instance
+        * @param       $requestInstance                An instance of a class with an Requestable interface
+        * @return      void
+        * @todo        Maybe we need some filters here?
+        */
+       public function addExtraFilters (Controller $controllerInstance, Requestable $requestInstance) {
+               // Add user auth filter (we don't need an update of the user here because it will be redirected)
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // Add user status filter here
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_status_filter'));
+
+               // Check if government can pay training help
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('government_pays_training_filter'));
+
+               // Verify password
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('account_password_filter'));
+
+               // Verify CAPTCHA code
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('captcha_refill_verifier_filter'));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/companies/.htaccess b/application/shipsimu/main/companies/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/companies/class_ShippingCompany.php b/application/shipsimu/main/companies/class_ShippingCompany.php
new file mode 100644 (file)
index 0000000..de959b6
--- /dev/null
@@ -0,0 +1,666 @@
+<?php
+/**
+ * A shipping company may be founded with this class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShippingCompany extends BaseSimulator implements Customer, ContractPartner {
+       /**
+        * Full name of this company
+        */
+       private $companyName     = "Namenlose Reederei";
+
+       /**
+        * Shorted name of this company
+        */
+       private $shortName       = "";
+
+       /**
+        * Instance of the founder
+        */
+       private $founderInstance = null;
+
+       /**
+        * Headquarter harbor instance
+        */
+       private $hqInstance      = null;
+
+       /**
+        * Employed people by this company
+        */
+       private $employeeList    = null;
+
+       /**
+        * List of all assigned shipyards
+        */
+       private $shipyardList   = null;
+
+       /**
+        * List of owned ships
+        */
+       private $ownedShips      = null;
+
+       /**
+        * Work constracts this company is currently working on
+        */
+       private $contractList    = null;
+
+       // Exception constants
+       const EXCEPTION_USER_OWNS_NO_COMPANY = 0x200;
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this company class or throws an exception if the
+        * given user owns no company.
+        *
+        * @param       $userInstance           A user class
+        * @return      $companyInstance        Prepared company instance
+        * @todo        Add functionality if user participates in a company
+        */
+       public static final function createShippingCompany (ManageableAccount $userInstance) {
+               // Get new instance
+               $companyInstance = new ShippingCompany();
+
+               // Does the given user owns a company?
+               if ($companyInstance->ifUserParticipatesInCompany($userInstance)) {
+                       // 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
+
+               // Init all lists
+               $companyInstance->initCompanyLists();
+
+               // Return instance
+               return $companyInstance;
+       }
+
+       /**
+        * Checks wether the given user participates in a company
+        *
+        * @param       $userInstance   An instance of a user class
+        * @return      $participates   Wether the user participates at lease in one company
+        */
+       protected function ifUserParticipatesInCompany (ManageableAccount $userInstance)  {
+               // By default no user owns any company... ;)
+               $participates = false;
+
+               // Get a company database wrapper class
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class', array($this));
+
+               // Ask the wrapper if this user participates
+               $participates = $wrapperInstance->ifUserParticipatesInCompany($userInstance);
+
+               // Get the result instance
+               $resultInstance = $wrapperInstance->getResultInstance();
+
+               // Caches the result instance here, if set (we don't the wrapper anymore!)
+               if ($resultInstance instanceof SearchableResult) {
+                       // Set the result instance
+                       $this->setResultInstance($resultInstance);
+               } // END - if
+
+               // Return result
+               return $participates;
+       }
+
+       /**
+        * Checks wether the current user in registry is the company founder
+        *
+        * @return      $isFounder      Wether the current user is the company founder
+        * @todo        Check if user is company founder
+        */
+       public function ifUserIsFounder () {
+               // Default is not the founder
+               $isFounder = false;
+
+               // Get result instance
+               $resultInstance = $this->getResultInstance();
+
+               // Is it set?
+               if ($resultInstance instanceof SearchableResult) {
+                       // Result found so analyse it
+                       $this->partialStub("Check if user is company founder.");
+               } // END - if
+
+               // Return result
+               return $isFounder;
+       }
+
+       /**
+        * Checks wether the current user in registry is the company owner
+        *
+        * @return      $isOwner        Wether the current user is the company owner
+        * @todo        Check if user is company owner
+        */
+       public function ifUserIsOwner () {
+               // Default is not the owner
+               $isOwner = false;
+
+               // Get result instance
+               $resultInstance = $this->getResultInstance();
+
+               // Is it set?
+               if ($resultInstance instanceof SearchableResult) {
+                       // Result found so analyse it
+                       $this->partialStub("Check if user is company owner.");
+               } // END - if
+
+               // Return result
+               return $isOwner;
+       }
+
+       /**
+        * Checks wether the current user in registry is an employee in this company
+        *
+        * @return      $isOwner        Wether the current user is an employee in this company
+        */
+       public function ifUserIsEmployee () {
+               // Default is no employee
+               $isEmployee = false;
+
+               // Get result instance
+               $resultInstance = $this->getResultInstance();
+
+               // Is it set?
+               if ($resultInstance instanceof SearchableResult) {
+                       // Result found so he is employee
+                       $isEmployee = true;
+               } // END - if
+
+               // Return result
+               return $isEmployee;
+       }
+
+       //------------------------------------------------------------------------------\
+       // Below here is very old code which needs to be translated and changed heavily |
+       //------------------------------------------------------------------------------/
+
+       /**
+        * Intialize all lists
+        *
+        * @return      void
+        * @todo        Maybe we don't need these big lists anymore?! So we can deprecate/remove it
+        */
+       protected function initCompanyLists () {
+               // Employees
+               $this->employeeList = new FrameworkArrayObject("FakedEmployeeList");
+
+               // Ship yards
+               $this->shipyardList = new FrameworkArrayObject("FakedShipyardList");
+
+               // Contracts
+               $this->contractList = new FrameworkArrayObject("FakedContractList");
+       }
+
+       // Setter-Methode fuer Firmennamen
+       public final function setCompanyName ($companyName) {
+               $this->companyName = (string) $companyName;
+       }
+
+       // Getter-Methode fuer Firmennamen
+       public final function getCompanyName () {
+               return $this->companyName;
+       }
+
+       // Setter-Methode fuer Firmensitz
+       public final function setHQInstance (Harbor $hqInstance) {
+               $this->hqInstance = $hqInstance;
+       }
+
+       // Kuerzel setzen
+       private function initShortName () {
+               // Mindestens eine Leerstelle?
+               $dummy = explode(" ", $this->getCompanyName());
+               foreach ($dummy as $part) {
+                       $this->shortName .= substr($part, 0, 1);
+               } // END - if
+       }
+
+       // Reedereien Werften bauen lassen
+       public function createShipyardInHarbor($shipyardName, Harbor $harborInstance) {
+               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> baut im <strong>%s</strong> eine Werft <strong>%s</strong>.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $harborInstance->getHarborName(),
+                       $shipyardName
+               ));
+
+               // Wird im HQ gebaut?
+               if ($this->hqInstance->equals($harborInstance)) {
+                       // Die neue Werft wird im HQ gebaut!
+                       $this->hqInstance->addNewShipyardNotify($shipyardName, $this);
+                       // Die Werft drueber in Kenntnis setzen, welcher Reederei sie angehoert
+               } else {
+                       // Ausserhalb des Heimathafens soll eine Werft gebaut werden
+                       $harborInstance->addNewShipyardNotify($shipyardName, $this);
+               }
+       }
+
+       // Setter fuer Reederei-Gruender
+       public final function setCompanyFounder(CompanyEmployee $founderInstance) {
+               $this->founderInstance = $founderInstance;
+       }
+
+       // Getter for founder instance
+       public final function getFounderInstance () {
+               return $this->founderInstance;
+       }
+
+       // Neue(n) Angestellte(n) in Angestellten-Liste aufnehmen
+       public function addNewEmployee (SimulatorPersonell $employeeInstance) {
+               $this->employeeList->append($employeeInstance);
+       }
+
+       // Neue Werft in Liste aufnehmen
+       public function addNewShipyard (Shipyard $shipyardInstance) {
+               $this->shipyardList->append($shipyardInstance);
+       }
+
+       // Neue Mitarbeiter per Zufall einstellen/rekrutieren
+       public function recruitRandomEmployees($amount, SimulatorPersonell $personellInstance) {
+               // Anzahl Mitarbeiter absichern
+               $amount = (int) $amount;
+
+               // Debug-Meldung ausgeben
+               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> stellt per Zufall <strong>%d</strong> neue Mitarbeiter ein.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $amount
+               ));
+
+               // Gesamtanzahl verfuegbarer Erwerbsloser holen
+               $totalUnemployed = $personellInstance->getAllUnemployed();
+
+               // Existiert die gewuenschte Anzahl freier Arbeiter? (doppelt geht derzeit nicht)
+               if ($totalUnemployed < $amount) {
+                       // Reichte nicht aus!
+                       throw new ToMuchEmployeesException(array($amount, $personellInstance->getAllUnemployed()), self::EXCEPTION_NOT_ENOUGTH_UNEMPLOYEES);
+               } // END - if
+
+               // Get list for all unemployed people
+               $list = $personellInstance->getSpecialPersonellList(false); // Should be cached
+
+               // Get iterator of the list
+               $iterator = $list->getIterator();
+
+               // Get the requested amount of personell
+               for ($idx = 0; $idx < $amount; $idx++) {
+                       $employee = null;
+                       // Is this personl unemployed?
+                       while (is_null($employee) || $employee->isEmployed()) {
+                               // Generate random number
+                               $pos = mt_rand(0, ($totalUnemployed - 1)); // Don't remove the -1 here:
+                               // E.g. 100 entries means latest position is 99...
+
+                               // Seek for the position
+                               $iterator->seek($pos);
+
+                               // Is the current position valid?
+                               if ($iterator->valid() === false) {
+                                       // Should normally not happen... :(
+                                       throw new StructuresOutOfBoundsException($idx, self::EXCEPTION_INDEX_OUT_OF_BOUNDS);
+                               } // END - if
+
+                               // Get current element
+                               $employee = $iterator->current();
+                       } // END - while
+
+                       // A dummy just for the description and real class
+                       $dummy = CompanyEmployee::createCompanyEmployee("", "", "M", 1970, 1, 1, $employee->isMarried(), 0);
+
+                       // Make this person employed and give him some money to work
+                       $employee->setEmployed(true);
+                       $employee->setRealClass($dummy->__toString());
+                       $employee->increaseSalary((mt_rand(7, 14) * 100)); // Are 700 to 1400 EUR for the begin okay?
+
+                       // Debug message
+                       if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> stellt den/die Angestellte(n) <strong>%s %s</strong> ein.",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getCompanyName(),
+                               $employee->getSurname(),
+                               $employee->getFamily()
+                       ));
+
+                       // Add this employee
+                       $this->addNewEmployee($employee);
+               } // End - for
+
+               // Cache resetten
+               $personellInstance->resetCache();
+
+               // Debug-Meldung ausgeben
+               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat per Zufall <strong>%d</strong> neue Mitarbeiter eingestellt.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $amount
+               ));
+       } // End - method
+
+       // Distribute all personells on all shipyards
+       public function distributeAllPersonellOnShipyards () {
+               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> verteilt alle ihre <strong>%d</strong> Mitarbeiter auf alle <strong>%d</strong> Werft(en).",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $this->getTotalEmployee(),
+                       $this->getTotalShipyards()
+               ));
+
+               // Do we have some shipyards?
+               if (is_null($this->shipyardList)) {
+                       // No shipyards created
+                       throw new NoShipyardsConstructedException($this, self::EXCEPTION_HARBOR_HAS_NO_SHIPYARDS);
+               }
+
+               // Get iterator for shipyards
+               $shipyardIter = $this->shipyardList->getIterator();
+
+               // Iterate through all employees
+               for ($idx = $this->employeeList->getIterator(); $idx->valid(); $idx->next()) {
+                       // Is the shipyard iterator still okay?
+                       if ($shipyardIter->valid() === false) {
+                               // Rewind to first position
+                               $shipyardIter->seek(0);
+                       } // END - if
+
+                       // Get Shipyard object
+                       $shipyard = $shipyardIter->current();
+
+                       // Is this a Shipyard object?
+                       if (is_null($shipyard)) {
+                               // No class returned
+                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
+                       } elseif (!is_object($shipyard)) {
+                               // Not an object! ;-(
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                       } elseif ($shipyard->isClass("Shipyard") === false) {
+                               // Nope, so throw exception
+                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
+                       }
+
+                       // Add employee to the shipyard
+                       $shipyard->addNewPersonell($idx->current());
+
+                       // Continue to next shipyard
+                       $shipyardIter->next();
+               }
+       }
+
+       // Getter for total employees
+       public final function getTotalEmployee () {
+               // Count all...
+               $total = $this->employeeList->count();
+
+               // Debug message
+               if ((defined('DEBUG_COMPANY_EMPLOYEE')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat <strong>%d</strong> Mitarbeiter.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $total
+               ));
+
+               // Return amount
+               return $total;
+       }
+
+       // Getter for total shipyards
+       public final function getTotalShipyards () {
+               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] F&uuml;r die Reederei <strong>%s</strong> werden die Anzahl der Werften in allen H&auml;fen ermittelt.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName()
+               ));
+
+               // Do we have some shipyards?
+               if (is_null($this->shipyardList)) {
+                       // No shipyards created
+                       throw new NoShipyardsConstructedException($this, self::EXCEPTION_HARBOR_HAS_NO_SHIPYARDS);
+               }
+
+               // Get iterator
+               $total = $this->shipyardList->count();
+
+               // Debug message
+               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat <strong>%d</strong> Werft(en).",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $total
+               ));
+
+               // Return amount
+               return $total;
+       }
+
+       // Add a ship type (class) to all shipyards
+       public function addShipTypeToAllShipyards ($shipType) {
+               // Secure strings
+               $shipType = (string) $shipType;
+
+               // Is the class there?
+               if (!class_exists($shipType)) {
+                       // Throw exception
+                       throw new NoClassException($shipType, self::EXCEPTION_CLASS_NOT_FOUND);
+               }
+
+               // Create dummy ship
+               eval(sprintf("\$shipInstance = %s::create%s(\"M/S Dummy\");",
+                       $shipType,
+                       $shipType
+               ));
+
+               // Iterate shipyard list
+               for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
+                       // Get current element
+                       $shipyard = $idx->current();
+
+                       // Is this a shipyard?
+                       if (is_null($shipyard)) {
+                               // Opps! Empty list?
+                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
+                       } elseif (!is_object($shipyard)) {
+                               // Not an object! ;-(
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                       } elseif ($shipyard->isClass("Shipyard") === false) {
+                               // Class is not a shipyard
+                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
+                       }
+
+                       // Add the new ship type to the shipyard
+                       $shipyard->addNewConstructableShipType($shipType);
+               } // END - for
+       }
+
+       // Validate the requested ship type with the company if they can construct it
+       public function validateWorksContractShipType (SignableContract $contractInstance) {
+               // First get the ship type
+               $shipInstance = $contractInstance->getShipInstance();
+
+               // Ist there a ship instance?
+               if (is_null($shipInstance)) {
+                       // Opps! Empty entry?
+                       throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
+               } elseif (!is_object($shipInstance)) {
+                       // Not an object! ;-(
+                       throw new InvalidObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
+               }
+
+               // Get it's real class name
+               $shipType = $shipInstance->__toString();
+
+               // Now check if ship type is in any list and return the result
+               return ($this->isShipTypeConstructable($shipType));
+       }
+
+       // Is the ship type constructable?
+       public function isShipTypeConstructable ($shipType) {
+               // The type must be a string!
+               $shipType = (string) $shipType;
+
+               // Debug message
+               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> fragt alle Werften ab, ob diese Schiffe vom Typ <strong>%s</strong> bauen k&ouml;nnen.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $shipType
+               ));
+
+               // First everthing is failed...
+               $result = false;
+
+               // Iterate through all shipyards
+               for ($idx = $this->shipyardList->getIterator(); $idx->valid(); $idx->next()) {
+                       // Get current Shipyard instance
+                       $shipyard = $idx->current();
+
+                       // Is this a shipyard?
+                       if (is_null($shipyard)) {
+                               // Opps! Empty list?
+                               throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
+                       } elseif (!is_object($shipyard)) {
+                               // Not an object! ;-(
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                       } elseif ($shipyard->isClass("Shipyard") === false) {
+                               // Class is not a shipyard
+                               throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
+                       }
+
+                       // Validate if first found shipyard can construct the requested type
+                       $result = $shipyard->isShipTypeConstructable($shipType);
+
+                       // Does this shipyard construct the requested ship type?
+                       if ($result) break; // Then abort the search!
+               } // END - for
+
+               // Debug message
+               if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> hat die Suche nach einer Werft beendet, die Schiffe vom Typ <strong>%s</strong> bauen kann.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getCompanyName(),
+                       $shipType
+               ));
+
+               // Return result
+               return $result;
+       }
+
+       // As a customer the shipping company can add new contracts
+       public function addNewWorksContract (SignableContract $contractInstance) {
+               $this->contractList->append($contractInstance);
+       }
+
+       // As a customer the shippng company can withdraw from a contract
+       public function withdrawFromContract (SignableContract $contractInstance) {
+               ApplicationEntryPoint::app_die("WITHDRAW:<pre>".print_r($contractInstance, true)."</pre>");
+       }
+
+       // Get latest added contract instance
+       public final function getLastContractInstance () {
+               // Get iterator
+               $iter = $this->contractList->getIterator();
+
+               // Get latest entry (total - 1)
+               $iter->seek($iter->count() - 1);
+
+               // Return entry
+               return $iter->current();
+       }
+
+       // Sign a contract with an other party which must also implement Customer
+       public function signContract (SignableContract $contractInstance, ContractPartner $partnerInstance) {
+               // Check wether the other party is our contract partner
+               if ($partnerInstance->isContractPartner($contractInstance) === false) {
+                       // Invalid contract partner!
+                       throw new InvalidContractPartnerException($partnerInstance, self::EXCEPTION_CONTRACT_PARTNER_INVALID);
+               } // END - if
+
+               // Determine if company "signs" own contract (must be done) or with an other party
+               if ($this->equals($partnerInstance)) {
+                       // With itself
+                       if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> erteilt an sich selbst einen Bauauftrag f&uuml;r das <strong>%s</strong> &quot;<strong>%s</strong>&quot;.",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getCompanyName(),
+                               $contractInstance->getShipInstance()->getObjectDescription(),
+                               $contractInstance->getShipInstance()->getShipName()
+                       ));
+               } else {
+                       // Other external company
+                       if ((defined('DEBUG_COMPANY')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Reederei <strong>%s</strong> unterzeichnet einen Bauauftrag f&uuml;r das <strong>%s</strong> &quot;<strong>%s</strong>&quot; mit der <strong>%s</strong>.",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getCompanyName(),
+                               $contractInstance->getShipInstance()->getObjectDescription(),
+                               $contractInstance->getShipInstance()->getShipName(),
+                               $partnerInstance->getCompanyName()
+                       ));
+               }
+
+               // Sign the contract
+               $contractInstance->signContract($this, $partnerInstance);
+
+               /**
+                * @todo        Maybe do something more here...
+                */
+       }
+
+       // Is this the right contract partner?
+       public function isContractPartner (SignableContract $contractInstance) {
+               // Get contract partner instance and compare it with $this contract partner
+               return ($this->equals($contractInstance->getContractPartner()));
+       }
+
+       // Setter for merchant instance
+       public final function setMerchantInstance (Merchant $merchantInstance) {
+               // Get contract
+               $contractInstance = $this->getLastContractInstance();
+
+               if (is_null($contractInstance)) {
+                       // Opps! Empty contract instance?
+                       throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
+               } elseif (!is_object($contractInstance)) {
+                       // Not an object! ;-(
+                       throw new InvalidObjectException($contractInstance, self::EXCEPTION_IS_NO_OBJECT);
+               } elseif ($contractInstance->isClass("WorksContract") === false) {
+                       // Is not a merchant
+                       throw new ClassMismatchException(array($contractInstance->__toString(), "WorksContract"), self::EXCEPTION_CLASSES_NOT_MATCHING);
+               }
+
+               // Set the merchant in the contract (for getting prices)
+               $contractInstance->setMerchantInstance($merchantInstance);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/.htaccess b/application/shipsimu/main/constructions/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/berths/.htaccess b/application/shipsimu/main/constructions/berths/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/berths/class_Berth.php b/application/shipsimu/main/constructions/berths/class_Berth.php
new file mode 100644 (file)
index 0000000..c96ba10
--- /dev/null
@@ -0,0 +1,39 @@
+<?php
+/**
+ * A berth is a place where ships can wait for their next assignment
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Berth extends BaseConstruction {
+       // Durchlaufende Nummer der Liegeplaetze
+       private $berthIndex = 0;
+
+       // Zugewiesener Hafen
+       private $harborInstance = null;
+
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/class_BaseConstruction.php b/application/shipsimu/main/constructions/class_BaseConstruction.php
new file mode 100644 (file)
index 0000000..af08a39
--- /dev/null
@@ -0,0 +1,36 @@
+<?php
+/**
+ * A general construction (land) class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseConstruction extends BaseSimulator {
+       // Tiefgang fuer z.B. Trockdocks
+       private $draught = 0;
+
+       // Konstruktor
+       protected function __construct ($className) {
+               // Eltern-Konstrutor aufrufen
+               parent::__construct($className);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/docks/.htaccess b/application/shipsimu/main/constructions/docks/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/docks/class_DryDock.php b/application/shipsimu/main/constructions/docks/class_DryDock.php
new file mode 100644 (file)
index 0000000..c9d6f8e
--- /dev/null
@@ -0,0 +1,36 @@
+<?php
+/**
+ * A dry dock where ships can be repaired, repainted or modified in.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 DryDock extends BaseConstruction {
+       // Zugewiesener Hafen
+       private $harborInstance = null;
+
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/harbors/.htaccess b/application/shipsimu/main/constructions/harbors/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/harbors/class_Harbor.php b/application/shipsimu/main/constructions/harbors/class_Harbor.php
new file mode 100644 (file)
index 0000000..cf350ce
--- /dev/null
@@ -0,0 +1,87 @@
+<?php
+/**
+ * A harbor class suitable for all kind of harbors
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Harbor extends BaseConstruction {
+       // Namen des Hafens (z.B. Hamburger Hafen)
+       private $harborName = "Unbekannter Hafen";
+
+       // Schiffsliste aller gebauten Schiffe
+       private $constructedShips = null;
+
+       // Liegeplatz-Liste
+       private $berthList = null;
+
+       // List of all assigned shipyards
+       private $shipyardList = null;
+
+       // Constructor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Creates a harbor
+       public static final function createHarbor ($harborName) {
+               // Hafen-Instanz holen
+               $harborInstance = new Harbor();
+
+               // Hafenname setzen
+               $harborInstance->setHarborName($harborName);
+
+               // Werftliste initialisieren
+               $harborInstance->createshipyardList();
+
+               // Instanz zurueckliefern
+               return $harborInstance;
+       }
+
+       // Werft-Liste generieren
+       public function createshipyardList () {
+               $this->shipyardList = new FrameworkArrayObject("FakedShipyardList");
+       }
+
+       // Setter fuer Hafennamen
+       public final function setHarborName ($harborName) {
+               $this->harborName = (string) $harborName;
+       }
+
+       // Getter fuer Hafennamen
+       public final function getHarborName () {
+               return $this->harborName;
+       }
+
+       // Werft in den Hafen einbauen und Werft->Reederei zuweisen
+       public function addNewShipyardNotify ($shipyardName, ShippingCompany $companyInstance) {
+               // Werft generieren und in die Werftliste aufnehmen
+               $this->shipyardList->append(Shipyard::createShipyardNotify($this, $shipyardName, $companyInstance));
+       }
+
+       // Werft in den Hafen einbauen ohne Zuweisung einer Reederei (gehoert der "Stadt" dann)
+       public function addNewShipyard ($shipyardName) {
+               // Werft generieren und in die Werftliste aufnehmen
+               $this->shipyardList->append(Shipyard::createShipyard($this, $shipyardName));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/terminals/.htaccess b/application/shipsimu/main/constructions/terminals/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/terminals/class_Terminal.php b/application/shipsimu/main/constructions/terminals/class_Terminal.php
new file mode 100644 (file)
index 0000000..9ae9985
--- /dev/null
@@ -0,0 +1,36 @@
+<?php
+/**
+ * A terminal class where ships can land and passengers can board the ship
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Terminal extends BaseConstruction {
+       // Zugewiesener Hafen
+       private $harborInstance = null;
+
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/constructions/yards/.htaccess b/application/shipsimu/main/constructions/yards/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/constructions/yards/class_Shipyard.php b/application/shipsimu/main/constructions/yards/class_Shipyard.php
new file mode 100644 (file)
index 0000000..1959f83
--- /dev/null
@@ -0,0 +1,215 @@
+<?php
+/**
+ * A shipyard construction class which can be used for constructing all kinds of
+ * ships.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Shipyard extends BaseConstruction {
+       // Werft-Name
+       private $shipyardName    = "Namenlose Werft";
+
+       // Arbeiter-Liste
+       private $staffList = null;
+
+       // Queue-Liste fuer zu bauende Schiffe
+       private $queueList = null;
+
+       // Aktuell im Bau befindliches Schiff
+       private $currShipInConst = null;
+
+       // Liste konstruierbarer Schiffstypen
+       private $shipTypeList = null;
+
+       // Zugewiesener Hafen
+       private $harborInstance = null;
+
+       // Zugewiesene Reederei
+       private $shippingCompany = null;
+
+       // Constructor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+
+               // Staff-Liste/Schiffstyp-Liste erzeugen
+               $this->createStaffList();
+               $this->createShipTypeList();
+       }
+
+       // Create a shipyard and notify it about it's owner
+       public static final function createShipyardNotify (Harbor $harborInstance, $shipyardName, ShippingCompany $companyInstance) {
+               // Werft-Instanz holen
+               $shipyardInstance = self::createShipyard($harborInstance, $shipyardName);
+
+               // Reederei der Werft zuweisen
+               $shipyardInstance->setCompanyInstance($companyInstance);
+
+               // Die Reederei ueber ihre Werft informieren
+               $companyInstance->addNewShipyard($shipyardInstance);
+
+               // Instanz zurueckgeben
+               return $shipyardInstance;
+       }
+
+       // Create a shipyard, first we need to create a harbor
+       public static final function createShipyard (Harbor $harborInstance, $shipyardName) {
+               // Instanz temporaer holen
+               $shipyardInstance = new Shipyard();
+
+               // Debug message
+               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Eine Werft mit dem Namen <strong>%s</strong> wird im Hafen <strong>%s</strong> konstruiert.",
+                       __CLASS__,
+                       __LINE__,
+                       $shipyardName,
+                       $harborInstance->getHarborName()
+               ));
+
+               // Werft-Name setzen
+               $shipyardInstance->setShipyardName($shipyardName);
+
+               // Hafen-Instanz setzen
+               $shipyardInstance->setHarborInstance($harborInstance);
+
+               // Abmasse setzen in Meter
+               $shipyardInstance->setWidth(30);
+               $shipyardInstance->setHeight(30);
+               $shipyardInstance->setLength(100);
+
+               // Clean up a little
+               $shipyardInstance->removeDraught();
+
+               // Debug-Meldung
+               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> wurde gebaut.",
+                       __CLASS__,
+                       __LINE__,
+                       $shipyardName
+               ));
+
+               // Instanz zurueckliefern
+               return $shipyardInstance;
+       }
+
+       // Create staff list
+       private function createStaffList () {
+               $this->staffList = new FrameworkArrayObject("FakedStaffList");
+       }
+
+       // Create ship type list
+       private function createShipTypeList () {
+               $this->shipTypeList = new FrameworkArrayObject("FakedShipTypeList");
+       }
+
+       // Setter-Methode fuer Werft-Name
+       public final function setShipyardName ($shipyardName) {
+               $this->shipyardName = (string) $shipyardName;
+       }
+
+       // Getter-Methode fuer Werft-Name
+       public final function getShipyardName () {
+               return $this->shipyardName;
+       }
+
+       // Setter-Methode fuer Hafen-Instanz
+       public final function setHarborInstance (Harbor $harborInstance) {
+               $this->harborInstance = $harborInstance;
+       }
+
+       // Getter-Methode fuer Hafen-Instanz
+       public final function getHarborInstance () {
+               return $this->harborInstance;
+       }
+
+       // Setter fuer Reederei-Instanz
+       public final function setCompanyInstance (ShippingCompany $companyInstance) {
+               $this->shippingCompany = $companyInstance;
+       }
+
+       // Getter fuer Reederei-Instanz
+       public final function getCompanyInstance () {
+               return $this->shippingCompany;
+       }
+
+       // Add new personell
+       public function addNewPersonell ($personell) {
+               // Add to list
+               $this->staffList->append($personell);
+       }
+
+       // Add a new ship type to our list
+       public function addNewConstructableShipType ($shipType) {
+               // This must be a string!
+               $shipType = (string) $shipType;
+
+               // Debug message
+               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> kann bald Schiffe vom Typ <strong>%s</strong> bauen.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getShipyardName(),
+                       $shipType
+               ));
+
+               // Add to list
+               $this->shipTypeList->append($shipType);
+       }
+
+       // Is the specified ship type in our list?
+       public function isShipTypeConstructable ($shipType) {
+               // First we can't build this ship
+               $result = false;
+
+               // This must be a string!
+               $shipType = (string) $shipType;
+
+               // Debug message
+               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> pr&uuml;ft, ob Schiffe vom Typ <strong>%s</strong> baubar sind.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getShipyardName(),
+                       $shipType
+               ));
+
+               // Iterate through all types
+               for ($idx = $this->shipTypeList->getIterator(); $idx->valid(); $idx->next()) {
+                       // Get current ship type
+                       $type = (string) $idx->current();
+
+                       // Is both the same?
+                       $result = ($type == $shipType);
+
+                       // Type is found?
+                       if ($result) break; // Then abort the search!
+               }
+
+               // Debug message
+               if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> hat die Suche nach dem Schiffstyp <strong>%s</strong> abgeschlossen.",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getShipyardName(),
+                       $shipType
+               ));
+
+               // Return result
+               return $result;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/controller/.htaccess b/application/shipsimu/main/controller/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/controller/web/.htaccess b/application/shipsimu/main/controller/web/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/controller/web/class_WebCompanyController.php b/application/shipsimu/main/controller/web/class_WebCompanyController.php
new file mode 100644 (file)
index 0000000..c5f1e2d
--- /dev/null
@@ -0,0 +1,106 @@
+<?php
+/**
+ * Controller for company requests
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebCompanyController 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
+        * @todo        Add some filters to this controller
+        */
+       public static final function createWebCompanyController (CommandResolver $resolverInstance) {
+               // Create the instance
+               $controllerInstance = new WebCompanyController();
+
+               // Set the command resolver
+               $controllerInstance->setResolverInstance($resolverInstance);
+
+               // User auth filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // User update filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_update_filter'));
+
+               // News fetcher filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_download_filter'));
+
+               // News proccess/display-preparation
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_process_filter'));
+
+               // 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 from the resolver by sending a request instance to the resolver
+               $commandInstance = $this->getResolverInstance()->resolveCommandByRequest($requestInstance);
+
+               // Add more filters by the command
+               $commandInstance->addExtraFilters($this, $requestInstance);
+
+               // Try to run the pre filters, if auth exceptions come through redirect here
+               try {
+                       // Run the pre filters
+                       $this->executePreFilters($requestInstance, $responseInstance);
+               } catch (UserAuthorizationException $e) {
+                       // Redirect to main page
+                       $responseInstance->redirectToConfiguredUrl('login_failed');
+
+                       // Exit here
+                       exit();
+               }
+
+               // This request was valid! :-D
+               $requestInstance->requestIsValid();
+
+               // Execute the command
+               $commandInstance->execute($requestInstance, $responseInstance);
+
+               // Run the pre filters
+               $this->executePostFilters($requestInstance, $responseInstance);
+
+               // Flush the response out
+               $responseInstance->flushBuffer();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/controller/web/class_WebGovernmentFailedController.php b/application/shipsimu/main/controller/web/class_WebGovernmentFailedController.php
new file mode 100644 (file)
index 0000000..c51bf1c
--- /dev/null
@@ -0,0 +1,106 @@
+<?php
+/**
+ * Controller for failed government requests
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebGovernmentFailedController 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
+        * @todo        Add some filters to this controller
+        */
+       public static final function createWebGovernmentFailedController (CommandResolver $resolverInstance) {
+               // Create the instance
+               $controllerInstance = new WebGovernmentFailedController();
+
+               // Set the command resolver
+               $controllerInstance->setResolverInstance($resolverInstance);
+
+               // User auth filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_auth_filter'));
+
+               // User update filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_update_filter'));
+
+               // News fetcher filter
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_download_filter'));
+
+               // News proccess/display-preparation
+               $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('news_process_filter'));
+
+               // 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 from the resolver by sending a request instance to the resolver
+               $commandInstance = $this->getResolverInstance()->resolveCommandByRequest($requestInstance);
+
+               // Add more filters by the command
+               $commandInstance->addExtraFilters($this, $requestInstance);
+
+               // Try to run the pre filters, if auth exceptions come through redirect here
+               try {
+                       // Run the pre filters
+                       $this->executePreFilters($requestInstance, $responseInstance);
+               } catch (UserAuthorizationException $e) {
+                       // Redirect to main page
+                       $responseInstance->redirectToConfiguredUrl('login_failed');
+
+                       // Exit here
+                       exit();
+               }
+
+               // This request was valid! :-D
+               $requestInstance->requestIsValid();
+
+               // Execute the command
+               $commandInstance->execute($requestInstance, $responseInstance);
+
+               // Run the pre filters
+               $this->executePostFilters($requestInstance, $responseInstance);
+
+               // Flush the response out
+               $responseInstance->flushBuffer();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/drives/.htaccess b/application/shipsimu/main/drives/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/drives/class_BaseDrive.php b/application/shipsimu/main/drives/class_BaseDrive.php
new file mode 100644 (file)
index 0000000..56f9802
--- /dev/null
@@ -0,0 +1,64 @@
+<?php
+/**
+ * A general drive class for all kind of "drives".
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseDrive extends BaseSimulator {
+       // Price of this drive
+       private $price      = 0.00;
+       // PS-Zahl
+       private $horsePower = 0;
+       // Anzahl Nocken
+       private $numCams    = 0;
+
+       // Konstruktor
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Setter-Methode fuert PS-Zahl
+       public final function setHorsePower ($hp) {
+               $this->horsePower = (int) $hp;
+       }
+
+       // Setter-Methode fuer Nockenanzahl
+       public final function setNumCams ($cams) {
+               $this->numCams = (int) $cams;
+       }
+
+       // Setter for price
+       public final function setPrice ($price) {
+               $this->price = (float) $price;
+       }
+
+       // Getter for price
+       public final function getPrice () {
+               return $this->price;
+       }
+
+       public final function removePrice () {
+               unset($this->price);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/drives/motor/.htaccess b/application/shipsimu/main/drives/motor/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/drives/motor/class_Motor.php b/application/shipsimu/main/drives/motor/class_Motor.php
new file mode 100644 (file)
index 0000000..2f3479e
--- /dev/null
@@ -0,0 +1,56 @@
+<?php
+/**
+ * A motorized drive for bigger ships
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Motor extends BaseDrive implements TradeableItem, ConstructableShipPart {
+       // Constructor
+       protected function __construct() {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Einen Motor erstellen
+       public static final function createMotor ($descr, $hp, $cams, $w, $h, $l) {
+               // Get new instance
+               $motorInstance = new Motor();
+
+               // Beschreibung und Abmasse setzen
+               $motorInstance->setWidth($w);
+               $motorInstance->setHeight($h);
+               $motorInstance->setLength($l);
+
+               // Weitere Daten setzen
+               $motorInstance->setHorsePower($hp);
+               $motorInstance->setNumCams($cams);
+
+               // Instanz zurueckgeben
+               return $motorInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/factories/.htaccess b/application/shipsimu/main/factories/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/factories/class_ShipSimuWebNewsFactory.php b/application/shipsimu/main/factories/class_ShipSimuWebNewsFactory.php
new file mode 100644 (file)
index 0000000..e42b021
--- /dev/null
@@ -0,0 +1,60 @@
+<?php
+/**
+ * A class for the special news object factory
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuWebNewsFactory extends BaseFrameworkSystem {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return              $factoryInstance        An instance of this class
+        */
+       public static final function createShipSimuWebNewsFactory () {
+               // Get a new instance
+               $factoryInstance = new ShipSimuWebNewsFactory();
+
+               // Return the prepared instance
+               return $factoryInstance;
+       }
+
+       /**
+        * Create the news object itself here depending on the request
+        *
+        * @param       $requestInstance        An instance of a request class
+        * @return      $newsInstance           An instance of a news class
+        */
+       public function createNewObject (Requestable $requestInstance) {
+               // Do some stuff here
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/.htaccess b/application/shipsimu/main/filter/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/book/.htaccess b/application/shipsimu/main/filter/book/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/book/refill/.htaccess b/application/shipsimu/main/filter/book/refill/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php b/application/shipsimu/main/filter/book/refill/class_RefillRequestCurrencyTestBookFilter.php
new file mode 100644 (file)
index 0000000..b7ff113
--- /dev/null
@@ -0,0 +1,72 @@
+<?php
+/**
+ * A filter for currency booking in refill requests. This filter shall "book" the
+ * requested amount of points directly on the users account. This filter is for
+ * testing/developing only and was needed for the first developement stage of the
+ * game. You should not really use this filter on your "live-system".
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 RefillRequestCurrencyTestBookFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance         An instance of this filter class
+        */
+       public static final function createRefillRequestCurrencyTestBookFilter () {
+               // Get a new instance
+               $filterInstance = new RefillRequestCurrencyTestBookFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Add code being executed in this filter
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Get the user instance from registry
+               $userInstance = Registry::getRegistry()->getInstance('user');
+
+               // Run the update
+               $userInstance->bookAmountDirectly($requestInstance);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/class_ b/application/shipsimu/main/filter/class_
new file mode 100644 (file)
index 0000000..20653ff
--- /dev/null
@@ -0,0 +1,65 @@
+<?php
+/**
+ * A filter for money refill page
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 ???Filter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance         An instance of this filter class
+        */
+       public final static function create???Filter () {
+               // Get a new instance
+               $filterInstance = new ???Filter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Add code being executed in this filter
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               $this->partialStub("Add code here for your specific filter.");
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/class_BaseShipSimuFilter.php b/application/shipsimu/main/filter/class_BaseShipSimuFilter.php
new file mode 100644 (file)
index 0000000..7a80cf2
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A general filter class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseShipSimuFilter extends BaseFilter {
+       /**
+        * Protected constructor
+        *
+        * @param       $className      Name of the filter class
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Add something to do on every filter
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Add something to do on every filter
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/government/.htaccess b/application/shipsimu/main/filter/government/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php b/application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysStartupHelpFilter.php
new file mode 100644 (file)
index 0000000..7becf12
--- /dev/null
@@ -0,0 +1,78 @@
+<?php
+/**
+ * A filter for checking if government can pay startup helps
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuGovernmentPaysStartupHelpFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance                 An instance of this filter class
+        */
+       public static final function createShipSimuGovernmentPaysStartupHelpFilter () {
+               // Get a new instance
+               $filterInstance = new ShipSimuGovernmentPaysStartupHelpFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Get the user instance from registry
+               $userInstance = Registry::getRegistry()->getInstance('user');
+
+               // Now simply check for it
+               if ((!$userInstance instanceof ManageableMember) || ($userInstance->ifGovernmentPaysStartupHelp() === false)) {
+                       // Request is invalid
+                       $requestInstance->requestIsValid(false);
+
+                       // Redirect to configured URL
+                       $responseInstance->redirectToConfiguredUrl('login_government_startup_failed');
+
+                       // Stop processing here
+                       exit();
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php b/application/shipsimu/main/filter/government/class_ShipSimuGovernmentPaysTrainingFilter.php
new file mode 100644 (file)
index 0000000..75eb1cc
--- /dev/null
@@ -0,0 +1,78 @@
+<?php
+/**
+ * A filter for checking if government can pay a training for current user
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuGovernmentPaysTrainingFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance                 An instance of this filter class
+        */
+       public static final function createShipSimuGovernmentPaysTrainingFilter () {
+               // Get a new instance
+               $filterInstance = new ShipSimuGovernmentPaysTrainingFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        0% done
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Get the user instance from registry
+               $userInstance = Registry::getRegistry()->getInstance('user');
+
+               // Now simply check for it
+               if ((!$userInstance instanceof ManageableMember) || ($userInstance->ifGovernmentPaysTraining() === false)) {
+                       // Request is invalid
+                       $requestInstance->requestIsValid(false);
+
+                       // Redirect to configured URL
+                       $responseInstance->redirectToConfiguredUrl('login_government_training_failed');
+
+                       // Stop processing here
+                       exit();
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/page/.htaccess b/application/shipsimu/main/filter/page/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/page/class_RefillPageFilter.php b/application/shipsimu/main/filter/page/class_RefillPageFilter.php
new file mode 100644 (file)
index 0000000..d4680ba
--- /dev/null
@@ -0,0 +1,75 @@
+<?php
+/**
+ * A filter for money refill page
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 RefillPageFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance                 An instance of this filter class
+        */
+       public static final function createRefillPageFilter () {
+               // Get a new instance
+               $filterInstance = new RefillPageFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @throws      FilterChainException    If this filter fails to operate
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Is the configuration variable set?
+               if ($this->getConfigInstance()->getConfigEntry('refill_page_active') === "N") {
+                       // Password is empty
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('refill_page_not_active');
+
+                       // Abort here
+                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/validator/.htaccess b/application/shipsimu/main/filter/validator/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/validator/class_RefillRequestValidatorFilter.php b/application/shipsimu/main/filter/validator/class_RefillRequestValidatorFilter.php
new file mode 100644 (file)
index 0000000..3abd7ba
--- /dev/null
@@ -0,0 +1,76 @@
+<?php
+/**
+ * A filter for validating the refill request
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 RefillRequestValidatorFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance         An instance of this filter class
+        */
+       public static final function createRefillRequestValidatorFilter () {
+               // Get a new instance
+               $filterInstance = new RefillRequestValidatorFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Maybe we need to added some more generic tests on the request here?
+        * @throws      FilterChainException    If this filter fails to operate
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Are all required request fields set?
+               if (($requestInstance->isRequestElementSet('type') === false) || ($requestInstance->isRequestElementSet('amount') === false)) {
+                       // Something important is missing
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('refill_page_required_fields_missing');
+
+                       // Abort here
+                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php b/application/shipsimu/main/filter/validator/class_ShipSimuUserStatusGuestFilter.php
new file mode 100644 (file)
index 0000000..989e1d4
--- /dev/null
@@ -0,0 +1,79 @@
+<?php
+/**
+ * A filter for validating the refill request
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuUserStatusGuestFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance         An instance of this filter class
+        */
+       public static final function createShipSimuUserStatusGuestFilter () {
+               // Get a new instance
+               $filterInstance = new ShipSimuUserStatusGuestFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        * @todo        Maybe we need to added some more generic tests on the request here?
+        * @throws      FilterChainException    If this filter fails to operate
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Get a user instance for comparison
+               $userInstance = Registry::getRegistry()->getInstance('user');
+
+               // Is the user account confirmed?
+               if ($userInstance->getField(UserDatabaseWrapper::DB_COLUMN_USER_STATUS) == $this->getConfigInstance()->getConfigEntry('user_status_guest')) {
+                       // Request is invalid!
+                       $requestInstance->requestIsValid(false);
+
+                       // Redirect to configured URL
+                       $responseInstance->redirectToConfiguredUrl('login_user_status_guest');
+
+                       // Stop processing here
+                       exit();
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/filter/verifier/.htaccess b/application/shipsimu/main/filter/verifier/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/filter/verifier/class_BirthdayVerifierFilter.php b/application/shipsimu/main/filter/verifier/class_BirthdayVerifierFilter.php
new file mode 100644 (file)
index 0000000..51bb4db
--- /dev/null
@@ -0,0 +1,117 @@
+<?php
+/**
+ * A verifier filter for birthday data
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BirthdayVerifierFilter extends BaseShipSimuFilter implements Filterable {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this filter class
+        *
+        * @return      $filterInstance                 An instance of this filter class
+        */
+       public static final function createBirthdayVerifierFilter () {
+               // Get a new instance
+               $filterInstance = new BirthdayVerifierFilter();
+
+               // Return the instance
+               return $filterInstance;
+       }
+
+       /**
+        * Executes the filter with given request and response objects
+        *
+        * @param       $requestInstance        An instance of a class with an Requestable interface
+        * @param       $responseInstance       An instance of a class with an Responseable interface
+        * @return      void
+        */
+       public function execute (Requestable $requestInstance, Responseable $responseInstance) {
+               // Execute the parent execute method
+               parent::execute($requestInstance, $responseInstance);
+
+               // Day of birth set?
+               if (!$requestInstance->isRequestElementSet('birth_day')) {
+                       // Day of birth isn't set
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('day_of_birth_unset');
+               } // END - if
+
+               // Month of birth set?
+               if (!$requestInstance->isRequestElementSet('birth_month')) {
+                       // Month of birth isn't set
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('month_of_birth_unset');
+               } // END - if
+
+               // Year of birth set?
+               if (!$requestInstance->isRequestElementSet('birth_year')) {
+                       // Year of birth isn't set
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('year_of_birth_unset');
+               } // END - if
+
+               // Is the request still valid?
+               if (!$requestInstance->isRequestValid()) {
+                       // Abort here
+                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
+               } // END - if
+
+               // Now comes the final check
+               $birthCheck = mktime(
+                       0,
+                       0,
+                       0,
+                       $requestInstance->getRequestElement('birth_day'),
+                       $requestInstance->getRequestElement('birth_month'),
+                       $requestInstance->getRequestElement('birth_year')
+               );
+
+               // Is there a number or such? (we don't care about the value itself here)
+               if (empty($birthCheck)) {
+                       // Validation has failed
+                       $requestInstance->requestIsValid(false);
+
+                       // Add a message to the response
+                       $responseInstance->addFatalMessage('birthday_invalid');
+
+                       // Abort here
+                       throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/government/.htaccess b/application/shipsimu/main/government/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/government/class_SimplifiedGovernment.php b/application/shipsimu/main/government/class_SimplifiedGovernment.php
new file mode 100644 (file)
index 0000000..8999153
--- /dev/null
@@ -0,0 +1,137 @@
+<?php
+/**
+ * A government class with simplified ways...
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.org
+ * @todo               Find an interface for governments
+ *
+ * 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 SimplifiedGovernment extends BaseFrameworkSystem implements Registerable {
+       // Constants
+       const STATUS_STARTER_HELP    = 'STARTER_HELP';
+       const STATUS_TRAINING        = 'TRAINING';
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this government class by given user instance
+        *
+        * @param       $userInstance           The user instance
+        * @return      $governmentInstance     Instance of the prepared government instance
+        */
+       public static final function createSimplifiedGovernment (ManageableAccount $userInstance) {
+               // Get a new instance
+               $governmentInstance = new SimplifiedGovernment();
+
+               // Set the user instance
+               $governmentInstance->setUserInstance($userInstance);
+
+               // Return the prepared instance
+               return $governmentInstance;
+       }
+
+       /**
+        * Checks wether the government has already payed a training course for te
+        * current user
+        *
+        * @return      $alreadyPayed   Wether the government has already payed
+        * @todo        Needs do check training limit
+        */
+       public function ifGovernmentAlreadyPayedTraining () {
+               // Default is not payed
+               $alreadyPayed = false;
+
+               // Cache startup training limit
+               $trainingLimit = $this->getConfigInstance()->getConfigEntry('government_training_limit');
+
+               // Now get a search criteria and set the user's name as criteria
+               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_USERID  , $this->getUserInstance()->getUserId());
+               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_ACTIVITY, self::STATUS_TRAINING);
+               $searchInstance->setLimit(1);
+
+               // Get a wrapper instance
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
+
+               // Get result back
+               $resultInstance = $wrapperInstance->doSelectByCriteria($searchInstance);
+
+               // Was the query fine?
+               if ($resultInstance->next()) {
+                       // Get entry
+                       $currEntry = $resultInstance->current();
+
+                       // Entry was found so the government can no more pay a training
+                       $alreadyPayed = true;
+               } // END - if
+
+               // Return the result
+               return $alreadyPayed;
+       }
+
+       /**
+        * Checks wether the government has payed maximum of startup helps to the
+        * current user
+        *
+        * @return      $maximumPayed   Wether the government has already payed
+        * @todo        Needs do check help limit
+        */
+       public function ifGovernmentPayedMaxmimumStartupHelp () {
+               // Default is not payed
+               $maximumPayed = false;
+
+               // Cache startup help limit
+               $helpLimit = $this->getConfigInstance()->getConfigEntry('government_startup_help_limit');
+
+               // Now get a search criteria and set the user's name as criteria
+               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_USERID  , $this->getUserInstance()->getUserId());
+               $searchInstance->addCriteria(UserGovernmentDatabaseWrapper::DB_COLUMN_GOV_ACTIVITY, self::STATUS_STARTER_HELP);
+               $searchInstance->setLimit($helpLimit);
+
+               // Get a wrapper instance
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_gov_wrapper_class');
+
+               // Get result back
+               $resultInstance = $wrapperInstance->doSelectByCriteria($searchInstance);
+
+               // Was the query fine?
+               if ($resultInstance->next()) {
+                       // Get entry
+                       $currEntry = $resultInstance->current();
+
+                       // Entry found, so lets have a look if this government wants to again...
+                       $maximumPayed = true;
+               } // END - if
+
+               // Return the result
+               return $maximumPayed;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/login/.htaccess b/application/shipsimu/main/login/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/login/class_ShipSimuGuestLogin.php b/application/shipsimu/main/login/class_ShipSimuGuestLogin.php
new file mode 100644 (file)
index 0000000..16f76ed
--- /dev/null
@@ -0,0 +1,152 @@
+<?php
+/**
+ * A special guest login class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuGuestLogin extends BaseFrameworkSystem implements LoginableUser {
+       /**
+        * The hashed password
+        */
+       private $hashedPassword = '';
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this login class
+        *
+        * @return      $loginInstance  An instance of this login class
+        */
+       public static final function createShipSimuGuestLogin () {
+               // Get a new instance
+               $loginInstance = new ShipSimuGuestLogin();
+
+               // Return the instance
+               return $loginInstance;
+       }
+
+       /**
+        * Logins the user with the given request containing the credential. The
+        * result of the login can be thrown by exception or, if prefered stored
+        * in a boolean attribute which is then readable by a matching getter.
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @param       $responseInstance       An instance of a Responseable class
+        * @return      void
+        * @throws      UserAuthMethodException If wether username nor email login
+        *                                                                              was detected
+        * @throws      MissingMethodException          If a method was not found in the
+        *                                                                              User class
+        * @throws      UserPasswordMismatchException   If the supplied password did not
+        *                                                                              match with the stored password
+        */
+       public function doLogin (Requestable $requestInstance, Responseable $responseInstance) {
+               // By default no method is selected
+               $method = null;
+               $data = "";
+
+               // Detect login method (username or email) and try to get a userinstance
+               if (!is_null($requestInstance->getRequestElement('user'))) {
+                       // Username found!
+                       $method = 'createGuestByUsername';
+                       $data = $requestInstance->getRequestElement('user');
+               } // END - if
+
+               // Is a method detected?
+               if (is_null($method)) {
+                       // Then abort here
+                       throw new UserAuthMethodException($this, self::EXCEPTION_MISSING_METHOD);
+               } elseif (!method_exists($this->getConfigInstance()->getConfigEntry('guest_class'), $method)) {
+                       // The method is invalid!
+                       throw new MissingMethodException(array($this, $method), self::EXCEPTION_MISSING_METHOD);
+               }
+
+               // Get a user instance
+               $userInstance = call_user_func_array(array($this->getConfigInstance()->getConfigEntry('guest_class'), $method), array($data));
+
+               // Remember this new instance in registry
+               Registry::getRegistry()->addInstance('user', $userInstance);
+
+               // Is the password correct?
+               if ($userInstance->ifPasswordHashMatches($requestInstance) === false) {
+                       // Mismatching password
+                       throw new UserPasswordMismatchException(array($this, $userInstance), BaseUser::EXCEPTION_USER_PASS_MISMATCH);
+               } // END - if
+
+               // Now do the real login. This can be cookie- or session-based login
+               // which depends on the admins setting then on the user's taste.
+               // 1) Get a login helper instance
+               $helperInstance = ObjectFactory::createObjectByConfiguredName('login_helper_class', array($requestInstance));
+
+               // 2) Execute the login. This will now login...
+               $helperInstance->executeLogin($responseInstance);
+       }
+
+       /**
+        * Determines wether the login was fine. This is done by checking if 'login' instance is in registry
+        *
+        * @return      $loginDone      Wether the login was fine or not
+        */
+       public function ifLoginWasSuccessfull () {
+               // Is the registry key there?
+               $loginDone = (Registry::getRegistry()->getInstance('login') instanceof Registerable);
+
+               // Return the result
+               return $loginDone;
+       }
+
+       /**
+        * Encrypt given request key or throw an exception if key was not found in
+        * request
+        *
+        * @param       $requestKey             Key in request class
+        * @return      void
+        */
+       public function encryptPassword ($requestKey) {
+               // Check if password is found in request
+               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
+                       // So encrypt the password and store it for later usage in
+                       // the request:
+
+                       // Get the plain password
+                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
+
+                       // Get user instance
+                       $userInstance = Registry::getRegistry()->getInstance('user');
+
+                       // Get a crypto helper and hash the password
+                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword, $userInstance->getPasswordHash());
+
+                       // Store the hash back in request
+                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/login/class_ShipSimuUserLogin.php b/application/shipsimu/main/login/class_ShipSimuUserLogin.php
new file mode 100644 (file)
index 0000000..cf43ef0
--- /dev/null
@@ -0,0 +1,140 @@
+<?php
+/**
+ * A special login class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuUserLogin extends BaseFrameworkSystem implements LoginableUser {
+       /**
+        * The hashed password
+        */
+       private $hashedPassword = '';
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this login class
+        *
+        * @return      $loginInstance  An instance of this login class
+        */
+       public static final function createShipSimuUserLogin () {
+               // Get a new instance
+               $loginInstance = new ShipSimuUserLogin();
+
+               // Return the instance
+               return $loginInstance;
+       }
+
+       /**
+        * Logins the user with the given request containing the credential. The
+        * result of the login can be thrown by exception or, if prefered stored
+        * in a boolean attribute which is then readable by a matching getter.
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @param       $responseInstance       An instance of a Responseable class
+        * @return      void
+        * @throws      UserPasswordMismatchException   If the supplied password did not
+        *                                                                              match with the stored password
+        * @todo        We need to add something here which will make more than one
+        * @todo        guest logins, users who are online but based on the same
+        * @todo        user account.
+        */
+       public function doLogin (Requestable $requestInstance, Responseable $responseInstance) {
+               // By default no method is selected
+               $method = null;
+               $data = "";
+
+               // Get member class
+               $userClass = $this->getConfigInstance()->getConfigEntry('user_class');
+
+               // Get a user instance
+               $userInstance = call_user_func_array(array($userClass, 'createMemberByRequest'), array($requestInstance));
+
+               // Remember this new instance in registry
+               Registry::getRegistry()->addInstance('user', $userInstance);
+
+               // Is the password correct?
+               if ($userInstance->ifPasswordHashMatches($requestInstance) === false) {
+                       // Mismatching password
+                       throw new UserPasswordMismatchException(array($this, $userInstance), BaseUser::EXCEPTION_USER_PASS_MISMATCH);
+               } // END - if
+
+               // ToDo place
+
+               // Now do the real login. This can be cookie- or session-based login
+               // which depends on the admins setting then on the user's taste.
+               // 1) Get a login helper instance
+               $helperInstance = ObjectFactory::createObjectByConfiguredName('login_helper_class', array($requestInstance));
+
+               // 2) Execute the login. This will now login...
+               $helperInstance->executeLogin($responseInstance);
+       }
+
+       /**
+        * Determines wether the login was fine. This is done by checking if 'login' instance is in registry
+        *
+        * @return      $loginDone      Wether the login was fine or not
+        */
+       public function ifLoginWasSuccessfull () {
+               // Is the registry key there?
+               $loginDone = (Registry::getRegistry()->getInstance('login') instanceof Registerable);
+
+               // Return the result
+               return $loginDone;
+       }
+
+       /**
+        * Encrypt given request key or throw an exception if key was not found in
+        * request
+        *
+        * @param       $requestKey             Key in request class
+        * @return      void
+        */
+       public function encryptPassword ($requestKey) {
+               // Check if password is found in request
+               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
+                       // So encrypt the password and store it for later usage in
+                       // the request:
+
+                       // Get the plain password
+                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
+
+                       // Get user instance
+                       $userInstance = Registry::getRegistry()->getInstance('user');
+
+                       // Get a crypto helper and hash the password
+                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword, $userInstance->getPasswordHash());
+
+                       // Store the hash back in request
+                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/login/helper/.htaccess b/application/shipsimu/main/login/helper/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/login/helper/class_ShipSimuLoginHelper.php b/application/shipsimu/main/login/helper/class_ShipSimuLoginHelper.php
new file mode 100644 (file)
index 0000000..b5c125e
--- /dev/null
@@ -0,0 +1,114 @@
+<?php
+/**
+ * A helper for Ship-Simu to login. This login helper first checks what setting
+ * (cookie or session) the admin has choosen then overwrites it with the setting
+ * from current user. The registry instance should hold an instance of this user
+ * class at key 'user' else an exception will be thrown. After this the setting
+ * from a login form will be taken as login method and be stored in database
+ * for later usage.
+ *
+ * The user shall be able to choose "Default login method" or similar to use his
+ * own login method.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLoginHelper extends BaseLoginHelper implements HelpableLogin {
+       /**
+        * The login method we shall choose
+        */
+       private $authMethod = "";
+
+       // Exception constants
+       const EXCEPTION_INVALID_USER_INSTANCE = 0x190;
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class by given request instance
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @return      $helperInstance         An instance of this helper class
+        * @throws      UserInstanceMissingException    If the user instance in registry
+        *                                                                                      is missing or invalid
+        */
+       public static final function createShipSimuLoginHelper (Requestable $requestInstance) {
+               // Get a new instance first
+               $helperInstance = new ShipSimuLoginHelper();
+
+               // Get a user instance from registry
+               $userInstance = Registry::getRegistry()->getInstance('user');
+
+               // Is this instance valid?
+               if (!$userInstance instanceof ManageableAccount) {
+                       // Thrown an exception here
+                       throw new UserInstanceMissingException (array($helperInstance, 'user'), self::EXCEPTION_INVALID_USER_INSTANCE);
+               } // END - if
+
+               // Set default login method from config
+               $helperInstance->setDefaultAuthMethod();
+
+               // Set request instance
+               $helperInstance->setRequestInstance($requestInstance);
+
+               // Return the prepared instance
+               return $helperInstance;
+       }
+
+       /**
+        * Setter for default login method from config
+        *
+        * @return      void
+        */
+       protected function setDefaultAuthMethod () {
+               $this->authMethod = $this->getConfigInstance()->getConfigEntry('auth_method_class');
+       }
+
+       /**
+        * Execute the login request by given response instance. This instance can
+        * be used for sending cookies or at least the session id out.
+        *
+        * @param       $responseInstance       An instance of a Responseable class
+        * @return      void
+        */
+       public function executeLogin (Responseable $responseInstance) {
+               // Get an instance from the login method
+               $loginInstance = ObjectFactory::createObjectByName($this->authMethod, array($responseInstance));
+
+               // Set user cookie
+               $loginInstance->setUserAuth($this->getRequestInstance()->getRequestElement('username'));
+
+               // Set password cookie
+               $loginInstance->setPasswordAuth($this->getRequestInstance()->getRequestElement('pass_hash'));
+
+               // Remember this login instance for later usage
+               Registry::getRegistry()->addInstance('login', $loginInstance);
+       }
+}
+
+//
+?>
diff --git a/application/shipsimu/main/menu/.htaccess b/application/shipsimu/main/menu/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/menu/class_ShipSimu b/application/shipsimu/main/menu/class_ShipSimu
new file mode 100644 (file)
index 0000000..93970de
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A ??? menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 ShipSimu???Menu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public final static function createShipSimu???Menu () {
+               // Get a new instance
+               $menuInstance = new ShipSimu???Menu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuConfirmMenu.php b/application/shipsimu/main/menu/class_ShipSimuConfirmMenu.php
new file mode 100644 (file)
index 0000000..1dc56b7
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A Confirm menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuConfirmMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuConfirmMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuConfirmMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuHomeMenu.php b/application/shipsimu/main/menu/class_ShipSimuHomeMenu.php
new file mode 100644 (file)
index 0000000..ef01389
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuHomeMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuHomeMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuHomeMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuLoginAreaMenu.php b/application/shipsimu/main/menu/class_ShipSimuLoginAreaMenu.php
new file mode 100644 (file)
index 0000000..038b123
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLoginAreaMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuLoginAreaMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuLoginAreaMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuLoginFailedMenu.php b/application/shipsimu/main/menu/class_ShipSimuLoginFailedMenu.php
new file mode 100644 (file)
index 0000000..6978654
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A LoginFailed menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLoginFailedMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuLoginFailedMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuLoginFailedMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuLoginMenu.php b/application/shipsimu/main/menu/class_ShipSimuLoginMenu.php
new file mode 100644 (file)
index 0000000..7aa83e9
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLoginMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuLoginMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuLoginMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuLogoutMenu.php b/application/shipsimu/main/menu/class_ShipSimuLogoutMenu.php
new file mode 100644 (file)
index 0000000..76b6c68
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuLogoutMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuLogoutMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuLogoutMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuRegisterMenu.php b/application/shipsimu/main/menu/class_ShipSimuRegisterMenu.php
new file mode 100644 (file)
index 0000000..d2438f2
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuRegisterMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuRegisterMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuRegisterMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/class_ShipSimuStatusMenu.php b/application/shipsimu/main/menu/class_ShipSimuStatusMenu.php
new file mode 100644 (file)
index 0000000..fbc0434
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A Status menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuStatusMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuStatusMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuStatusMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/menu/government/.htaccess b/application/shipsimu/main/menu/government/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php b/application/shipsimu/main/menu/government/class_ShipSimuGovernmentFailedAreaMenu.php
new file mode 100644 (file)
index 0000000..0d2112c
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A menu class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuGovernmentFailedAreaMenu extends BaseMenu implements RenderableMenu {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this class
+        *
+        * @return      $menuInstance   An instance of this class
+        */
+       public static final function createShipSimuGovernmentFailedAreaMenu () {
+               // Get a new instance
+               $menuInstance = new ShipSimuGovernmentFailedAreaMenu();
+
+               // Return the prepared instance
+               return $menuInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/opening/.htaccess b/application/shipsimu/main/opening/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/opening/bank/.htaccess b/application/shipsimu/main/opening/bank/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/opening/bank/class_MoneyBankRealtimeOpening.php b/application/shipsimu/main/opening/bank/class_MoneyBankRealtimeOpening.php
new file mode 100644 (file)
index 0000000..5136767
--- /dev/null
@@ -0,0 +1,63 @@
+<?php
+/**
+ * A class for the money bank's opening times
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 MoneyBankRealtimeOpening extends BaseOpening {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this opening time class
+        *
+        * @param       $bankInstance           An instance of a money bank
+        * @return      $openeningInstance      An instance of this class
+        */
+       public static final function createMoneyBankRealtimeOpening (BaseBank $bankInstance) {
+               // Get a new instance
+               $openingInstance = new MoneyBankRealtimeOpening();
+
+               // Set the bank instance here
+               $openingInstance->setBankInstance($bankInstance);
+
+               // Return the prepared instance
+               return $openingInstance;
+       }
+
+       /**
+        * Checks wether we are within the opening times
+        *
+        * @return      $withinOpeningTimes             Wether we are within opening times
+        */
+       public function ifWithinOpeningTimes () {
+               $this->partialStub();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/opening/class_ b/application/shipsimu/main/opening/class_
new file mode 100644 (file)
index 0000000..b9f1ce7
--- /dev/null
@@ -0,0 +1,50 @@
+<?php
+/**
+ * A ??? opening times class
+ *
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @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 ???Opening extends BaseOpening {
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this opening time class
+        *
+        * @return      $openeningInstance      An instance of this class
+        */
+       public final static function create???Opening () {
+               // Get a new instance
+               $openeningInstance = new ???Opening();
+
+               // Return the prepared instance
+               return $openeningInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/opening/class_BaseOpening.php b/application/shipsimu/main/opening/class_BaseOpening.php
new file mode 100644 (file)
index 0000000..78f8983
--- /dev/null
@@ -0,0 +1,60 @@
+<?php
+/**
+ * A general opening time class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+abstract class BaseOpening extends BaseFrameworkSystem {
+       /**
+        * A bank instance
+        */
+       private $bankInstance = null;
+
+       /**
+        * Protected constructor
+        *
+        * @param       $className      The class' real name
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Setter for bank instance
+        *
+        * @param       $bankInstance   An instance of a bank
+        * @return      void
+        */
+       protected final function setBankInstance (BaseBank $bankInstance) {
+               $this->bankInstance = $bankInstance;
+       }
+
+       /**
+        * Checks wether we are within the opening times
+        *
+        * @return      $withinOpeningTimes             Wether we are within opening times
+        */
+       public abstract function ifWithinOpeningTimes ();
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/parts/.htaccess b/application/shipsimu/main/parts/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/parts/class_BaseShipPart.php b/application/shipsimu/main/parts/class_BaseShipPart.php
new file mode 100644 (file)
index 0000000..aca83a9
--- /dev/null
@@ -0,0 +1,51 @@
+<?php
+/**
+ * This is a general ship part which can be used for all other ship parts...
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseShipPart extends BaseSimulator {
+       // Price of this ship part
+       private $price = 0.00;
+
+       // Konstruktor
+       protected function __construct($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Setter for price
+       public final function setPrice ($price) {
+               $this->price = (float) $price;
+       }
+
+       // Getter for price
+       public final function getPrice () {
+               return $this->price;
+       }
+
+       // Remove price
+       public final function removePrice () {
+               unset($this->price);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/parts/maschineroom/.htaccess b/application/shipsimu/main/parts/maschineroom/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/parts/maschineroom/class_MaschineRoom.php b/application/shipsimu/main/parts/maschineroom/class_MaschineRoom.php
new file mode 100644 (file)
index 0000000..bcd7b30
--- /dev/null
@@ -0,0 +1,47 @@
+<?php
+/**
+ * A maschine room class for really huge ships
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 MaschineRoom extends BaseShipPart {
+       // Constructor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Maschinenraum erstellen
+       public static final function createMaschineRoom () {
+               // Get new instance
+               $roomInstance = new MaschineRoom();
+
+               // Umrechnungsfaktoren setzen
+               $roomInstance->setResizeFactorElement('width' , 1.3);
+               $roomInstance->setResizeFactorElement('height', 1.8);
+               $roomInstance->setResizeFactorElement('length', 1.3);
+
+               // Instanz zurueckgeben
+               return $roomInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/personell/.htaccess b/application/shipsimu/main/personell/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/personell/class_SimulatorPersonell.php b/application/shipsimu/main/personell/class_SimulatorPersonell.php
new file mode 100644 (file)
index 0000000..8ff01e7
--- /dev/null
@@ -0,0 +1,327 @@
+<?php
+/**
+ * The general simulator personell class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 SimulatorPersonell extends BasePersonell {
+       // Personell list
+       private $personellList = null;
+
+       // A cache for lists
+       private $cacheList = null;
+
+       // A string for cached conditions
+       private $cacheCond = null;
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Magic wake-up method called when unserialize() is called. This is
+        * neccessary because in this case a personell does not need to know the
+        * min/max ages range and system classes. This would anyway use more RAM
+        * what is not required.
+        *
+        * @return      void
+        */
+       public function __wakeup () {
+               // Tidy up a little
+               $this->removePersonellList();
+               $this->removeMinMaxAge();
+               $this->removeCache();
+       }
+
+       /**
+        * Generate a specified amount of personell and return the prepared instance
+        *
+        * @param               $amountPersonell                Number of personell we shall
+        *                                                              generate
+        * @return      $personellInstance              An instance of this object with a
+        *                                                              list of personells
+        */
+       public static final function createSimulatorPersonell ($amountPersonell) {
+               // Make sure only integer can pass
+               $amountPersonell = (int) $amountPersonell;
+
+               // Get a new instance
+               $personellInstance = new SimulatorPersonell();
+
+               // Debug message
+               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $personellInstance->debugOutput(sprintf("[%s:%d] Es werden <strong>%d</strong> Personal bereitgestellt.",
+                       __CLASS__,
+                       __LINE__,
+                       $amountPersonell
+               ));
+
+               // Initialize the personell list
+               $personellInstance->createPersonellList();
+
+               // Create requested amount of personell
+               for ($idx = 0; $idx < $amountPersonell; $idx++) {
+                       $personellInstance->addRandomPersonell();
+               }
+
+               // Debug message
+               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $personellInstance->debugOutput(sprintf("[%s:%d] <strong>%d</strong> Personal bereitgestellt.",
+                       __CLASS__,
+                       __LINE__,
+                       $amountPersonell
+               ));
+
+               // Tidy up a little
+               $personellInstance->removeGender();
+               $personellInstance->removeNames();
+               $personellInstance->removeBirthday();
+               $personellInstance->removeSalary();
+               $personellInstance->removeEmployed();
+               $personellInstance->removeMarried();
+               //$personellInstance->removeCache();
+
+               // Instanz zurueckgeben
+               return $personellInstance;
+       }
+
+       /**
+        * Create a SimulatorPersonell object by loading the specified personell
+        * list from an existing database backend
+        *
+        * @param       $idNumber                       The ID number (only right part) of the list
+        * @return      $personellInstance      An instance of this class
+        * @throws      InvalidIDFormatException        If the given id number
+        *                                                                              $idNumber is invalid
+        * @throws      MissingSimulatorIdException             If an ID number was not found
+        * @deprecated
+        */
+       public static final function createSimulatorPersonellByID ($idNumber) {
+               // Get instance
+               $personellInstance = new SimulatorPersonell(false);
+               $personellInstance->makeDeprecated();
+       }
+
+       // Create personell list
+       public function createPersonellList () {
+               // Is the list already created?
+               if ($this->personelllList instanceof FrameworkArrayObject) {
+                       // Throw an exception
+                       throw new PersonellListAlreadyCreatedException($this, self::EXCEPTION_DIMENSION_ARRAY_INVALID);
+               } // END - if
+
+               // Initialize the array
+               $this->personellList = new FrameworkArrayObject("FakedPersonellList");
+       }
+
+       // Remove the personell list
+       private final function removePersonellList () {
+               unset($this->personellList);
+       }
+
+       // Add new personell object to our list
+       public function addRandomPersonell () {
+               // Gender list...
+               $genders = array("M", "F");
+
+               // Create new personell members
+               $personellInstance = new SimulatorPersonell();
+
+               // Set a randomized gender
+               $personellInstance->setGender($genders[mt_rand(0, 1)]);
+
+               // Set a randomized birthday (maximum age required, see const MAX_AGE)
+               $personellInstance->createBirthday();
+
+               // Married? Same values means: married
+               if (mt_rand(0, 5) == mt_rand(0, 5)) $personellInstance->setMarried(true);
+
+               // Tidy up a little
+               $personellInstance->removePersonellList();
+               $personellInstance->removeMinMaxAge();
+               $personellInstance->removeCache();
+
+               // Add new member to the list
+               $this->personellList->append($personellInstance);
+       }
+
+       /**
+        * Get a specifyable list of our people, null or empty string will be ignored!
+        *
+        * @return      $cacheList      A list of cached personells
+        */
+       function getSpecialPersonellList ($isEmployed = null, $isMarried = null, $hasGender = "") {
+               // Serialize the conditions for checking if we can take the cache
+               $serialized = serialize(array($isEmployed, $isMarried, $hasGender));
+
+               // The same (last) conditions?
+               if (($serialized == $this->cacheCond) && (!is_null($this->cacheCond))) {
+                       if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Gecachte Liste wird verwendet.",
+                               __CLASS__,
+                               __LINE__
+                       ));
+
+                       // Return cached list
+                       return $this->cacheList;
+               }
+
+               // Output debug message
+               if ((defined('DEBUG_PERSONELL')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Personalliste wird nach Kriterien durchsucht...",
+                       __CLASS__,
+                       __LINE__
+               ));
+
+               // Remember the conditions
+               $this->setCacheCond($serialized);
+
+               // Create cached list
+               $this->setAllCacheList(new FrameworkArrayObject('FakedCacheList'));
+
+               // Search all unemployed personells
+               for ($idx = $this->personellList->getIterator(); $idx->valid(); $idx->next()) {
+                       // Element holen
+                       $el = $idx->current();
+
+                       // Check currenylt all single conditions (combined conditions are not yet supported)
+                       if ((!is_null($isEmployed)) && ($el->isEmployed() == $isEmployed)) {
+                               // Add this one (employed status asked)
+                               $this->cacheList->append($el);
+                       } elseif ((!is_null($isMarried)) && ($el->isMarried() == $isMarried)) {
+                               // Add this one (marrital status asked)
+                               $this->cacheList->append($el);
+                       } elseif ((!empty($hasGender)) && ($el->getGender() == $hasGender)) {
+                               // Add this one (specified gender)
+                               $this->cacheList->append($el);
+                       }
+               }
+
+               // Return the completed list
+               return $this->cacheList;
+       }
+
+       /**
+        * Get amount of unemployed personell
+        *
+        * @return      $count  Amount of unemployed personell
+        */
+       public final function getAllUnemployed () {
+               // Get a temporary list
+               $list = $this->getSpecialPersonellList(false);
+
+               // Anzahl zurueckliefern
+               return $list->count();
+       }
+
+       /**
+        * Remove cache things
+        *
+        * @return      void
+        */
+       private function removeCache () {
+               // Remove cache data
+               unset($this->cacheList);
+               unset($this->cacheCond);
+       }
+
+       /**
+        * Setter for cache list
+        *
+        * @param               $cacheList      The new cache list to set or null for initialization/reset
+        * @return      void
+        */
+       private final function setAllCacheList (FrameworkArrayObject $cacheList = null) {
+               $this->cacheList = $cacheList;
+       }
+
+       /**
+        * Setter for cache conditions
+        *
+        * @param               $cacheCond      The new cache conditions to set
+        * @return      void
+        */
+       private final function setCacheCond ($cacheCond) {
+               $this->cacheCond = (string) $cacheCond;
+       }
+
+       /**
+        * Reset cache list
+        *
+        * @return      void
+        */
+       public function resetCache () {
+               $this->setAllCacheList(null);
+               $this->setCacheCond("");
+       }
+
+       /**
+        * Getter for surname. If no surname is set then default surnames are set
+        * for male and female personells.
+        *
+        * @return      $surname        The personell' surname
+        */
+       public final function getSurname () {
+               $surname = parent::getSurname();
+
+               // Make sure every one has a surname...
+               if (empty($surname)) {
+                       if ($this->isMale()) {
+                               // Typical male name
+                               $surname = "John";
+                       } else {
+                               // Typical female name
+                               $surname = "Jennifer";
+                       }
+
+                       // Set typical family name
+                       parent::setFamily("Smith");
+               } // END - if
+
+               // Return surname
+               return $surname;
+       }
+
+       /**
+        * Getter for personell list
+        *
+        * @return      $personellList          The list of all personells
+        */
+       public final function getPersonellList () {
+               return $this->personellList;
+       }
+
+       /**
+        * Loads the mostly pre-cached personell list
+        *
+        * @param       $idNumber       The ID number we shall use for looking up
+        *                                              the right data.
+        * @return      void
+        * @deprecated
+        */
+       public function loadPersonellList ($idNumber) {
+               $this->makeDeprecated();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/personell/company/.htaccess b/application/shipsimu/main/personell/company/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/personell/company/class_CompanyEmployee.php b/application/shipsimu/main/personell/company/class_CompanyEmployee.php
new file mode 100644 (file)
index 0000000..472692e
--- /dev/null
@@ -0,0 +1,85 @@
+<?php
+/**
+ * Campany employees may be handled and payed within this class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 CompanyEmployee extends SimulatorPersonell {
+       // Employeee list
+       private $employeeList = null;
+
+       // Constructor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Generate a specified amount of personell
+       public static final function createCompanyEmployee ($surname, $family, $gender, $year, $month, $day, $married, $salary) {
+               // Get instance
+               $personellInstance = new CompanyEmployee();
+
+               // Debug message
+               if (((defined('DEBUG_COMPANY_EMPLOYEE')) && (defined('DEBUG_PERSONELL'))) || (defined('DEBUG_ALL'))) {
+                       $personellInstance->debugOutput(sprintf("[%s:%d] Der/Die Angestellte <strong>%s %s</strong> wird angelegt.",
+                               __CLASS__,
+                               __LINE__,
+                               $surname,
+                               $family
+                       ));
+               }
+
+               // Ist the given birthday valid?
+               if ($personellInstance->isDateValid($year, $month, $day) === false) {
+                       // Something is wrong ...
+                       throw new BirthdayInvalidException(array($year, $month, $day), self::EXCEPTION_BIRTH_DATE_IS_INVALID);
+               } // END - if
+
+               // Set birthday
+               $personellInstance->setBirthday($year, $month, $day);
+
+               // Set as employed/marrital status
+               $personellInstance->setEmployed(true);
+               $personellInstance->setMarried($married);
+
+               // Set surname/family/gender
+               $personellInstance->setSurname($surname);
+               $personellInstance->setFamily($family);
+               $personellInstance->setGender($gender);
+
+               // Set salary
+               $personellInstance->increaseSalary($salary);
+
+               // Tidy up a little
+               $personellInstance->removeEmployeeList();
+               $personellInstance->removeMinMaxAge();
+
+               // Return prepared instance
+               return $personellInstance;
+       }
+
+       // Remove the employee list
+       private function removeEmployeeList () {
+               unset($this->employeeList);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/registration/.htaccess b/application/shipsimu/main/registration/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/registration/class_ShipSimuRegistration.php b/application/shipsimu/main/registration/class_ShipSimuRegistration.php
new file mode 100644 (file)
index 0000000..674d189
--- /dev/null
@@ -0,0 +1,207 @@
+<?php
+/**
+ * A user registration class specially for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuRegistration extends BaseRegistration implements UserRegister {
+       /**
+        * Hashed password
+        */
+       private $hashedPassword = '';
+
+       /**
+        * Elements for criteria
+        */
+       private $criteriaElements = array(
+               'username',
+               'pass_hash',
+               'email' => 'email1',
+               'surname',
+               'family',
+               'street',
+               'zip',
+               'city',
+               'icq',
+               'jabber',
+               'yahoo',
+               'aol',
+               'msn',
+               'birth_day',
+               'birth_month',
+               'birth_year'
+       );
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Create a new instance
+        *
+        * @return      $registrationInstance   An instance of this registration class
+        */
+       public static final function createShipSimuRegistration () {
+               // Get a new instance
+               $registrationInstance = new ShipSimuRegistration();
+
+               // Initialize the filter chains
+               $registrationInstance->initFilterChains();
+
+               // And return it
+               return $registrationInstance;
+       }
+
+       /**
+        * Encrypt given request key or throw an exception if key was not found in
+        * request
+        *
+        * @param       $requestKey             Key in request class
+        * @return      void
+        */
+       public function encryptPassword ($requestKey) {
+               // Check if password is found in request
+               if ($this->getRequestInstance()->isRequestElementSet($requestKey)) {
+                       // So encrypt the password and store it for later usage in
+                       // the request:
+
+                       // 1.: Get the plain password
+                       $plainPassword = $this->getRequestInstance()->getRequestElement($requestKey);
+
+                       // 2. Get a crypto helper and hash the password
+                       $this->hashedPassword = ObjectFactory::createObjectByConfiguredName('crypto_class')->hashString($plainPassword);
+
+                       // 3. Store the hash back in request
+                       $this->getRequestInstance()->setRequestElement('pass_hash', $this->hashedPassword);
+               }
+       }
+
+       /**
+        * Perform things like informing assigned affilates about new registration
+        * before registration
+        *
+        * @return      void
+        * @todo        Maybe add more things to perform
+        */
+       public function doPreRegistration () {
+               // First run all pre filters
+               $this->executePreFilters();
+       }
+
+       /**
+        * Registers the new user account by insterting the request data into the
+        * database and paying some start credits or throw exceptions if this fails
+        *
+        * @return      void
+        * @todo        Maybe add more things to perform
+        */
+       public function registerNewUser () {
+               // Get a user database wrapper
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_db_wrapper_class');
+
+               // Use this instance to insert the whole registration instance
+               $wrapperInstance->insertRegistrationObject($this);
+       }
+
+       /**
+        * Perform things like notifying partner websites after registration is done
+        *
+        * @return      void
+        * @todo        Maybe add more things to perform
+        */
+       public function doPostRegistration () {
+               // First run all post filters
+               $this->executePostFilters();
+       }
+
+       /**
+        * Do the action which is required after all registration steps are done.
+        * This can be a simple redirect to another webpage or displaying a message
+        * to the user. Or this can be a login step into the newly created account.
+        *
+        * @return      void
+        */
+       public function doPostAction () {
+               // Get an action instance from our factory
+               $actionInstance = ObjectFactory::createObjectByConfiguredName('post_registration_class');
+
+               // Execute the action
+               $actionInstance->execute($this->getRequestInstance(), $this->getResponseInstance());
+       }
+
+       /**
+        * Adds registration elements to a given dataset instance
+        *
+        * @param       $criteriaInstance       An instance of a storeable criteria
+        * @return      void
+        */
+       public function addElementsToDataSet (StoreableCriteria $criteriaInstance) {
+               // Default is unconfirmed!
+               $configEntry = 'user_status_unconfirmed';
+
+               // Is the confirmation process entirely disabled?
+               if ($this->getConfigInstance()->getConfigEntry('confirm_email_enabled') === 'N') {
+                       // No confirmation of email needed
+                       $configEntry = 'user_status_confirmed';
+               } // END - if
+
+               // Add a lot elements to the dataset criteria
+               foreach ($this->criteriaElements as $alias => $element) {
+                       // Do we have an alias?
+                       if (is_string($alias)) {
+                               // Yes, so use it
+                               $criteriaInstance->addCriteria($alias, $this->getRequestInstance()->getRequestElement($element));
+
+                               // Debug message
+                               //* DEBUG: */ $this->debugOutput('ALIAS: alias='.$alias.',element='.$element.'='.$this->getRequestInstance()->getRequestElement($element));
+                       } else {
+                               // No, default entry
+                               $criteriaInstance->addCriteria($element, $this->getRequestInstance()->getRequestElement($element));
+
+                               // Debug message
+                               //* DEBUG: */ $this->debugOutput('DEFAULT: element='.$element.'='.$this->getRequestInstance()->getRequestElement($element));
+                       }
+
+                       // Is this a guest account?
+                       if ((($element == 'username') || ($alias == 'username')) && ($this->getRequestInstance()->getRequestElement($element) == $this->getConfigInstance()->getConfigEntry('guest_login_user'))) {
+                               // Yes, then set the config entry to guest status
+                               $configEntry = 'user_status_guest';
+                       } // END - if
+               } // END - foreach
+
+               // Mark the username as unique key
+               $criteriaInstance->setUniqueKey(UserDatabaseWrapper::DB_COLUMN_USERNAME);
+
+               // Add account status as configured
+               $criteriaInstance->addConfiguredCriteria(UserDatabaseWrapper::DB_COLUMN_USER_STATUS, $configEntry);
+
+               // Include registration timestamp
+               $criteriaInstance->addCriteria('registered', date('Y-m-d H:i:s', time()));
+       }
+}
+
+//
+?>
diff --git a/application/shipsimu/main/resolver/.htaccess b/application/shipsimu/main/resolver/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/resolver/web/.htaccess b/application/shipsimu/main/resolver/web/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/resolver/web/class_WebCompanyCommandResolver.php b/application/shipsimu/main/resolver/web/class_WebCompanyCommandResolver.php
new file mode 100644 (file)
index 0000000..e5fcfb4
--- /dev/null
@@ -0,0 +1,190 @@
+<?php
+/**
+ * A command resolver for local (non-hubbed) web commands including the failed government request
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebCompanyCommandResolver extends BaseCommandResolver implements CommandResolver {
+       /**
+        * Last successfull resolved command
+        */
+       private $lastCommandInstance = null;
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+
+               // Set prefix to "Web"
+               $this->setCommandPrefix('Web');
+       }
+
+       /**
+        * Creates an instance of a Web command resolver with a given default command
+        *
+        * @param       $commandName                            The default command we shall execute
+        * @param       $appInstance                            An instance of a manageable application helper class
+        * @return      $resolverInstance                       The prepared command resolver instance
+        * @throws      EmptyVariableException          Thrown if default command is not set
+        * @throws      InvalidInterfaceException       Thrown if command does not implement interface Commandable
+        */
+       public static final function createWebCompanyCommandResolver ($commandName, ManageableApplication $appInstance) {
+               // Create the new instance
+               $resolverInstance = new WebCompanyCommandResolver();
+
+               // Get request instance
+               $requestInstance = $appInstance->getRequestInstance();
+
+               // Is the variable $commandName set and the command is valid?
+               if (empty($commandName)) {
+                       // Then thrown an exception here
+                       throw new EmptyVariableException(array($resolverInstance, 'commandName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
+               } elseif (!$resolverInstance->resolveCommandByRequest($requestInstance) instanceof Commandable) {
+                       // Invalid command found (missing interface?)
+                       throw new InvalidInterfaceException(array($userInstance, 'ManageableMember'), self::EXCEPTION_REQUIRED_INTERFACE_MISSING);
+               }
+
+               // Set the application instance
+               $resolverInstance->setApplicationInstance($appInstance);
+
+               // Return the prepared instance
+               return $resolverInstance;
+       }
+
+       /**
+        * Returns an command instance for a given request class or null if
+        * it was not found
+        *
+        * @param       $requestInstance        An instance of a request class
+        * @return      $commandInstance        An instance of the resolved command
+        * @throws      InvalidCommandException                         Thrown if $commandName is
+        *                                                                                              invalid
+        * @throws      InvalidCommandInstanceException         Thrown if $commandInstance
+        *                                                                                              is an invalid instance
+        */
+       public function resolveCommandByRequest (Requestable $requestInstance) {
+               // Init instance
+               $commandInstance = null;
+
+               // This goes fine so let's resolv the command
+               $commandName = str_replace('-', '_', $requestInstance->getRequestElement('app')) . '_' . $requestInstance->getRequestElement('page');
+
+               // Is there a "failed" request?
+               if ($requestInstance->isRequestElementSet('failed')) {
+                       // Then include with within the command name
+                       $commandName = $commandName . '_' . $requestInstance->getRequestElement('failed');
+               } // END - if
+
+               // Is the command empty? Then fall back to default command
+               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Check if command is valid
+               if ($this->isCommandValid($commandName) === false) {
+                       // This command is invalid!
+                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Get the command
+               $commandInstance = $this->loadCommand($commandName);
+
+               // And validate it
+               if ((!is_object($commandInstance)) || (!$commandInstance instanceof Commandable)) {
+                       // This command has an invalid instance!
+                       throw new InvalidCommandInstanceException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Set last command
+               $this->lastCommandInstance = $commandInstance;
+
+               // Return the resolved command instance
+               return $commandInstance;
+       }
+
+       /**
+        * Resolves the command by its direct name and returns an instance of its class
+        *
+        * @param       $commandName            The direct command name we shall resolve
+        * @return      $commandInstance        An instance of the command class
+        * @throws      InvalidCommandException         Thrown if $commandName is invalid
+        */
+       public function resolveCommand ($commandName) {
+               // Initiate the instance variable
+               $commandInstance = null;
+
+               // Is the command empty? Then fall back to default command
+               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Check if command is valid
+               if ($this->isCommandValid($commandName) === false) {
+                       // This command is invalid!
+                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               }
+
+               // Get the command
+               $commandInstance = $this->loadCommand($commandName);
+
+               // Return the instance
+               return $commandInstance;
+       }
+
+       /**
+        * "Loads" a given command and instances it if not yet cached
+        *
+        * @param       $commandName                            A command name we shall look for
+        * @return      $commandInstance                        A loaded command instance
+        * @throws      InvalidCommandException         Thrown if even the default
+        *                                                                              command class is missing (bad!)
+        */
+       private function loadCommand ($commandName) {
+               // Cache default command
+               $defaultCommand = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Init command instance
+               $commandInstance = null;
+
+               // Get 'app' from the application
+               $app = Registry::getRegistry()->getInstance('application')->getRequestInstance()->getRequestElement('app');
+
+               // Create command class name
+               $this->setClassName(sprintf("%s%sCommand",
+                       $this->getCommandPrefix(),
+                       $this->convertToClassName($commandName)
+               ));
+
+               // Is this class loaded?
+               if (!class_exists($this->getClassName())) {
+                       // Class not found, so throw an exception
+                       throw new InvalidCommandException(array($this, $defaultCommand), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Initiate the command
+               $commandInstance = ObjectFactory::createObjectByName($this->getClassName(), array($this));
+
+               // Return the result
+               return $commandInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php b/application/shipsimu/main/resolver/web/class_WebGovernmentFailedCommandResolver.php
new file mode 100644 (file)
index 0000000..9456c08
--- /dev/null
@@ -0,0 +1,187 @@
+<?php
+/**
+ * A command resolver for local (non-hubbed) web commands including the failed government request
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 WebGovernmentFailedCommandResolver extends BaseCommandResolver implements CommandResolver {
+       /**
+        * Last successfull resolved command
+        */
+       private $lastCommandInstance = null;
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+
+               // Set prefix to "Web"
+               $this->setCommandPrefix('Web');
+       }
+
+       /**
+        * Creates an instance of a Web command resolver with a given default command
+        *
+        * @param       $commandName                            The default command we shall execute
+        * @param       $appInstance                            An instance of a manageable application helper class
+        * @return      $resolverInstance                       The prepared command resolver instance
+        * @throws      EmptyVariableException          Thrown if default command is not set
+        * @throws      InvalidInterfaceException       Thrown if command does not implement interface Commandable
+        */
+       public static final function createWebGovernmentFailedCommandResolver ($commandName, ManageableApplication $appInstance) {
+               // Create the new instance
+               $resolverInstance = new WebGovernmentFailedCommandResolver();
+
+               // Get request instance
+               $requestInstance = $appInstance->getRequestInstance();
+
+               // Is the variable $commandName set and the command is valid?
+               if (empty($commandName)) {
+                       // Then thrown an exception here
+                       throw new EmptyVariableException(array($resolverInstance, 'commandName'), self::EXCEPTION_UNEXPECTED_EMPTY_STRING);
+               } elseif (!$resolverInstance->resolveCommandByRequest($requestInstance) instanceof Commandable) {
+                       // Invalid command found (missing interface?)
+                       throw new InvalidInterfaceException(array($userInstance, 'ManageableMember'), self::EXCEPTION_REQUIRED_INTERFACE_MISSING);
+               }
+
+               // Set the application instance
+               $resolverInstance->setApplicationInstance($appInstance);
+
+               // Return the prepared instance
+               return $resolverInstance;
+       }
+
+       /**
+        * Returns an command instance for a given request class or null if
+        * it was not found
+        *
+        * @param       $requestInstance        An instance of a request class
+        * @return      $commandInstance        An instance of the resolved command
+        * @throws      InvalidCommandException                         Thrown if $commandName is
+        *                                                                                              invalid
+        * @throws      InvalidCommandInstanceException         Thrown if $commandInstance
+        *                                                                                              is an invalid instance
+        */
+       public function resolveCommandByRequest (Requestable $requestInstance) {
+               // Init instance
+               $commandInstance = null;
+
+               // This goes fine so let's resolv the command
+               $commandName = $requestInstance->getRequestElement('page');
+
+               // Is there a "failed" request?
+               if ($requestInstance->isRequestElementSet('failed')) {
+                       // Then include with within the command name
+                       $commandName = sprintf("%s_%s", $commandName, $requestInstance->getRequestElement('failed'));
+               } // END - if
+
+               // Is the command empty? Then fall back to default command
+               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Check if command is valid
+               if ($this->isCommandValid($commandName) === false) {
+                       // This command is invalid!
+                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Get the command
+               $commandInstance = $this->loadCommand($commandName);
+
+               // And validate it
+               if ((!is_object($commandInstance)) || (!$commandInstance instanceof Commandable)) {
+                       // This command has an invalid instance!
+                       throw new InvalidCommandInstanceException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Set last command
+               $this->lastCommandInstance = $commandInstance;
+
+               // Return the resolved command instance
+               return $commandInstance;
+       }
+
+       /**
+        * Resolves the command by its direct name and returns an instance of its class
+        *
+        * @param       $commandName            The direct command name we shall resolve
+        * @return      $commandInstance        An instance of the command class
+        * @throws      InvalidCommandException         Thrown if $commandName is invalid
+        */
+       public function resolveCommand ($commandName) {
+               // Initiate the instance variable
+               $commandInstance = null;
+
+               // Is the command empty? Then fall back to default command
+               if (empty($commandName)) $commandName = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Check if command is valid
+               if ($this->isCommandValid($commandName) === false) {
+                       // This command is invalid!
+                       throw new InvalidCommandException(array($this, $commandName), self::EXCEPTION_INVALID_COMMAND);
+               }
+
+               // Get the command
+               $commandInstance = $this->loadCommand($commandName);
+
+               // Return the instance
+               return $commandInstance;
+       }
+
+       /**
+        * "Loads" a given command and instances it if not yet cached
+        *
+        * @param       $commandName                            A command name we shall look for
+        * @return      $commandInstance                        A loaded command instance
+        * @throws      InvalidCommandException         Thrown if even the default
+        *                                                                              command class is missing (bad!)
+        */
+       private function loadCommand ($commandName) {
+               // Cache default command
+               $defaultCommand = $this->getConfigInstance()->getConfigEntry('default_web_command');
+
+               // Init command instance
+               $commandInstance = null;
+
+               // Create command class name
+               $this->setClassName(sprintf("%s%sCommand",
+                       $this->getCommandPrefix(),
+                       $this->convertToClassName($commandName)
+               ));
+
+               // Is this class loaded?
+               if (!class_exists($this->getClassName())) {
+                       // Class not found, so throw an exception
+                       throw new InvalidCommandException(array($this, $defaultCommand), self::EXCEPTION_INVALID_COMMAND);
+               } // END - if
+
+               // Initiate the command
+               $commandInstance = ObjectFactory::createObjectByName($this->getClassName(), array($this));
+
+               // Return the result
+               return $commandInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/ships/.htaccess b/application/shipsimu/main/ships/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/ships/class_BaseShip.php b/application/shipsimu/main/ships/class_BaseShip.php
new file mode 100644 (file)
index 0000000..ae22ca3
--- /dev/null
@@ -0,0 +1,167 @@
+<?php
+/**
+ * A general ship class for all other kinds of ships even small sail ships
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseShip extends BaseSimulator {
+       // Name des Shipes
+       private $shipName   = "Unbekanntes Schiff";
+
+       // Anzahl Anker
+       private $numAnchor  = 0;
+
+       // Tiefgang in Meter
+       private $draught    = 0;
+
+       // Besatzung-Objekte
+       private $crewList   = null;
+
+       // Aufbauten-Objekte
+       private $structures = null;
+
+       // Namenloses Ship generieren
+       protected function __construct($className) {
+               // Call parent constructor
+               parent::__construct($className);
+
+               // Prepare array object for all structures
+               $this->createStructuresArray();
+
+               // Clean-up a little
+               $this->removePartInstance();
+       }
+
+       // Array-Objekt anlegen
+       private function createStructuresArray () {
+               $this->structures = new FrameworkArrayObject("FakedShipStructures");
+       }
+
+       // Schiffsteil generieren (kann alles sein)
+       // buildInstance = Das was in das Schiffsteil evtl. eingebaut werden soll (null = kein besonderes Teil einbauen!)
+       // partClass = Das zu konstruierende Schiffsteil
+       public function createShipPart (ConstructableShipPart $buildInstance, $partClass) {
+               if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> erh&auml;lt ein neues Schiffsteil (%s).",
+                       __CLASS__,
+                       __LINE__,
+                       $this->getShipName(),
+                       $partClass
+               ));
+
+               // Ist die gewuenschte Klasse vorhanden?
+               if (!class_exists($partClass)) {
+                       // Nicht vorhanden, dann Ausnahme werfen!
+                       throw new NoClassException($partClass, self::EXCEPTION_CLASS_NOT_FOUND);
+               } // END - if
+
+               // Get an instance back from our object factory
+               $partInstance = ObjectFactory::createObjectByName($partClass);
+
+               // Das Einbauen versuchen...
+               try {
+                       $partInstance->addShipPartToShip($this, $buildInstance);
+               } catch (MotorShipMismatchException $e) {
+                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keinen Motor erhalten! Grund: <strong>%s</strong>",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getShipName(),
+                               $e->getMessage()
+                       ));
+                       return false;
+               } catch (RoomShipMismatchException $e) {
+                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keinen Maschinenraum erhalten! Grund: <strong>%s</strong>",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getShipName(),
+                               $e->getMessage()
+                       ));
+                       return false;
+
+               } catch (StructureShipMismatchException $e) {
+                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keine Aufbauten erhalten! Grund: <strong>%s</strong>",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getShipName(),
+                               $e->getMessage()
+                       ));
+                       return false;
+               } catch (CabinShipMismatchException $e) {
+                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat keine Kabine erhalten! Grund: <strong>%s</strong>",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getShipName(),
+                               $e->getMessage()
+                       ));
+                       return false;
+               } catch (DeckShipMismatchException $e) {
+                       if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Das Schiff <strong>%s</strong> hat kein Deck erhalten! Grund: <strong>%s</strong>",
+                               __CLASS__,
+                               __LINE__,
+                               $this->getShipName(),
+                               $e->getMessage()
+                       ));
+                       return false;
+               }
+
+               // Instanz im Aufbauten-Array vermerken
+               $this->structures->append($partInstance);
+
+               // Alles klar!
+               return true;
+       }
+
+       // Getter-Methode fuer Strukturen-Array
+       public final function getStructuresArray () {
+               return $this->structures;
+       }
+
+       // STUB: Getter-Methode Anzahl Betten
+       public function calcTotalBeds () {
+               $this->partialStub("Please implement this stub in your ship!");
+       }
+
+       // Setter-Methode fuer Schiffsnamen
+       public final function setShipName ($shipName) {
+               $this->shipName = (string) $shipName;
+       }
+
+       // Getter-Methode fuer Schiffsnamen
+       public final function getShipName () {
+               return $this->shipName;
+       }
+
+       // Setter-Methode fuer Tiefgang
+       public final function setDraught ($draught) {
+               $this->draught = (int) $draught;
+       }
+
+       // Getter-Methode fuer Tiefgang
+       public final function getDraught() {
+               return $this->draught;
+       }
+
+       // Setter-Methode fuer Anzahl Anker
+       public final function setNumAnchor ($numAnchor) {
+               $this->numAnchor = (int) $numAnchor;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/ships/passenger/.htaccess b/application/shipsimu/main/ships/passenger/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/ships/passenger/class_PassengerShip.php b/application/shipsimu/main/ships/passenger/class_PassengerShip.php
new file mode 100644 (file)
index 0000000..70fa5ed
--- /dev/null
@@ -0,0 +1,87 @@
+<?php
+/**
+ * A passenger ship with one or more decks, cabins, bridge (replacement for the
+ * captain) and many more
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 PassengerShip extends BaseShip implements ConstructableShip {
+       // Konstruktor
+       protected function __construct () {
+               // Eltern-Kontruktor aufrufen
+               parent::__construct(__CLASS__);
+       }
+
+       // Passagier-Schiff erstellen
+       public static final function createPassengerShip ($shipName) {
+               // Get new instance
+               $passInstance = new PassengerShip();
+
+               // Set ship name
+               $passInstance->setShipName($shipName);
+
+               // Instanz zurueckgeben
+               return $passInstance;
+       }
+
+       // Anzahl Betten ermitteln
+       public final function calcTotalBeds () {
+               // Struktur-Array holen
+               $struct = $this->getStructuresArray();
+
+               if (is_null($struct)) {
+                       // Empty structures list!
+                       throw new EmptyStructuresListException($this, self::EXCEPTION_EMPTY_STRUCTURES_ARRAY);
+               } // END - if
+
+               // Anzahl Betten auf 0 setzen
+               $numBeds = 0;
+
+               // Alle Strukturen nach Kabinen durchsuchen
+               for ($idx = $struct->getIterator(); $idx->valid(); $idx->next()) {
+                       // Element holen
+                       $el = $idx->current();
+
+                       // Ist es eine Kabine?
+                       if ($el->isCabin()) {
+                               // Anzahl Betten ermitteln
+                               $total = $el->calcTotalBedsByCabin();
+                               $numBeds += $total;
+
+                               // Debug-Meldung ausgeben?
+                               if ((defined('DEBUG_SHIP')) || (defined('DEBUG_ALL'))) {
+                                       // Get new instance
+                                       $cabType = "Kabine ohne Namen";
+                                       $cab = $el->getPartInstance();
+                                       if (!is_null($cab)) {
+                                               // Kabinenbeschreibung holen
+                                               $cabType = $cab->getObjectDescription();
+                                       } // END - if
+                               } // END - if
+                       } // END - if
+               } // END - for
+
+               // Anzahl zurueckliefern
+               return $numBeds;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/.htaccess b/application/shipsimu/main/structures/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/class_BaseStructure.php b/application/shipsimu/main/structures/class_BaseStructure.php
new file mode 100644 (file)
index 0000000..59318cb
--- /dev/null
@@ -0,0 +1,51 @@
+<?php
+/**
+ * A general construction class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseStructure extends BaseSimulator {
+       // Price of this structure
+       private $price = 0.00;
+
+       // Konstruktor (hier keine Exceptions aendern!)
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Setter for price
+       public final function setPrice ($price) {
+               $this->price = (float) $price;
+       }
+
+       // Getter for price
+       public final function getPrice () {
+               return $this->price;
+       }
+
+       // Remove price
+       public final function removePrice () {
+               unset($this->price);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/.htaccess b/application/shipsimu/main/structures/extended/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/cabines/.htaccess b/application/shipsimu/main/structures/extended/cabines/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/cabines/class_BaseCabin.php b/application/shipsimu/main/structures/extended/cabines/class_BaseCabin.php
new file mode 100644 (file)
index 0000000..b513944
--- /dev/null
@@ -0,0 +1,38 @@
+<?php
+/**
+ * A general cabin class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseCabin extends BaseCabinStructure {
+       // Konstruktor
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Is this a cabin?
+       public final function isCabin () {
+               return ($this->isClass("BaseCabin"));
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/cabines/ship/.htaccess b/application/shipsimu/main/structures/extended/cabines/ship/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/cabines/ship/class_EconomyCabin.php b/application/shipsimu/main/structures/extended/cabines/ship/class_EconomyCabin.php
new file mode 100644 (file)
index 0000000..beceae8
--- /dev/null
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Cabins in the economy class may use this class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 EconomyCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Economy-Kabine erstellen
+       public static final function createEconomyCabin ($numLuxury, $numRooms, $numBeds, $dim) {
+               // Get new instance
+               $ecoInstance = new EconomyCabin();
+
+               // Abmasse extrahieren
+               $ecoInstance->extractDimensions($dim);
+
+               // Den Rest auch setzen
+               $ecoInstance->setNumCabin($numLuxury);
+               $ecoInstance->setNumRooms($numRooms);
+               $ecoInstance->setNumBeds($numBeds);
+
+               // Nicht noetig!
+               $ecoInstance->removePartInstance();
+
+               // Instanz zurueckgeben
+               return $ecoInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/cabines/ship/class_LowCabin.php b/application/shipsimu/main/structures/extended/cabines/ship/class_LowCabin.php
new file mode 100644 (file)
index 0000000..23b877c
--- /dev/null
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Cabins in the lower decks may use this class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 LowCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // 2-Sterne-Klasse erstellen
+       public static final function createLowCabin ($numLuxury, $numRooms, $numBeds, $dim) {
+               // Get new instance
+               $lowInstance = new LowCabin();
+
+               // Abmasse extrahieren
+               $lowInstance->extractDimensions($dim);
+
+               // Den Rest auch setzen
+               $lowInstance->setNumCabin($numLuxury);
+               $lowInstance->setNumRooms($numRooms);
+               $lowInstance->setNumBeds($numBeds);
+
+               // Nicht noetig!
+               $lowInstance->removePartInstance();
+
+               // Instanz zurueckgeben
+               return $lowInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/cabines/ship/class_LuxuryCabin.php b/application/shipsimu/main/structures/extended/cabines/ship/class_LuxuryCabin.php
new file mode 100644 (file)
index 0000000..78cb9c4
--- /dev/null
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Luxury class cabins  resists here
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 LuxuryCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Eine Luxuskabine erstellen
+       public static final function createLuxuryCabin ($numLuxury, $numRooms, $numBeds, $dim) {
+               // Get new instance
+               $luxuryInstance = new LuxuryCabin();
+
+               // Abmasse extrahieren
+               $luxuryInstance->extractDimensions($dim);
+
+               // Den Rest auch setzen
+               $luxuryInstance->setNumCabin($numLuxury);
+               $luxuryInstance->setNumRooms($numRooms);
+               $luxuryInstance->setNumBeds($numBeds);
+
+               // Nicht noetig!
+               $luxuryInstance->removePartInstance();
+
+               // Instanz zurueckgeben
+               return $luxuryInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/cabines/ship/class_PremierCabin.php b/application/shipsimu/main/structures/extended/cabines/ship/class_PremierCabin.php
new file mode 100644 (file)
index 0000000..522e301
--- /dev/null
@@ -0,0 +1,58 @@
+<?php
+/**
+ * So-called "premier class" cabins are constructed with this class (medium class)
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 PremierCabin extends BaseCabin implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Premier-Kabine erstellen
+       public static final function createPremierCabin ($numLuxury, $numRooms, $numBeds, $dim) {
+               // Get new instance
+               $premierInstance = new PremierCabin();
+
+               // Abmasse extrahieren
+               $premierInstance->extractDimensions($dim);
+
+               // Den Rest auch setzen
+               $premierInstance->setNumCabin($numLuxury);
+               $premierInstance->setNumRooms($numRooms);
+               $premierInstance->setNumBeds($numBeds);
+
+               // Nicht noetig!
+               $premierInstance->removePartInstance();
+
+               // Instanz zurueckgeben
+               return $premierInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/class_ b/application/shipsimu/main/structures/extended/class_
new file mode 100644 (file)
index 0000000..9644fd5
--- /dev/null
@@ -0,0 +1,7 @@
+
+       /**
+        * Limits this object with an ObjectLimits instance
+        */
+       public function limitObject (ObjectLimits $limitInstance) {
+               die("limitObject() reached! Stub!");
+       }
diff --git a/application/shipsimu/main/structures/extended/class_BaseCabinStructure.php b/application/shipsimu/main/structures/extended/class_BaseCabinStructure.php
new file mode 100644 (file)
index 0000000..77a81ae
--- /dev/null
@@ -0,0 +1,135 @@
+<?php
+/**
+ * General cabin structure class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseCabinStructure extends BaseStructure {
+       // --- Besondere Eigenschaften dazufuegen: ---
+       // Anzahl der Kabinen im Schiff
+       private $numCabin = 0;
+
+       // Anzahl Raeume pro Kabine (kann auch nur 1 sein)
+       private $numRooms = 0;
+
+       // Anzahl Betten, verallgemeinert
+       private $numBeds = 0;
+
+       // Konstruktor
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Kabine hinzufuegen
+       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $cabinInstance) {
+               // Eltern-Methode aufrufen
+               parent::addShipPartToShip ($shipInstance, $cabinInstance);
+
+               // Restlichen Daten ebenfalls
+               $this->setNumCabin($cabinInstance->numCabin);
+               $this->setNumRooms($cabinInstance->numRooms);
+               $this->setNumBeds($cabinInstance->numBeds);
+
+               // Unnoetige Attribute entfernen
+               $cabinInstance->removeNumCabin();
+               $cabinInstance->removeNumRooms();
+               $cabinInstance->removeNumBeds();
+
+               // Instanz setzen
+               $this->setDeckInstance($cabinInstance);
+       }
+
+       // Wrapper fuer setDeckInstance->setPartInstance
+       public final function setDeckInstance ($deck) {
+               parent::setPartInstance($deck);
+       }
+
+       // Getter-Methode fuer Anzahl Betten
+       public final function getNumBeds () {
+               return $this->numBeds;
+       }
+
+       // Getter-Methode fuer Anzahl Kabinen
+       public final function getNumCabin () {
+               return $this->numCabin;
+       }
+
+       // Setter-Methode fuer Anzahl Betten
+       public final function setNumBeds ($numBeds) {
+               $this->numBeds = $numBeds;
+       }
+
+       // Setter-Methode fuer Anzahl Raeume
+       public final function setNumRooms ($numRooms) {
+               $this->numRooms = $numRooms;
+       }
+
+       // Setter-Methode fuer Anzahl Kabinen
+       public final function setNumCabin ($numCabin) {
+               $this->numCabin = $numCabin;
+       }
+
+       // Loesch-Methode fuer Anzahl Betten
+       public final function removeNumBeds() {
+               unset($this->numBeds);
+       }
+
+       // Loesch-Methode fuer Anzahl Kabinen
+       public final function removeNumCabin() {
+               unset($this->numCabin);
+       }
+
+       // Loesch-Methode fuer Anzahl Raeume
+       public final function removeNumRooms() {
+               unset($this->numRooms);
+       }
+
+       // Bettenanzahl pro Kabine berechnen
+       public function calcTotalBedsByCabin () {
+               // Dann Bettenanzahl holen und aufaddieren
+               $beds = $this->getNumBeds();
+               $num  = $this->getNumCabin();
+               $cabinBeds = $beds * $num;
+               if ((defined('DEBUG_STRUCTURE')) || (defined('DEBUG_ALL'))) {
+                       // Get new instance
+                       $cabType = "Kabine ohne Namen";
+                       $cab = $this->getPartInstance();
+                       if (!is_null($cab)) {
+                               // Kabinenbeschreibung holen
+                               $cabType = $cab->__toString();
+                       }
+
+                       // Debug-Meldung ausgeben
+                       $this->debugOutput(sprintf("[%s:%d] Es exisitieren <strong>%d</strong> Kabinen vom Typ <strong>%s</strong> zu je <strong>%d</strong> Betten. Das sind <strong>%d</strong> Betten.",
+                               __CLASS__,
+                               __LINE__,
+                               $num,
+                               $cabType,
+                               $beds,
+                               $cabinBeds
+                       ));
+               }
+               return $cabinBeds;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/class_BaseDeckStructure.php b/application/shipsimu/main/structures/extended/class_BaseDeckStructure.php
new file mode 100644 (file)
index 0000000..0f44a55
--- /dev/null
@@ -0,0 +1,61 @@
+<?php
+/**
+ * A general deck structure class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseDeckStructure extends BaseStructure {
+       // Anzahl Decks
+       private $numDecks = 0;
+
+       // Konstruktor
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       // Deckstruktur dem Schiff hinzufuegen
+       public function addShipPartToShip (ConstructableShip $shipInstance, ConstructableShipPart $deckInstance) {
+               // Eltern-Methode aufrufen
+               parent::addShipPartToShip($shipInstance, $deckInstance);
+
+               // Andere Daten uebertragen und von der Quelle loeschen
+               $this->setNumDecks($deckInstance->getNumDecks());
+               $deckInstance->removeNumDecks();
+       }
+
+       // Deckanzahl entfernen
+       public final function removeNumDecks() {
+               unset($this->numDecks);
+       }
+
+       // Setter-Methode fuer Anzahl Decks
+       public final function setNumDecks($numDecks) {
+               $this->numDecks = (int) $numDecks;
+       }
+
+       // Getter-Methode fuer Anzahl Decks
+       public final function getNumDecks() {
+               return $this->numDecks;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/class_BaseUpperStructure.php b/application/shipsimu/main/structures/extended/class_BaseUpperStructure.php
new file mode 100644 (file)
index 0000000..dd6934c
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * A general upper structure class.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseUpperStructure extends BaseStructure {
+       /**
+        * Constructor for all super structures on a ship
+        *
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/decks/.htaccess b/application/shipsimu/main/structures/extended/decks/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/decks/cargo/.htaccess b/application/shipsimu/main/structures/extended/decks/cargo/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/decks/cargo/class_CarDeck.php b/application/shipsimu/main/structures/extended/decks/cargo/class_CarDeck.php
new file mode 100644 (file)
index 0000000..d87dd09
--- /dev/null
@@ -0,0 +1,56 @@
+<?php
+/**
+ * A deck class for cars with ramps and about 2.5 meters hich
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 CarDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // Autodeck erstellen
+       public static final function createCarDeck ($numDecks, $dim) {
+               // Get new instance
+               $carInstance = new CarDeck();
+
+               // Abmasse extrahieren
+               $carInstance->extractDimensions($dim);
+
+               // Andere Daten uebetragen
+               $carInstance->setNumDecks($numDecks);
+
+               // Nicht noetige Instanz
+               $carInstance->removePartInstance();
+
+               // Instanz zurueckgeben
+               return $carInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/decks/cargo/class_TrainDeck.php b/application/shipsimu/main/structures/extended/decks/cargo/class_TrainDeck.php
new file mode 100644 (file)
index 0000000..07410ea
--- /dev/null
@@ -0,0 +1,56 @@
+<?php
+/**
+ * A train deck with rails constructed in it
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 TrainDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // LKW-Deck erstellen
+       public static final function createTrainDeck ($numDecks, $dim) {
+               // Get new instance
+               $trainInstance = new TrainDeck();
+
+               // Abmasse extrahieren
+               $trainInstance->extractDimensions($dim);
+
+               // Andere Daten uebetragen
+               $trainInstance->setNumDecks($numDecks);
+
+               // Nicht noetige Instanz
+               $trainInstance->removePartInstance();
+
+               // Instanz zurueckliefern
+               return $trainInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/decks/cargo/class_TruckDeck.php b/application/shipsimu/main/structures/extended/decks/cargo/class_TruckDeck.php
new file mode 100644 (file)
index 0000000..6a87d85
--- /dev/null
@@ -0,0 +1,57 @@
+<?php
+/**
+ * A truck and bus decks. Also other vehicle may be put in here if they don't
+ * match into the car deck.
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 TruckDeck extends BaseDeck implements TradeableItem, ConstructableShipPart {
+       // Konstruktor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       // LKW-Deck erstellen
+       public static final function createTruckDeck ($numDecks, $dim) {
+               // Get new instance
+               $truckInstance = new TruckDeck();
+
+               // Abmasse extrahieren
+               $truckInstance->extractDimensions($dim);
+
+               // Andere Daten uebetragen
+               $truckInstance->setNumDecks($numDecks);
+
+               // Nicht noetige Instanz
+               $truckInstance->removePartInstance();
+
+               // Instanz zurueckliefern
+               return $truckInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/decks/class_BaseDeck.php b/application/shipsimu/main/structures/extended/decks/class_BaseDeck.php
new file mode 100644 (file)
index 0000000..7b92d68
--- /dev/null
@@ -0,0 +1,37 @@
+<?php
+/**
+ * A general cabin class
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 BaseDeck extends BaseDeckStructure {
+       /**
+        * Constructor for cargo decks in general
+        *
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/structures/extended/lower/.htaccess b/application/shipsimu/main/structures/extended/lower/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/upper/.htaccess b/application/shipsimu/main/structures/extended/upper/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/structures/extended/upper/class_Bridge.php b/application/shipsimu/main/structures/extended/upper/class_Bridge.php
new file mode 100644 (file)
index 0000000..1c3b674
--- /dev/null
@@ -0,0 +1,55 @@
+<?php
+/**
+ * The control bridge of the ship
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 Bridge extends BaseUpperStructure implements TradeableItem, ConstructableShipPart {
+       // Constructor
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+
+               // Clean up a little
+               $this->removePartInstance();
+       }
+
+       // Eine Kommandobruecke erstellen
+       public static final function createBridge ($width, $height, $length) {
+               // Get new instance
+               $bridgeInstance = new Bridge();
+
+               // Abmasse setzen
+               $bridgeInstance->setWidth($width);
+               $bridgeInstance->setHeight($height);
+               $bridgeInstance->setLength($length);
+
+               // Instanz zurueckgeben
+               return $bridgeInstance;
+       }
+
+       // Overwritten method for tradeable items
+       public function isTradeable () {
+               return true;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/user/.htaccess b/application/shipsimu/main/user/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/user/class_ShipSimuBaseUser.php b/application/shipsimu/main/user/class_ShipSimuBaseUser.php
new file mode 100644 (file)
index 0000000..75de2c7
--- /dev/null
@@ -0,0 +1,261 @@
+<?php
+/**
+ * A special member class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuBaseUser extends BaseUser implements Registerable, Updateable {
+       /**
+        * Protected constructor
+        *
+        * @param       $className      Name of the class
+        * @return      void
+        */
+       protected function __construct ($className) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Initializes the bank instance
+        *
+        * @return      $bankInstance   A bank instance wether just created or from registry
+        */
+       protected function initBankInstance () {
+               // Init instance
+               $bankInstance = null;
+
+               try {
+                       // Get a money bank instance from registry
+                       $bankInstance = Registry::getRegistry()->getInstance('money_bank');
+               } catch (NullPointerException $e) {
+                       // Instance not found in registry
+                       // @TODO We should log this exception later
+               }
+
+               // Is it there?
+               if (is_null($bankInstance)) {
+                       // Then create a new one
+                       $bankInstance = ObjectFactory::createObjectByConfiguredName('bank_class', array($this));
+
+                       // Store it in registry
+                       Registry::getRegistry()->addInstance('money_bank', $bankInstance);
+               } // END - if
+
+               // Return the instance
+               return $bankInstance;
+       }
+
+       /**
+        * Initializes the government instance
+        *
+        * @return      $governmentInstance             A government instance
+        */
+       protected function initGovernmentInstance () {
+               // Init instance
+               $governmentInstance = null;
+
+               try {
+                       // First get a government instance from registry
+                       $governmentInstance = Registry::getRegistry()->getInstance('government');
+               } catch (NullPointerException $e) {
+                       // Instance not found in registry
+                       // @TODO We should log this exception later
+               }
+
+               // Is it there?
+               if (is_null($governmentInstance)) {
+                       // Then create a new one
+                       $governmentInstance = ObjectFactory::createObjectByConfiguredName('government_class', array($this));
+
+                       // Store it in registry
+                       Registry::getRegistry()->addInstance('government', $governmentInstance);
+               } // END - if
+
+               // Return the prepared instance
+               return $governmentInstance;
+       }
+
+       /**
+        * Checks wether the user has reached maximum allowed companies to found
+        *
+        * @return      $reached        Wether the user has reached maximum allowed companies to found
+        */
+       public function ifUserCreatedMaximumAllowedCompanies () {
+               // Get max allowed companies to found
+               $maxFound = $this->getConfigInstance()->getConfigEntry('max_allowed_companies_found');
+
+               // Now get a search criteria and set the user's name as criteria
+               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+               $searchInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
+               $searchInstance->setLimit($maxFound);
+
+               // Get a company wrapper
+               $wrapperInstance = ObjectFactory::createObjectByConfiguredName('company_db_wrapper_class');
+
+               // Do the count-select by criteria
+               $totalRows = $wrapperInstance->doSelectCountByCriteria($searchInstance);
+
+               // Does the user have reached maximum?
+               $reached = ($totalRows >= $maxFound);
+
+               // Return the result
+               return $reached;
+       }
+
+       /**
+        * Checks wether the user has the required amount of points left for the specified action
+        *
+        * @param       $action                 The action or configuration entry plus prefix the user wants to perform
+        * @return      $hasRequired    Wether the user has the required points
+        */
+       public function ifUserHasRequiredPoints ($action) {
+               // Default is that everyone is poor... ;-)
+               $hasRequired = false;
+
+               // Init instance
+               $pointsInstance = null;
+
+               try {
+                       // Get a points instance from registry
+                       $pointsInstance = Registry::getRegistry()->getInstance('points');
+               } catch (NullPointerException $e) {
+                       // Instance not found in registry
+                       // @TODO We should log this exception later
+               }
+
+               // Is there an instance?
+               if (is_null($pointsInstance)) {
+                       // Then create one
+                       $pointsInstance = ObjectFactory::createObjectByConfiguredName('user_points_class', array($this));
+
+                       // And store it in registry
+                       Registry::getRegistry()->addInstance('points', $pointsInstance);
+               } // END - if
+
+               // Just forward this request to the user points class
+               $hasRequired = $pointsInstance->ifUserHasRequiredPoints($action);
+
+               // Return the result
+               return $hasRequired;
+       }
+
+       /**
+        * Determines if government can still pay a "virtual training course" in general
+        *
+        * @return      $ifGovHelps             Wether if government helps the user with a virtual training course
+        */
+       public function ifGovernmentPaysTraining () {
+               // By default they want to help.
+               $ifGovHelps = true;
+
+               // Initialize government instance
+               $governmentInstance = $this->initGovernmentInstance();
+
+               // Then ask the government if they want to pay a "startup help" to the user
+               $ifGovHelps = ($governmentInstance->ifGovernmentAlreadyPayedTraining());
+
+               // Return result here
+               return $ifGovHelps;
+       }
+
+       /**
+        * Determines if government can still pay a "startup help" to the user
+        *
+        * @return      $ifGovHelps             Wether if government helps the user with some startup money
+        */
+       public function ifGovernmentPaysStartupHelp () {
+               // By default they want to help.
+               $ifGovHelps = true;
+
+               // Initialize government instance
+               $governmentInstance = $this->initGovernmentInstance();
+
+               // Then ask the government if they want to pay a "startup help" to the user
+               $ifGovHelps = ($governmentInstance->ifGovernmentPayedMaxmimumStartupHelp());
+
+               // Return result here
+               return $ifGovHelps;
+       }
+
+       /**
+        * Checks wether the user can take points from the money bank
+        *
+        * @return      $bankLends      Wether the money bank is able to lend money
+        * @todo        Need to implement MoneyBank::ifBankLendsMoreMoney()
+        */
+       public function ifUserAllowedTakeCreditsFromMoneyBank () {
+               // Per default the money bank cannot pay
+               $bankLends = false;
+
+               // Initialize bank instance
+               $bankInstance->initBankInstance();
+
+               // Does the money bank lend more money?
+               $bankLends = ($bankInstance->ifBankLendsMoreMoney());
+
+               // Return result
+               return $bankLends;
+       }
+
+       /**
+        * Checks wether the user has maximum credits with the money bank. This
+        * should be done seperately from checking if the user is allowed to take
+        * credits from the bank.
+        *
+        * @return      $hasMaxCredits  Wether the user has maximum credits with the bank
+        * @todo        Need to check the bank if they can lend more money
+        */
+       public function ifUserHasMaximumCreditsWithMoneyBank () {
+               // For default he can still get money
+               $hasMaxCredits = false;
+
+               // Initialize the bank instance
+               $bankInstance = $this->initBankInstance();
+
+               // Now check if the user has maximum credits
+               $hasMaxCredits = ($bankInstance->ifUserHasMaxCredits());
+
+               // Return the result
+               return $hasMaxCredits;
+       }
+
+       /**
+        * Checks wether the money bank has opened
+        *
+        * @return      $hasOpened      Wether the money bank has opened
+        */
+       public function ifMoneyBankHasOpened () {
+               // Default is not opened
+               $hasOpened = false;
+
+               // Initialize the bank instance
+               $bankInstance = $this->initBankInstance();
+
+               // Has this bank opened?
+               $hasOpened = ($bankInstance->ifMoneyBankHasOpened());
+
+               // Return result
+               return $hasOpened;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/user/extended/.htaccess b/application/shipsimu/main/user/extended/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/user/extended/class_ShipSimuGuest.php b/application/shipsimu/main/user/extended/class_ShipSimuGuest.php
new file mode 100644 (file)
index 0000000..a66de18
--- /dev/null
@@ -0,0 +1,108 @@
+<?php
+/**
+ * A special guest class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuGuest extends ShipSimuBaseUser implements ManageableGuest {
+       // Exceptions
+       const EXCEPTION_USERNAME_NOT_FOUND   = 0x170;
+       const EXCEPTION_USER_EMAIL_NOT_FOUND = 0x171;
+       const EXCEPTION_USER_PASS_MISMATCH   = 0x172;
+
+       /**
+        * Protected constructor
+        *
+        * @param       $className      Name of the class
+        * @return      void
+        */
+       protected function __construct ($className = __CLASS__) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Creates an instance of this user class by a provided username. This
+        * factory method will check if username is already taken and if not
+        * so it will throw an exception.
+        *
+        * @param       $userName               Username we need a class instance for
+        * @return      $userInstance   An instance of this user class
+        * @throws      UsernameMissingException        If the username does not exist
+        */
+       public static final function createGuestByUsername ($userName) {
+               // Get a new instance
+               $userInstance = new ShipSimuGuest();
+
+               // Set the username
+               $userInstance->setUserName($userName);
+
+               // Check if username exists
+               if ($userInstance->ifUsernameExists() === false) {
+                       // Throw an exception here
+                       throw new UsernameMissingException(array($userInstance, $userName), self::EXCEPTION_USERNAME_NOT_FOUND);
+               } // END - if
+
+               // Return the instance
+               return $userInstance;
+       }
+
+       /**
+        * Creates an instance of this user class by a provided email address. This
+        * factory method will not check if email address is there.
+        *
+        * @param       $email                  Email address of the user
+        * @return      $userInstance   An instance of this user class
+        */
+       public static final function createGuestByEmail ($email) {
+               // Get a new instance
+               $userInstance = new ShipSimuGuest();
+
+               // Set the username
+               $userInstance->setEmail($email);
+
+               // Return the instance
+               return $userInstance;
+       }
+
+       /**
+        * Updates the last activity timestamp and last performed action in the
+        * database result. You should call flushPendingUpdates() to flush these updates
+        * to the database layer.
+        *
+        * @param       $requestInstance        A requestable class instance
+        * @return      void
+        */
+       public function updateLastActivity (Requestable $requestInstance) {
+               // No activity will be logged for guest accounts
+       }
+
+       /**
+        * Flushs all pending updates to the database layer
+        *
+        * @return      void
+        */
+       public function flushPendingUpdates () {
+               // No updates will be flushed to database!
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/user/extended/class_ShipSimuMember.php b/application/shipsimu/main/user/extended/class_ShipSimuMember.php
new file mode 100644 (file)
index 0000000..a37ef16
--- /dev/null
@@ -0,0 +1,220 @@
+<?php
+/**
+ * A special member class for Ship-Simu
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 ShipSimuMember extends ShipSimuBaseUser implements ManageableMember, BookableAccount {
+       /**
+        * Protected constructor
+        *
+        * @param       $className      Name of the class
+        * @return      void
+        */
+       protected function __construct ($className = __CLASS__) {
+               // Call parent constructor
+               parent::__construct($className);
+       }
+
+       /**
+        * Destructor for e.g. flushing pending updates to the database
+        *
+        * @return      void
+        */
+       public function __destruct () {
+               // Flush any updated entries to the database
+               $this->flushPendingUpdates();
+
+               // Call parent destructor
+               parent::__destruct();
+       }
+
+       /**
+        * Creates an instance of this user class by a provided username. This
+        * factory method will check if username is already taken and if not
+        * so it will throw an exception.
+        *
+        * @param       $userName               Username we need a class instance for
+        * @return      $userInstance   An instance of this user class
+        * @throws      UsernameMissingException        If the username does not exist
+        */
+       public static final function createMemberByUsername ($userName) {
+               // Get a new instance
+               $userInstance = new ShipSimuMember();
+
+               // Set the username
+               $userInstance->setUserName($userName);
+
+               // Check if username exists
+               if ($userInstance->ifUsernameExists() === false) {
+                       // Throw an exception here
+                       throw new UsernameMissingException(array($userInstance, $userName), self::EXCEPTION_USERNAME_NOT_FOUND);
+               } // END - if
+
+               // Return the instance
+               return $userInstance;
+       }
+
+       /**
+        * Creates an instance of this user class by a provided email address. This
+        * factory method will not check if email address is there.
+        *
+        * @param       $email                  Email address of the user
+        * @return      $userInstance   An instance of this user class
+        */
+       public static final function createMemberByEmail ($email) {
+               // Get a new instance
+               $userInstance = new ShipSimuMember();
+
+               // Set the username
+               $userInstance->setEmail($email);
+
+               // Return the instance
+               return $userInstance;
+       }
+
+       /**
+        * Creates a user by a given request instance
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @return      $userInstance           An instance of this user class
+        * @todo        Add more ways of creating user instances
+        */
+       public static final function createMemberByRequest (Requestable $requestInstance) {
+               // Determine if by email or username
+               if (!is_null($requestInstance->getRequestElement('username'))) {
+                       // Username supplied
+                       $userInstance = self::createMemberByUserName($requestInstance->getRequestElement('username'));
+               } elseif (!is_null($requestInstance->getRequestElement('email'))) {
+                       // Email supplied
+                       $userInstance = self::createMemberByEmail($requestInstance->getRequestElement('email'));
+               } else {
+                       // Unsupported mode
+                       $userInstance = new ShipSimuMember();
+                       $userInstance->partialStub("We need to add more ways of creating user classes here.");
+                       $userInstance->debugBackTrace();
+                       exit();
+               }
+
+               // Return the prepared instance
+               return $userInstance;
+       }
+
+       /**
+        * Updates the last activity timestamp and last performed action in the
+        * database result. You should call flushPendingUpdates() to flush these updates
+        * to the database layer.
+        *
+        * @param       $requestInstance        A requestable class instance
+        * @return      void
+        */
+       public function updateLastActivity (Requestable $requestInstance) {
+               // Set last action
+               $lastAction = $requestInstance->getRequestElement('action');
+
+               // If there is no action use the default on
+               if (is_null($lastAction)) {
+                       $lastAction = $this->getConfigInstance()->getConfigEntry('login_default_action');
+               } // END - if
+
+               // Get a critieria instance
+               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+
+               // Add search criteria
+               $searchInstance->addCriteria(UserDatabaseWrapper::DB_COLUMN_USERNAME, $this->getUserName());
+               $searchInstance->setLimit(1);
+
+               // Now get another criteria
+               $updateInstance = ObjectFactory::createObjectByConfiguredName('update_criteria_class');
+
+               // And add our both entries
+               $updateInstance->addCriteria('last_activity', date('Y-m-d H:i:s', time()));
+               $updateInstance->addCriteria('last_action', $lastAction);
+
+               // Add the search criteria for searching for the right entry
+               $updateInstance->setSearchInstance($searchInstance);
+
+               // Set wrapper class name
+               $updateInstance->setWrapperConfigEntry('user_db_wrapper_class');
+
+               // Remember the update in database result
+               $this->getResultInstance()->add2UpdateQueue($updateInstance);
+       }
+
+       /**
+        * Books the given 'amount' in the request instance on the users 'points
+        * account'
+        *
+        * @param       $requestInstance        An instance of a Requestable class
+        * @return      void
+        */
+       public function bookAmountDirectly (Requestable $requestInstance) {
+               // Init points instance
+               $pointsInstance = null;
+
+               try {
+                       // Get the points class from registry
+                       $pointsInstance = Registry::getRegistry()->getInstance('points');
+               } catch (NullPointerException $e) {
+                       // Instance not found in registry
+                       // @TODO We should log this later
+               }
+
+               // Is the points instance null?
+               if (is_null($pointsInstance)) {
+                       // Then get a new one
+                       $pointsInstance = ObjectFactory::createObjectByConfiguredName('user_points_class', array($this));
+
+                       // And store it in registry
+                       Registry::getRegistry()->addInstance('points', $pointsInstance);
+               } // END - if
+
+               // Get the amount
+               $amount = $requestInstance->getRequestElement('amount');
+
+               // Call the method for booking points
+               $pointsInstance->bookPointsDirectly($amount);
+       }
+
+       /**
+        * Flushs all pending updates to the database layer
+        *
+        * @return      void
+        */
+       public function flushPendingUpdates () {
+               // Is the object valid?
+               if (!$this->getResultInstance() instanceof SearchableResult) {
+                       // Abort here
+                       return;
+               } // END - if
+
+               // Do we have data to update?
+               if ($this->getResultInstance()->ifDataNeedsFlush()) {
+                       // Get a database wrapper
+                       $wrapperInstance = ObjectFactory::createObjectByConfiguredName('user_db_wrapper_class');
+
+                       // Yes, then send the whole result to the database layer
+                       $wrapperInstance->doUpdateByResult($this->getResultInstance());
+               } // END - if
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/wrapper/.htaccess b/application/shipsimu/main/wrapper/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/main/wrapper/class_CompanyDatabaseWrapper.php b/application/shipsimu/main/wrapper/class_CompanyDatabaseWrapper.php
new file mode 100644 (file)
index 0000000..1552e67
--- /dev/null
@@ -0,0 +1,129 @@
+<?php
+/**
+ * A wrapper for database access to shipping company data
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 CompanyDatabaseWrapper extends BaseDatabaseWrapper {
+       /**
+        * Company instance
+        */
+       private $companyInstance = null;
+
+       // Constants for database tables
+       const DB_TABLE_COMPANY_DATA = 'company';
+       const DB_TABLE_COMPANY_USER = 'company_user';
+
+       // Constants for database columns
+       const DB_COLUMN_PARTICIPANT_ID = 'participant_id';
+
+       /**
+        * Protected constructor
+        *
+        * @return      void
+        */
+       protected function __construct () {
+               // Call parent constructor
+               parent::__construct(__CLASS__);
+       }
+
+       /**
+        * Creates an instance of this wrapper class
+        *
+        * @param       $companyInstance        An instance of a generic company class or null if no specific
+        * @return      $wrapperInstance        An instance of this wrapper class
+        * @todo        Find an interface which is suitable for all companies
+        */
+       public static final function createCompanyDatabaseWrapper (ShippingCompany $companyInstance = null) {
+               // Create a new instance
+               $wrapperInstance = new CompanyDatabaseWrapper();
+
+               // Set (primary!) table name
+               $wrapperInstance->setTableName(self::DB_TABLE_COMPANY_DATA);
+
+               // Set the company instance if not null
+               if (!is_null($companyInstance)) {
+                       $wrapperInstance->setCompanyInstance($companyInstance);
+               } // END - if
+
+               // Return the instance
+               return $wrapperInstance;
+       }
+
+       /**
+        * Checks wether the given user participates in a company
+        *
+        * @param       $userInstance   An instance of a user class
+        * @return      $participates   Wether the user participates at lease in one company
+        */
+       public function ifUserParticipatesInCompany (ManageableAccount $userInstance)  {
+               // By default no user owns any company... ;)
+               $participates = false;
+
+               // Get a search criteria class
+               $searchInstance = ObjectFactory::createObjectByConfiguredName('search_criteria_class');
+
+               // Add the user primary key as a search criteria
+               $searchInstance->addCriteria(self::DB_COLUMN_PARTICIPANT_ID, $userInstance->getPrimaryKey());
+               $searchInstance->setLimit(1);
+
+               // Set company->user table
+               $this->setTableName(self::DB_TABLE_COMPANY_USER);
+
+               // Get the result back
+               $resultInstance = $this->doSelectByCriteria($searchInstance);
+
+               // Is there a result?
+               if ($resultInstance->next()) {
+                       // Then cache it
+                       $this->setResultInstance($resultInstance);
+
+                       // Entry found for further analysis/processing
+                       $participates = true;
+               } // END - if
+
+               // Return the result
+               return $participates;
+       }
+
+       /**
+        * Setter for company instance
+        *
+        * @param       $companyInstance        An instance of a generic company
+        * @return      void
+        * @todo        Find an interface suitable for all types of companies
+        */
+       protected final function setCompanyInstance (ShippingCompany $companyInstance) {
+               $this->companyInstance = $companyInstance;
+       }
+
+       /**
+        * Getter for company instance
+        *
+        * @return      $companyInstance        An instance of a generic company
+        * @todo        Find an interface suitable for all types of companies
+        */
+       public final function getCompanyInstance () {
+               return $this->companyInstance;
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/main/wrapper/class_UserGovernmentDatabaseWrapper.php b/application/shipsimu/main/wrapper/class_UserGovernmentDatabaseWrapper.php
new file mode 100644 (file)
index 0000000..6392d6b
--- /dev/null
@@ -0,0 +1,70 @@
+<?php
+/**
+ * A wrapper for database access to government->user data
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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 UserGovernmentDatabaseWrapper extends BaseDatabaseWrapper {
+       // Constants for database tables
+       const DB_TABLE_USER_GOVERNMENT = 'gov_user';
+
+       // Database columns
+       const DB_COLUMN_GOV_USERID   = 'gov_uid';
+       const DB_COLUMN_GOV_ACTIVITY = 'gov_activity_status';
+
+       /**
+        * 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 static final function createUserGovernmentDatabaseWrapper () {
+               // Create a new instance
+               $wrapperInstance = new UserGovernmentDatabaseWrapper();
+
+               // Set (primary!) table name
+               $wrapperInstance->setTableName(self::DB_TABLE_USER_GOVERNMENT);
+
+               // Return the instance
+               return $wrapperInstance;
+       }
+
+       /**
+        * Registers the given startup help request with the government
+        *
+        * @param       $requestInstance        A Requestable instance
+        * @return      void
+        */
+       public function registerStartupHelpByRequest (Requestable $requestInstance) {
+               $requestInstance->debugInstance();
+       }
+}
+
+// [EOF]
+?>
diff --git a/application/shipsimu/starter.php b/application/shipsimu/starter.php
new file mode 100644 (file)
index 0000000..7ba3538
--- /dev/null
@@ -0,0 +1,53 @@
+<?php
+/**
+ * The application launcher
+ *
+ * @author             Roland Haeder <webmaster@shipsimu.org>
+ * @version            0.0.0
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+ * @license            GNU GPL 3.0 or any newer version
+ * @link               http://www.shipsimu.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/>.
+ */
+
+// Is there an application helper instance? We need the method main() for
+// maining the application
+$app = call_user_func_array(array(FrameworkConfiguration::getSelfInstance()->getConfigEntry('app_helper_class'), 'getSelfInstance'), array());
+
+// Some sanity checks
+if ((empty($app)) || (is_null($app))) {
+       // Something went wrong!
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because the helper class <span class=\"class_name\">%s</span> is not loaded.",
+               $application,
+               FrameworkConfiguration::getSelfInstance()->getConfigEntry('app_helper_class')
+       ));
+} elseif (!is_object($app)) {
+       // No object!
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because &#39;app&#39; is not an object.",
+               $application
+       ));
+} elseif (!method_exists($app, FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method'))) {
+       // Method not found!
+       ApplicationEntryPoint::app_die(sprintf("[Main:] The application <span class=\"app_name\">%s</span> could not be launched because the method <span class=\"method_name\">%s</span> is missing.",
+               $application,
+               FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method')
+       ));
+}
+
+// Call user function
+call_user_func_array(array($app, FrameworkConfiguration::getSelfInstance()->getConfigEntry('entry_method')), array());
+
+// [EOF]
+?>
diff --git a/application/shipsimu/templates/.htaccess b/application/shipsimu/templates/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/de/.htaccess b/application/shipsimu/templates/de/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/de/.xml b/application/shipsimu/templates/de/.xml
new file mode 100644 (file)
index 0000000..d7d7d08
--- /dev/null
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_company.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_company.ctp
new file mode 100644 (file)
index 0000000..b9df5fc
--- /dev/null
@@ -0,0 +1,97 @@
+<?php
+// Get a link helper instance
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'list_companies'));
+
+// Prefetch the user data
+$linkInstance->prefetchValueInstance('user');
+
+// Add link group for company founder
+$linkInstance->addLinkGroup('company_founder', "Vielleicht willst du eine Reederei gr&uuml;nden, um dich selbstst&auml;ndig zu machen?");
+
+// Maximum of allowed companies reached?
+if ($linkInstance->getValueInstance()->ifUserCreatedMaximumAllowedCompanies()) {
+       // No more companies allowed to found
+       $linkInstance->addLinkNote('company_maximum', "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
+       $linkInstance->addActionLinkById('company_found', 'found_company');
+}
+
+// Add link group for government
+$linkInstance->addLinkGroup('government', "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
+       $linkInstance->addActionLinkById('company_list', 'list_company');
+} elseif ($linkInstance->getValueInstance()->ifGovernmentPaysTraining()) {
+       // Government is able to pay a training in general
+       $linkInstance->addActionLinkById('government_training', 'list_training_by_government');
+
+       // Can the government pay startup help?
+       if ($linkInstance->getValueInstance()->ifGovernmentPaysStartupHelp()) {
+               // Add link note
+               $linkInstance->addLinkNote('government_startup_help', "Starthilfe beantragen:");
+
+               // Display link to government for startup help
+               $linkInstance->addActionLinkById('government_startup_help', 'apply_startup_help_government');
+       } // END - if
+} elseif ($linkInstance->getValueInstance()->ifGovernmentPaysStartupHelp()) {
+       // Display link to government for startup help
+       $linkInstance->addActionLinkById('government_startup_help', 'apply_startup_help_government');
+} else {
+       // Even government cannot help the gamer here
+       $linkInstance->addLinkNote('government_depleted', "Leider kann dir der Staat nicht mehr weiterhelfen, dich zu bewerben, da du zu oft Starthilfen erhalten hast oder ein Training absolviert hast. Hier muss aber noch weiter am Spiel gearbeitet werden. :-)");
+}
+
+// Checks wether the money bank has opened
+if ($linkInstance->getValueInstance()->ifMoneyBankHasOpened()) {
+       // Add link group for money bank
+       $linkInstance->addLinkGroup('moneybank', "Leihe dir zu g&uuml;nstigen Zinsen Geld aus, wenn du mehr brauchst!");
+
+       // Add link to moneybank
+       if ($linkInstance->getValueInstance()->ifUserAllowedTakeCreditsFromMoneyBank()) {
+               // Display link to money bank page
+               $linkInstance->addActionLinkById('moneybank', 'virtual_money_bank');
+       } elseif ($linkInstance->getValueInstance()->ifUserHasMaximumCreditsWithMoneyBank()) {
+               // Maximum credits reached which a money bank can lent
+               $linkInstance->addLinkNote('moneybank_depleted', "Die Spielebank kann dir kein Geld mehr leihen, bitte zahle es auch wieder zur&uuml;ck.");
+               $linkInstance->addActionLinkById('moneybank_payback_credits', 'payback_credits_to_money_bank');
+       } else {
+               // Unexpected state of the bank
+               $linkInstance->addLinkNote('moneybank_error', "Es wurde ein Fehler in der Spielebank erkannt. Bitte melde dies dem Support.");
+       }
+} else {
+       // Money bank is closed!
+       $linkInstance->addLinkGroup('moneybank', "Die Spielebank hat geschlossen.");
+       $linkInstance->addLinkNote('moneybank_closed', "Die Spielebank hat derzeit geschlossen. Bitte sp&auml;ter nochmal versuchen.");
+}
+
+// Add link group for refill page
+$linkInstance->addLinkGroup('refill_page', "Hole dir Geld von uns zu fairen Preisen!");
+
+if ($linkInstance->ifRefillPageActive()) {
+       // Display link to refill page
+       $linkInstance->addActionLinkById('refill', 'refill_virtual_money');
+} else {
+       // Refill page not active
+       $linkInstance->addLinkNote('refill_disabled', "Das Aufladen ist derzeit nicht m&ouml;glich oder gest&ouml;rt und wurde von uns deaktiviert.");
+}
+
+// Flush content to the template
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<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_footer">
+               {?list_companies?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_government_startup_help.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_government_startup_help.ctp
new file mode 100644 (file)
index 0000000..e300a01
--- /dev/null
@@ -0,0 +1,62 @@
+<?php
+// Get form helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_government_startup'));
+
+// Prefetch user instance
+$helperInstance->prefetchValueInstance('user');
+
+// Add main form group
+$helperInstance->addFormNote('reality_warning', "WARNUNG: Bitte dieses Formular nicht mit echten Angaben ausf&uuml;llen! (Die Profildaten sollte jedoch echt sein.)");
+
+// Add group for personal data
+$helperInstance->addFormGroup('persona_data', "Deine pers&ouml;nliche Daten, die f&uuml;r die Beantragung n&ouml;tig sind:");
+
+// Display email, surname and family name
+$helperInstance->addFormNote('surname', "Vorname: <span class=\"persona_data\">".$helperInstance->getValueField('surname')."</span>");
+$helperInstance->addFormNote('family', "Nachname: <span class=\"persona_data\">".$helperInstance->getValueField('family')."</span>");
+$helperInstance->addFormNote('email', "Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
+$helperInstance->addFormNote('birthday', "Geburtstag: <span class=\"persona_data\">".(int)$helperInstance->getValueField('birth_day').".".(int)$helperInstance->getValueField('birth_month').".".(int)$helperInstance->getValueField('birth_year')."</span>");
+
+// Add link placeholder for profile page
+$helperInstance->addFormNote('profile', "Stimmen die Daten noch? {?shipsimu_profile?}");
+
+// Ask again for current account password
+$helperInstance->addFormGroup('password', "Bitte gebe zur Best&auml;tigung dein derzeitiges Passwort ein.");
+$helperInstance->addFieldText('password', "Derzeitiges Passwort:");
+$helperInstance->addInputPasswordField('password');
+
+// CAPTCHA enabled?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha_user', "Die virtuelle Beantragung von Starthilfe ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du die Starthilfe beantragen kannst.");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Final notices
+$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
+$helperInstance->addInputResetButton("Alles nochmal eingeben");
+$helperInstance->addInputSubmitButton("Starthilfe beantragen");
+$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
+
+// Flush the finished form
+$helperInstance->flushContent();
+
+// Get link helper for profile link
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'shipsimu_profile'));
+
+// Add action
+$linkInstance->addActionLinkById('profile', 'profile');
+
+// Flush the finished form
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<div id="government_frame">
+       <div id="government_header">
+               Virtuelle Beantragung von Starthilfe
+       </div>
+
+       <div id="government_form">
+               {?shipsimu_government_startup?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_government_training.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_government_training.ctp
new file mode 100644 (file)
index 0000000..7c921ff
--- /dev/null
@@ -0,0 +1,62 @@
+<?php
+// Get form helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_government_training'));
+
+// Prefetch user instance
+$helperInstance->prefetchValueInstance('user');
+
+// Add main form group
+$helperInstance->addFormNote('reality_warning', "WARNUNG: Bitte dieses Formular nicht mit echten Angaben ausf&uuml;llen!");
+
+// Add group for personal data
+$helperInstance->addFormGroup('persona_data', "Deine pers&ouml;nliche Daten, die f&uuml;r die Kursusteilnahme n&ouml;tig sind:");
+
+// Ask again for current account password
+$helperInstance->addFormGroup('password', "Bitte gebe zur Best&auml;tigung dein derzeitiges Passwort ein.");
+$helperInstance->addFieldText('password', "Derzeitiges Passwort:");
+$helperInstance->addInputPasswordField('password');
+
+// Display email, surname and family name
+$helperInstance->addFormNote('surname', "Vorname: <span class=\"persona_data\">".$helperInstance->getValueField('surname')."</span>");
+$helperInstance->addFormNote('family', "Nachname: <span class=\"persona_data\">".$helperInstance->getValueField('family')."</span>");
+$helperInstance->addFormNote('email', "Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
+$helperInstance->addFormNote('birthday', "Geburtstag: <span class=\"persona_data\">".(int)$helperInstance->getValueField('birth_day').".".(int)$helperInstance->getValueField('birth_month').".".(int)$helperInstance->getValueField('birth_year')."</span>");
+
+// Add link placeholder for profile page
+$helperInstance->addFormNote('profile', "Stimmen die Daten noch? {?shipsimu_profile?}");
+
+// CAPTCHA enabled?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha_user', "Die virtuelle Beantragung eines Trainingkursus ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, um den Trainingskursus zu beantragen.");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Final notices
+$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
+$helperInstance->addInputResetButton("Alles nochmal eingeben");
+$helperInstance->addInputSubmitButton("Trainingskurs beantragen");
+$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
+
+// Flush the finished form
+$helperInstance->flushContent();
+
+// Get link helper for profile link
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'shipsimu_profile'));
+
+// Add action
+$linkInstance->addActionLinkById('profile', 'profile');
+
+// Flush the finished form
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<div id="government_frame">
+       <div id="government_header">
+               Virtuelle Beantragung eines Training-Kursus
+       </div>
+
+       <div id="government_form">
+               {?shipsimu_government_training?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_logout.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_logout.ctp
new file mode 100644 (file)
index 0000000..5443af2
--- /dev/null
@@ -0,0 +1,30 @@
+<?php
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout_now'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('logout_now');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'return_login'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('return_login');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="logout_box">
+       <div id="logout_header">
+               Willst du dich wirklich aus dem Spiel ausloggen?
+       </div>
+
+       <div id="logouts">
+               {?logout_now?} | {?return_login?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_profile.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_profile.ctp
new file mode 100644 (file)
index 0000000..8037a4e
--- /dev/null
@@ -0,0 +1,145 @@
+<?php
+// Get helper instance for web forms. This will add the opening form-tag to
+// the helper's render cache which is simply a small variable in the class
+// BaseHelper.
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, "shipsimu_profile"));
+
+// Pre-fetch field data with a given registry key
+$helperInstance->prefetchValueInstance('user');
+
+// Password can only be changed when the old one is entered and new one twice!
+$helperInstance->addFormGroup('pass', "Neues Passwort einrichten:");
+$helperInstance->addFormSubGroup('pass', "Bitte gebe zum &Auml;ndern deines Passwortes zweimal das gew&uuml;nschte neue Passwort ein.");
+$helperInstance->addFieldText('pass1', "Neues Passwort:");
+$helperInstance->addInputPasswordField('pass1');
+$helperInstance->addFieldText('pass2', "Neues Passwort, Wiederholung:");
+$helperInstance->addInputPasswordField('pass2');
+
+// Display current email
+$helperInstance->addFormNote('current_email', "Derzeitige Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
+
+// Only for changing email address
+if ($helperInstance->ifEmailChangeAllowed()) {
+       $helperInstance->addFormGroup('email', "&Auml;nderung deiner Email-Addresse:");
+       $helperInstance->addFormSubGroup('email', "Gebe nur deine Email-Adresse zweimal ein, wenn du diese &auml;ndern m&ouml;chtest!");
+       $helperInstance->addFieldText('email1', "Email-Adresse:");
+       $helperInstance->addInputTextField('email1');
+       $helperInstance->addFieldText('email2', "Wiederholung Email-Adresse:");
+       $helperInstance->addInputTextField('email2');
+
+       if ($helperInstance->ifEmailMustBeUnique()) {
+               $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
+       } // END - if
+
+       if ($helperInstance->ifEmailChangeRequireConfirmation()) {
+               $helperInstance->addFormNote('confirm', "Es wird ein Best&auml;tigungslink an deine neue Email-Adresse gesendet. Bitte klicke diesen dann m&ouml;glichst schnell an.");
+       } // END - if
+} // END - if
+
+// Add form group for user profile
+$helperInstance->addFormGroup('profile', "Hier kannst du deine Profildaten &auml;ndern.");
+
+// Persoenliche Daten mit in der Anmeldung abfragen?
+if ($helperInstance->ifRegisterIncludesPersonaData()) {
+       $helperInstance->addFormSubGroup('persona', "Wenn du magst, dann vervollst&auml;ndige deine komplette Adresse mit deinem Namen.");
+       $helperInstance->addFieldText('surname', "Dein Vorname:");
+       $helperInstance->addInputTextFieldWithDefault('surname');
+       $helperInstance->addFieldText('family', "Dein Nachname:");
+       $helperInstance->addInputTextFieldWithDefault('family');
+       $helperInstance->addFieldText('street', "Strasse und Hausnummer:");
+       $helperInstance->addInputTextFieldWithDefault('street');
+       $helperInstance->addFieldText('city', "Wohnort:");
+       $helperInstance->addInputTextFieldWithDefault('city');
+
+       // Include birthday?
+       if ($helperInstance->ifProfileIncludesBirthDay()) {
+               $helperInstance->addFormSubGroup('birthday', "Verrate uns doch dein Geburtsdatum, als Dankesch&ouml;n erh&auml;lst du interessante Pr&auml;mien - ausschliesslich per Email - zum Geburtstag zugesandt! G&uuml;ltiges Format: TT.MM.JJJJ");
+               $helperInstance->addInputTextField('birth_day');
+               $helperInstance->addFieldText('birth_day', ".");
+               $helperInstance->addInputTextField('birth_month');
+               $helperInstance->addFieldText('birth_day', ".");
+               $helperInstance->addInputTextField('birth_year');
+       } // END - if
+} // END - if
+
+// Add sub group for zip code
+$helperInstance->addFormSubGroup('zip', "Magst du uns auch deine Postleitzahl verraten?");
+$helperInstance->addFieldText('zip', "Postleitzahl:");
+$helperInstance->addInputTextFieldWithDefault('zip');
+
+// Add sub group for chat protocols
+$helperInstance->addFormSubGroup('chat', "Gebe hier deine Nicknames bzw. Nummern an:");
+
+// Add ICQ chat?
+if ($helperInstance->ifChatEnabled('icq')) {
+       $helperInstance->addFieldText('icq', "ICQ-Nummer:");
+       $helperInstance->addInputTextFieldWithDefault('icq');
+} // END - if
+
+// Add Jabber chat?
+if ($helperInstance->ifChatEnabled('jabber')) {
+       $helperInstance->addFieldText('jabber', "Jabber:");
+       $helperInstance->addInputTextFieldWithDefault('jabber');
+} // END - if
+
+// Add Yahoo! chat?
+if ($helperInstance->ifChatEnabled('yahoo')) {
+       $helperInstance->addFieldText('yahoo', "Yahoo!:");
+       $helperInstance->addInputTextFieldWithDefault('yahoo');
+} // END - if
+
+// Add AOL chat?
+if ($helperInstance->ifChatEnabled('aol')) {
+       $helperInstance->addFieldText('aol', "AOL-Screenname:");
+       $helperInstance->addInputTextFieldWithDefault('aol');
+} // END - if
+
+// Add MSN chat?
+if ($helperInstance->ifChatEnabled('msn')) {
+       $helperInstance->addFieldText('msn', "MSN:");
+       $helperInstance->addInputTextFieldWithDefault('msn');
+} // END - if
+
+if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
+       $helperInstance->addFormExtraNote(1, "Die Benachrichtigungen per Email sind im Loginbereich verfeinerbar, welche du genau haben willst.");
+} // END - if
+
+// Rules already accepted?
+if ($helperInstance->ifRulesHaveChanged()) {
+       $helperInstance->addFormGroup('rules', "Bitte lese dir die Spieleregeln gut durch und kreuze dann &quot;Ja, ich akzeptiere die aktuellen Spielregeln&quot; an.");
+       $helperInstance->addFieldText('rules', "Ja, ich akzeptiere die aktuellen Spielregeln:");
+       $helperInstance->addInputCheckboxField('rules', false);
+} else {
+       $helperInstance->addFormNote('rules_accepted', "Du hast die aktuellen Spielregeln akzeptiert. Vielen Dank!");
+       $helperInstance->addInputHiddenField('rules', "1");
+}
+
+// CAPTCHA enabled?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha_user', "Das &Auml;ndern von Profildaten ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit deine &Auml;nderungen gespeichert werden k&ouml;nnen.");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Ask again for current account password
+$helperInstance->addFormGroup('pass_old', "Bitte gebe zur Best&auml;tigung der &Auml;nderungen dein derzeitiges Passwort ein.");
+$helperInstance->addFieldText('pass_old', "Derzeitiges Passwort:");
+$helperInstance->addInputPasswordField('pass_old');
+
+// Final notices
+$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
+$helperInstance->addInputResetButton("Alles nochmal eingeben");
+$helperInstance->addInputSubmitButton("Accountdaten aktualisieren");
+$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
+
+// Flush finished form
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Deine Profildaten bearbeiten
+</div>
+
+<div id="profile_box">
+       {?shipsimu_profile?}
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_refill.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_refill.ctp
new file mode 100644 (file)
index 0000000..fdc7c4e
--- /dev/null
@@ -0,0 +1,60 @@
+<?php
+// Neue Helper-Instanz holen
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_refill'));
+
+// Pre-fetch payment types
+$helperInstance->prefetchValueInstance('payments');
+
+// Add form group
+$helperInstance->addFormGroup('refill_form', "Bitte w&auml;hle aus, was du nachbestellen willst und gebe die Menge an.");
+
+// Add sub group
+$helperInstance->addInputSelectField('type', "--- Bitte ausw&auml;hlen ---");
+
+// In-game currencies (if more than default add them here!)
+$helperInstance->addSelectSubOption('currencies', "--- W&auml;hrungen ---");
+$helperInstance->addSelectOption('currency', "{?currency?}");
+
+// Raw resources
+$helperInstance->addSelectSubOption('raw_resources', "--- Rohstoffe ---");
+$helperInstance->addSelectOption('raw_wood', "Holz");
+$helperInstance->addSelectOption('raw_iron', "Metall");
+$helperInstance->addSelectOption('raw_stones', "Steine");
+
+// This is needed to close the select tag
+$helperInstance->addInputSelectField('type', "");
+
+// Field for amount
+$helperInstance->addFormSubGroup('amount', "Gebe hier in ganzen Zahlen die Menge an, die du nachbestellen willst.");
+$helperInstance->addInputTextField('amount', 1000);
+
+// Add payments
+$helperInstance->getValueInstance()->addResultsToHelper($helperInstance);
+
+// Ask again for current account password
+$helperInstance->addFormGroup('pass_old', "Bitte gebe zur Best&auml;tigung der Nachbestellung dein derzeitiges Passwort ein.");
+$helperInstance->addFieldText('pass_old', "Derzeitiges Passwort:");
+$helperInstance->addInputPasswordField('pass_old');
+
+// CAPTCHA enbaled?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha_refill', "Bitte wiederhole den angezeigten Code:");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Submit button
+$helperInstance->addFormGroup('buttons_refill', "Mit Absenden des Formulars wird deine Nachbestellung verbindlich!");
+$helperInstance->addInputResetButton("Eingaben l&ouml;schen");
+$helperInstance->addInputSubmitButton("Nachbestellung verbindlich aufgeben");
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="refill_frame">
+       <div class="content_header">
+               Jetzt dein {?currency?}-Konto aufladen!
+       </div>
+       <div class="content_body">
+               {?shipsimu_refill?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_status_problem.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_status_problem.ctp
new file mode 100644 (file)
index 0000000..df4a8de
--- /dev/null
@@ -0,0 +1,79 @@
+<?php
+// Get helper instance for web forms. This will add the opening form-tag to
+// the helper's render cache which is simply a small variable in the class
+// BaseHelper.
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'resend_link'));
+
+// Pre-fetch field data with a given registry key
+$helperInstance->prefetchValueInstance('user');
+
+// Add submit button or notice
+if ($helperInstance->ifUserAccountUnconfirmed()) {
+       // Add submit button
+       $helperInstance->addInputHiddenFieldWithDefault('email');
+       $helperInstance->addInputSubmitButton("Best&auml;tigungslink erneut aussenden");
+} elseif ($helperInstance->ifUserAccountLocked()) {
+       // Account is locked
+       $helperInstance->addFormNote('status_locked', "Dein Account wurde gesperrt! Grund der Sperre:
+               <span id=\"lock_reason\">".$helperInstance->getValueField('lock_reason')."</span>
+               Bitte melde dich beim Support, damit dieser dir weiterhelfen kann."
+       );
+} elseif ($helperInstance->ifUserAccountGuest()) {
+       // Account is guest account
+       $helperInstance->addFormNote('status_guest', "G&auml;steaccounts sind in der Funktionalit&auml;t
+               leicht eingeschr&auml;nkt. Bitte melde dich an, damit du ein
+               vollwertiges Account bekommst."
+       );
+}
+
+// Flush content and automatically close the form
+$helperInstance->flushContent();
+
+// Build the form for confirmation
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'confirm_code'));
+
+// Pre-fetch field data with a given registry key
+$helperInstance->prefetchValueInstance('user');
+
+if ($helperInstance->ifUserAccountUnconfirmed()) {
+       // Add code box
+       $helperInstance->addFormGroup('code', "Bitte gebe hier den Best&auml;tigungscode aus der Willkommensemail ein. Solltest du diese nicht erhalten haben, kannst du dir diesen jetzt zusenden lassen.");
+       $helperInstance->addFieldText('code', "Best&auml;tigungscode aus der Mail:");
+       $helperInstance->addInputTextField('code');
+
+       // Add submit button
+       $helperInstance->addFormGroup('buttons', "Bitte einmal abschicken und das Ergebnis abwarten!");
+       $helperInstance->addInputResetButton("Nochmal eingeben");
+       $helperInstance->addInputSubmitButton("Best&auml;tigungscode absenden");
+} else {
+       // Add message
+       $helperInstance->addFormNote('status_not_unconfirmed', "M&ouml;glicherweise hast du einen Best&auml;tigungslink angeklickt, obwohl dein Account bereits freigegeben oder gesperrt ist.");
+}
+
+// Flush content and automatically close the form
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Problem mit deinem Account gefunden:
+</div>
+
+<div id="status_box">
+       Du bist m&ouml;glicherweise f&uuml;r deine ausgew&auml;hlte Aktion nicht
+       berechtigt oder du hast noch deine Email-Adresse nicht best&auml;tigt. Du
+       kannst dir nun den Best&auml;tigungslink erneut aussenden lassen, oder den
+       Best&auml;tigungscode unten eingeben.
+
+       <div id="resend_link_box">
+               {?resend_link?}
+       </div>
+
+       <div id="confirm_code_header">
+               Weitere M&ouml;glichkeiten:
+       </div>
+
+       <div id="confirm_code_box">
+               {?confirm_code?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_welcome.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_welcome.ctp
new file mode 100644 (file)
index 0000000..413a72a
--- /dev/null
@@ -0,0 +1,3 @@
+<div id="news_frame">
+       {?shipsimu_login_news?}
+</div>
diff --git a/application/shipsimu/templates/de/code/block_company_data.ctp b/application/shipsimu/templates/de/code/block_company_data.ctp
new file mode 100644 (file)
index 0000000..9752acf
--- /dev/null
@@ -0,0 +1,18 @@
+<?php
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'company'));
+
+// Set link text
+$helperInstance->addActionLinkById('company', 'company');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div class="user_name_div">
+       Firmenstatus: <span class="company_status">{?company_status?}</span>
+</div>
+<div class="user_profile_div">
+       {?company?}
+</div>
diff --git a/application/shipsimu/templates/de/code/block_persona_data.ctp b/application/shipsimu/templates/de/code/block_persona_data.ctp
new file mode 100644 (file)
index 0000000..bff6bfa
--- /dev/null
@@ -0,0 +1,27 @@
+<?php
+// Get a helper instance for the profile link (and maybe later more!)
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'profile'));
+
+// Prefetch user instance
+$helperInstance->prefetchValueInstance('user');
+
+// Flush the content out
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="user_name_div" class="block_cell">
+       Spielername: <span id="user_name">{?block_username?}</span>
+</div>
+<div id="user_status_div" class="block_cell">
+       Spielerstatus: <span id="user_status">{?block_user_status?}</span>
+</div>
+<div id="user_points_div" class="block_cell">
+       {?currency?}: <span id="user_points">{?block_points?}</span>
+</div>
+<div id="user_profile_div" class="block_cell">
+       {?profile?}
+</div>
+<div id="user_registered_div" class="block_cell">
+       Angemeldet seit: <span id="registered">{?block_registered?}</span>
+</div>
diff --git a/application/shipsimu/templates/de/code/captch_graphic_code.ctp b/application/shipsimu/templates/de/code/captch_graphic_code.ctp
new file mode 100644 (file)
index 0000000..121fb00
--- /dev/null
@@ -0,0 +1,23 @@
+<?php
+// Get a helper instance without a form tag
+$captchaHelper = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'captcha_code', false, false));
+
+// Add input field with text for CAPTCHA code
+$captchaHelper->addFieldText('captcha_code', "Bitte wiederhole den Code:");
+$captchaHelper->addInputTextField('c_code');
+
+// Add hidden field with validation hash
+$captchaHelper->addInputHiddenField('hash', $this->readVariable('captcha_hash'));
+
+// Flush content
+$captchaHelper->flushContent();
+
+// [EOC]
+?>
+<div class="captcha_image">
+       <img src="$config[base_url]/index.php?app={?app_short_name?}&amp;page=code_captcha&amp;encrypt={?encrypted_code?}&amp;request=image"
+        alt="CAPTCHA-Bild" title="CAPTCHA-Bild" class="captcha_img" />
+</div>
+<div class="captcha_code">
+       {?captcha_code?}
+</div>
diff --git a/application/shipsimu/templates/de/code/confirm_link.ctp b/application/shipsimu/templates/de/code/confirm_link.ctp
new file mode 100644 (file)
index 0000000..25f6e67
--- /dev/null
@@ -0,0 +1,25 @@
+<?php
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'direct_login'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('direct_login');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Best&auml;tigung Deiner Email-Adresse:
+</div>
+
+<div id="content_body">
+       Hallo <span class="data_username">{?username?}</span>! Du hast heute deine
+       Email-Addresse best&auml;tigt, wodurch alle Spielefunktionen entsperrt
+       worden sind. Viel Spass beim Spielen!
+</div>
+
+<div id="content_footer">
+       {?direct_login?}
+</div>
diff --git a/application/shipsimu/templates/de/code/emergency_exit.ctp b/application/shipsimu/templates/de/code/emergency_exit.ctp
new file mode 100644 (file)
index 0000000..e974daf
--- /dev/null
@@ -0,0 +1,29 @@
+{?header:title="Problem in application framework detected!"?}
+
+<div id="emergency_message">
+       $content[message]
+</div>
+
+<div id="emergency_backtrace">
+       <div id="backtrace_header">
+               File inclusion backtrace:
+       </div>
+       <div id="backtrace_content">
+               $content[backtrace]
+       </div>
+</div>
+
+<div id="stats_box">
+       <div id="stats_header">
+               Statistics
+       </div>
+       <div id="stats_objects">
+               Total objects: $content[total_objects]
+       </div>
+       <div id="stats_includes">
+               Loaded class files: $content[total_includes]
+               <span class="hint">(Including exception and interfaces.)</span>
+       </div>
+</div>
+
+{?footer_msg:footer_msg="Please contact the support and supply the full above message, if you think you are not qualified to fix this problem."?}
diff --git a/application/shipsimu/templates/de/code/footer.ctp b/application/shipsimu/templates/de/code/footer.ctp
new file mode 100644 (file)
index 0000000..aa82e68
--- /dev/null
@@ -0,0 +1,4 @@
+</div> <!-- masterbox //-->
+
+</body>
+</html>
diff --git a/application/shipsimu/templates/de/code/footer_msg.ctp b/application/shipsimu/templates/de/code/footer_msg.ctp
new file mode 100644 (file)
index 0000000..fb1de36
--- /dev/null
@@ -0,0 +1,8 @@
+       <div id="footer_message">
+               $content[footer_msg]
+       </div>
+
+</div> <!-- masterbox //-->
+
+</body>
+</html>
diff --git a/application/shipsimu/templates/de/code/government_failed_main.ctp b/application/shipsimu/templates/de/code/government_failed_main.ctp
new file mode 100644 (file)
index 0000000..b073132
--- /dev/null
@@ -0,0 +1,106 @@
+<?php
+///////////////////////////////
+// Assign personal user data //
+///////////////////////////////
+
+// Get a new instance for personal data
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'persona_data'));
+
+// Set the data source instance which must exist in registry
+$blockInstance->prefetchValueInstance('user');
+
+// Assign fields with template variables
+$blockInstance->assignField('username');
+$blockInstance->assignFieldWithFilter('user_status', "user_status_translator");
+
+// Shall we include registration date?
+if ($blockInstance->ifIncludeRegistrationStamp()) {
+       // Then assign it as well!
+       $blockInstance->assignFieldWithFilter('registered', 'formatTimestamp');
+} // END - if
+
+// Flush the content out to a template variable
+$blockInstance->flushContent();
+
+//////////////////////////////////////
+// Assign the shipping company data //
+//////////////////////////////////////
+
+// Get a new instance for personal data
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'company_data'));
+
+// Set the data source instance
+$blockInstance->prefetchValueInstance('company', 'user');
+
+// Assign the company name
+if ($blockInstance->getValueInstance()->ifUserIsFounder()) {
+       // User is the founder of the company
+       $blockInstance->assignMessageField('company_status', "user_is_company_founder");
+       $blockInstance->assignLinkFieldWithAction('company' , "company_overview");
+       $blockInstance->assignMessageField('company', "link_text_company_overview");
+       $blockInstance->assignMessageField('company_title', "link_title_company_overview");
+} elseif ($blockInstance->getValueInstance()->ifUserIsOwner()) {
+       // User owns the company
+       $blockInstance->assignMessageField('company_status', "user_is_company_owner");
+       $blockInstance->assignLinkFieldWithAction('company' , "company_overview");
+       $blockInstance->assignMessageField('company', "link_text_company_overview");
+       $blockInstance->assignMessageField('company_title', "link_title_company_overview");
+} elseif ($blockInstance->getValueInstance()->ifUserIsEmployee()) {
+       // User is employed in company
+       $blockInstance->assignMessageField('company_status', "user_is_employed_in_company");
+       $blockInstance->assignLinkFieldWithAction('company' , "employee_overview");
+       $blockInstance->assignMessageField('company', "link_text_employee_overview");
+       $blockInstance->assignMessageField('company_title', "link_title_employee_overview");
+} else {
+       // No company participation!
+       $blockInstance->assignMessageField('company_status', "user_not_assigned_company");
+       $blockInstance->assignLinkFieldWithAction('company' , "company");
+       $blockInstance->assignMessageField('company', "link_text_company");
+       $blockInstance->assignMessageField('company_title', "link_title_company");
+}
+
+// Flush the content out to a template variable
+$blockInstance->flushContent();
+
+// Get helper instance
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout'));
+
+// Add action
+$linkInstance->addActionLinkById('logout', 'logout');
+
+// Flush the content
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Willkommen zum Staat in <span class="app_name">{?app_full_name?}</span>!
+</div>
+
+<div id="content_body">
+       {?government_failed_content?}
+</div>
+
+<div id="persona_data" title="Informationen zu Deinem Spieleaccount">
+       <div id="persona_header">
+               Account-Infos:
+       </div>
+
+       <div id="persona_body">
+               {?persona_data?}
+       </div>
+
+       <div id="logout">
+               {?logout?}
+       </div>
+</div>
+
+<div id="company_data" title="Informationen zu der aktuell ausgew&auml;hlten Reederei">
+       <div id="company_header">
+               Reederei-Infos:
+       </div>
+
+       <div id="company_body">
+               {?company_data?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/header.ctp b/application/shipsimu/templates/de/code/header.ctp
new file mode 100644 (file)
index 0000000..ed67731
--- /dev/null
@@ -0,0 +1,21 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de" lang="de">
+<head>
+       <title>
+               {?app_full_name?} - {?title?}
+       </title>
+
+       <meta name="author" content="$config[meta_author]" />
+       <meta name="publisher" content="$config[meta_publisher]" />
+       <meta name="keywords" content="$config[meta_keywords]" />
+       <meta name="robots" content="index,follow" />
+       <meta name="description" content="$config[meta_description]" />
+       <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
+       <meta http-equiv="content-style-type" content="text/css" />
+       <meta http-equiv="content-script-type" content="text/javascript" />
+       <meta http-equiv="language" content="de" />
+       {?header_extras_hook?}
+</head>
+
+<body>
+<div id="masterbox">
diff --git a/application/shipsimu/templates/de/code/header_extras_hook.ctp b/application/shipsimu/templates/de/code/header_extras_hook.ctp
new file mode 100644 (file)
index 0000000..4375e22
--- /dev/null
@@ -0,0 +1 @@
+<!-- Some extra CSS/JS stuff should be added here (by script!) //-->
diff --git a/application/shipsimu/templates/de/code/home.ctp b/application/shipsimu/templates/de/code/home.ctp
new file mode 100644 (file)
index 0000000..c530602
--- /dev/null
@@ -0,0 +1,7 @@
+<div id="content_header">
+       Willkommen zum <span class="app_name">{?app_full_name?}</span>
+</div>
+
+<div id="news_frame">
+       {?shipsimu_news?}
+</div>
diff --git a/application/shipsimu/templates/de/code/login_failed.ctp b/application/shipsimu/templates/de/code/login_failed.ctp
new file mode 100644 (file)
index 0000000..166c48e
--- /dev/null
@@ -0,0 +1,46 @@
+<?php
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'login_retry'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('login_retry');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Du bist nicht mehr im Spiel eingeloggt!
+</div>
+
+<div id="content_body">
+       <div id="login_failed_header">
+               Du bist nicht mehr in <span class="app_name">{?app_full_name?}</span> eingeloggt.
+               Dies kann verschiedene Gr&uuml;nde haben:
+       </div>
+
+       <ol id="login_failed_list">
+               <li>Dein Browser nimmt keine Cookies an.</li>
+               <li>Du hast den Loginbereich aus deinen Bookmarks/Favoriten aufgerufen
+                       und die Cookies sind gel&ouml;scht.</li>
+               <li>Es besteht ein Problem mit dem Server, wof&uuml;r du meistens nichts
+                       kannst. Bitte kontaktiere den Support, falls dieses Problem
+                       weiterhin besteht.</li>
+       </ol>
+
+       <div id="login_failed_footer">
+               Wenn du den Support kontaktierst, halte bitte s&auml;mtliche relevante
+               Informationen - <span class="important_note">nicht aber dein Passwort</span>
+               - bereit. Du kannst auch einen Screenshot dieser Seite anfertigen und dem
+               Support diesen senden!
+       </div>
+</div>
+
+<div id="content_footer">
+       <div id="login_retry">
+               {?login_retry?}
+       </div>
+
+       Vielen Dank f&uuml;r deine Mitarbeit! :-)
+</div>
diff --git a/application/shipsimu/templates/de/code/login_form.ctp b/application/shipsimu/templates/de/code/login_form.ctp
new file mode 100644 (file)
index 0000000..ae60048
--- /dev/null
@@ -0,0 +1,99 @@
+<?php
+// Get helper instance for web forms. This will add the opening form-tag to
+// the helper's render cache which is simply a small variable in the class
+// BaseHelper.
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_user_login'));
+
+// Formular deaktiviert?
+if ($helperInstance->ifLoginIsEnabled()) {
+       // Formular ist aktiv
+       $helperInstance->addFormGroup('login', "Gebe hier deine Logindaten ein:");
+
+       // Welches Loginverfahren wurde konfiguriert?
+       if ($helperInstance->ifLoginWithUsername()) {
+               // Login mit Username
+               $helperInstance->addFormSubGroup('username', "Bitte mit deinem Nickname einloggen.");
+               $helperInstance->addFieldText('username', "Dein Nickname:");
+               $helperInstance->addInputTextField('username');
+       } elseif ($helperInstance->ifLoginWithEmail()) {
+               // Login mit Email
+               $helperInstance->addFormSubGroup('email', "Bitte mit deiner Email-Adresse einloggen.");
+               $helperInstance->addFieldText('email', "Deine Email-Addresse:");
+               $helperInstance->addInputTextField('email');
+       } else {
+               // Login mit Email/Username
+               $helperInstance->addFormSubGroup('user_email', "Bitte mit deinem Nickname oder Email-Adresse einloggen.");
+               $helperInstance->addFieldText('user_email', "Dein Nickname/Email:");
+               $helperInstance->addInputTextField('user_email');
+       }
+
+       $helperInstance->addFormSubGroup('pass', "Gebe dein Passwort von der Anmeldung ein.");
+       $helperInstance->addFieldText('pass', "Dein Passwort:");
+       $helperInstance->addInputPasswordField('pass');
+
+       // CAPTCHA enabled?
+       if ($helperInstance->ifFormSecuredWithCaptcha()) {
+               $helperInstance->addFormGroup('captcha_user', "Das Benutzer-Login ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du dich einloggen kannst.");
+               $helperInstance->addCaptcha();
+       } // END - if
+
+       // Submit buttons
+       $helperInstance->addFormGroup('buttons_user', "Alles richtig eingegeben?");
+       $helperInstance->addInputResetButton("Formular leeren");
+       $helperInstance->addInputSubmitButton("Zum Spiel einloggen");
+} else {
+       // Formular deaktiviert
+       $helperInstance->addFormNote('form_deactivated', "Einloggen in&#39;s Spiel ist derzeit administrativ deaktiviert worden. Bitte komme sp&auml;ter noch mal wieder.");
+       $helperInstance->addFormNote('admin_notice', "Nachricht vom Admin: <span id=\"disabled_reason\">".$this->getConfigInstance()->readConfig('login_disabled_reason')."</span>");
+}
+
+// Formular schliessen
+$helperInstance->flushContent();
+
+// Ist Gastlogin erlaubt?
+if ($helperInstance->ifGuestLoginAllowed()) {
+       // Neue Helper-Instanz holen
+       $helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_guest_login'));
+       $helperInstance->addInputHiddenConfiguredField('user', 'guest_login');
+       $helperInstance->addInputHiddenConfiguredField('passwd', 'guest_login');
+
+       // CAPTCHA enbaled?
+       if ($helperInstance->ifFormSecuredWithCaptcha()) {
+               $helperInstance->addFormGroup('captcha_guest', "Unser Gast-Login ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, damit du dich einloggen kannst.");
+               $helperInstance->addCaptcha();
+       } // END - if
+
+       // Submit button
+       $helperInstance->addFormGroup('buttons_guest', "Gastlogins sind in der Funkionsweise eingeschr&auml;nkt. Mehr dazu unter &quot;Gastlogin&quot;.");
+       $helperInstance->addInputSubmitButton("Als Gast einloggen");
+       $helperInstance->flushContent();
+}
+
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'register'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('register_login');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Einloggen zu <span class="app_name">{?app_full_name?}</span>
+</div>
+
+<div id="content_body">
+       <div id="login_box">
+               {?shipsimu_user_login?}
+       </div>
+
+       <div id="guest_login">
+               {?shipsimu_guest_login?}
+       </div>
+</div>
+
+<div id="content_footer">
+       Noch kein Spieleaccount? {?register?}
+</div>
diff --git a/application/shipsimu/templates/de/code/login_main.ctp b/application/shipsimu/templates/de/code/login_main.ctp
new file mode 100644 (file)
index 0000000..56adbab
--- /dev/null
@@ -0,0 +1,107 @@
+<?php
+///////////////////////////////
+// Assign personal user data //
+///////////////////////////////
+
+// Get a new instance for personal data
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'persona_data'));
+
+// Set the data source instance which must exist in registry
+$blockInstance->prefetchValueInstance('user', 'user_points');
+
+// Assign fields with template variables
+$blockInstance->assignField('username');
+$blockInstance->assignFieldWithFilter('user_status', 'user_status_translator');
+$blockInstance->assignFieldWithFilter('points', 'format_number');
+
+// Shall we include registration date?
+if ($blockInstance->ifIncludeRegistrationStamp()) {
+       // Then assign it as well!
+       $blockInstance->assignFieldWithFilter('registered', 'format_timestamp');
+} // END - if
+
+// Flush the content out to a template variable
+$blockInstance->flushContent();
+
+//////////////////////////////////////
+// Assign the shipping company data //
+//////////////////////////////////////
+
+// Get a new instance for personal data
+$blockInstance = ObjectFactory::createObjectByConfiguredName('web_block_helper', array($this, 'company_data'));
+
+// Set the data source instance
+$blockInstance->prefetchValueInstance('company', 'user');
+
+// Assign the company name
+if ($blockInstance->getValueInstance()->ifUserIsFounder()) {
+       // User is the founder of the company
+       $blockInstance->assignMessageField('company_status', 'user_is_company_founder');
+       $blockInstance->assignLinkFieldWithAction('company' , 'company_overview');
+       $blockInstance->assignMessageField('company', 'link_text_company_overview');
+       $blockInstance->assignMessageField('company_title', 'link_title_company_overview');
+} elseif ($blockInstance->getValueInstance()->ifUserIsOwner()) {
+       // User owns the company
+       $blockInstance->assignMessageField('company_status', 'user_is_company_owner');
+       $blockInstance->assignLinkFieldWithAction('company' , 'company_overview');
+       $blockInstance->assignMessageField('company', 'link_text_company_overview');
+       $blockInstance->assignMessageField('company_title', 'link_title_company_overview');
+} elseif ($blockInstance->getValueInstance()->ifUserIsEmployee()) {
+       // User is employed in company
+       $blockInstance->assignMessageField('company_status', 'user_is_employed_in_company');
+       $blockInstance->assignLinkFieldWithAction('company' , 'employee_overview');
+       $blockInstance->assignMessageField('company', 'link_text_employee_overview');
+       $blockInstance->assignMessageField('company_title', 'link_title_employee_overview');
+} else {
+       // No company participation!
+       $blockInstance->assignMessageField('company_status', 'user_not_assigned_company');
+       $blockInstance->assignLinkFieldWithAction('company' , 'company');
+       $blockInstance->assignMessageField('company', 'link_text_company');
+       $blockInstance->assignMessageField('company_title', 'link_title_company');
+}
+
+// Flush the content out to a template variable
+$blockInstance->flushContent();
+
+// Get helper instance
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'logout'));
+
+// Add action
+$linkInstance->addActionLinkById('logout', 'logout');
+
+// Flush the content
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Willkommen im Loginbereich von <span class="app_name">{?app_full_name?}</span>!
+</div>
+
+<div id="content_body">
+       {?login_content?}
+</div>
+
+<div id="persona_data" title="Informationen zu Deinem Spieleaccount">
+       <div id="persona_header">
+               Account-Infos:
+       </div>
+
+       <div id="persona_body">
+               {?persona_data?}
+       </div>
+
+       <div id="logout">
+               {?logout?}
+       </div>
+</div>
+
+<div id="company_data" title="Informationen zu der aktuell ausgew&auml;hlten Reederei">
+       <div id="company_header">
+               Reederei-Infos:
+       </div>
+
+       <div id="company_body">
+               {?company_data?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/logout_done.ctp b/application/shipsimu/templates/de/code/logout_done.ctp
new file mode 100644 (file)
index 0000000..9843f50
--- /dev/null
@@ -0,0 +1,19 @@
+<?php
+// Get helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'relogin'));
+
+// Set link text
+$helperInstance->addLinkWithTextById('relogin');
+
+// Flush the content
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Du bist jetzt aus dem Spiel ausgeloggt!
+</div>
+
+<div id="content_body">
+       Du kannst dich nun {?relogin?} oder weiter auf unseren Seiten bleiben. ;-)
+</div>
diff --git a/application/shipsimu/templates/de/code/mail_debug.ctp b/application/shipsimu/templates/de/code/mail_debug.ctp
new file mode 100644 (file)
index 0000000..e62dd07
--- /dev/null
@@ -0,0 +1,25 @@
+<div class="debug_header">
+       Mail-Debug-Ausgabe:
+</div>
+
+<div class="mail_header">
+       <div class="mail_header_line">
+               <span class="mail_sender">Von:</span> <span class="mail_info">{?sender?}</span>
+       </div>
+       <div class="mail_header_line">
+               <span class="mail_recipient">An:</span> <span class="mail_info">{?recipient?}</span>
+       </div>
+       <div class="mail_header_line">
+               <span class="mail_subject">Betreff:</span> <span class="mail_info">{?subject?}</span>
+       </div>
+</div>
+
+<div class="mail_text_box">
+       <div class="mail_message">
+               Nachricht:
+       </div>
+
+       <div class="mail_content">
+               {?message?}
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/code/register_form.ctp b/application/shipsimu/templates/de/code/register_form.ctp
new file mode 100644 (file)
index 0000000..90dca57
--- /dev/null
@@ -0,0 +1,134 @@
+<?php
+// Get helper instance for web forms. This will add the opening form-tag to
+// the helper's render cache which is simply a small variable in the class
+// BaseHelper.
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_register'));
+
+// Always ask at least for nickname and password
+$helperInstance->addFormGroup('login', "Bitte gebe hier gew&uuml;nschten Nickname und dein Zugangspasswort ein.");
+$helperInstance->addFormSubGroup('username', "Dein Nickname wird erst nach Absenden des Formulares gepr&uuml;ft. Sp&auml;ter bauen wir dann einen automatischen Test ein, der dir sofort zeigt, ob der Nickname bereits vergeben ist.");
+$helperInstance->addFieldText('username', "Nickname im Spiel:");
+$helperInstance->addInputTextField('username');
+$helperInstance->addFormSubGroup('pass', "Dein Passwort sollte nicht zu leicht erratbar sein. Sp&auml;ter bauen wir hier noch einen automatischen Test ein, der dir sofort die Passwortst&auml;rke anzeigt.");
+$helperInstance->addFieldText('pass1', "Passwort:");
+$helperInstance->addInputPasswordField('pass1');
+$helperInstance->addFieldText('pass2', "Passwortwiederholung:");
+$helperInstance->addInputPasswordField('pass2');
+
+// Does this registration require an email?
+if ($helperInstance->ifRegisterRequiresEmailVerification()) {
+       $helperInstance->addFormGroup('email', "Bitte gebe deine Email zweimal (ein zweites Mal zur Best&auml;tigung) ein, damit wir dir deinen Freischaltlink zusenden k&ouml;nnen.");
+       $helperInstance->addFieldText('email1', "Email-Adresse:");
+       $helperInstance->addInputTextField('email1');
+       $helperInstance->addFieldText('email2', "Wiederholung Email-Adresse:");
+       $helperInstance->addInputTextField('email2');
+
+       // Must the email address be unique in this system?
+       if ($helperInstance->ifEmailMustBeUnique()) {
+               $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
+       } // END - if
+} // END - if
+
+// Shall we also ask some personal data to complete the profile?
+if ($helperInstance->ifRegisterIncludesProfile()) {
+       $helperInstance->addFormGroup('profile', "Hier kannst du zus&auml;tzlich deine Profildaten vorweg eingeben, du kannst sie aber auch nach dem Login vervollst&auml;ndigen!");
+
+       if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
+               $helperInstance->addFormSubGroup('email', "Die Angabe deiner Email-Adresse ist nur dann n&ouml;tig, wenn du auch Email-Benachrichtigungen (<span id=\"add_note\">*1</span>) haben m&ouml;chtest.");
+               $helperInstance->addFieldText('email1', "Email-Adresse:");
+               $helperInstance->addInputTextField('email1');
+
+               // Must the email address be unique in this system?
+               if ($helperInstance->ifEmailMustBeUnique()) {
+                       $helperInstance->addFormNote('email', "Die von dir eingegebene Email-Adresse darf nur einmal im Spiel verwendet worden sein.");
+               } // END - if
+       } // END - if
+
+       // Persoenliche Daten mit in der Anmeldung abfragen?
+       if ($helperInstance->ifRegisterIncludesPersonaData()) {
+               $helperInstance->addFormSubGroup('persona', "Wenn du magst, dann vervollst&auml;ndige deine komplette Adresse mit deinem Namen.");
+               $helperInstance->addFieldText('surname', "Dein Vorname:");
+               $helperInstance->addInputTextField('surname');
+               $helperInstance->addFieldText('family', "Dein Nachname:");
+               $helperInstance->addInputTextField('family');
+               $helperInstance->addFieldText('street', "Strasse und Hausnummer:");
+               $helperInstance->addInputTextField('street');
+               $helperInstance->addFieldText('city', "Wohnort:");
+               $helperInstance->addInputTextField('city');
+
+               // Include birthday?
+               if ($helperInstance->ifProfileIncludesBirthDay()) {
+                       $helperInstance->addFormSubGroup('birthday', "Verrate uns doch dein Geburtsdatum, als Dankesch&ouml;n erh&auml;lst du interessante Pr&auml;mien - ausschliesslich per Email - zum Geburtstag zugesandt! G&uuml;ltiges Format: TT.MM.JJJJ");
+                       $helperInstance->addInputTextField('birth_day');
+                       $helperInstance->addFieldText('birth_day', ".");
+                       $helperInstance->addInputTextField('birth_month');
+                       $helperInstance->addFieldText('birth_day', ".");
+                       $helperInstance->addInputTextField('birth_year');
+               } // END - if
+       } // END - if
+
+       $helperInstance->addFormSubGroup('zip', "Magst du uns auch deine Postleitzahl verraten?");
+       $helperInstance->addFieldText('zip', "Postleitzahl:");
+       $helperInstance->addInputTextField('zip');
+
+       $helperInstance->addFormSubGroup('chat', "Gebe hier deine Nicknames bzw. Nummern an:");
+
+       if ($helperInstance->ifChatEnabled('icq')) {
+               $helperInstance->addFieldText('icq', "ICQ-Nummer:");
+               $helperInstance->addInputTextField('icq');
+       } // END - if
+
+       if ($helperInstance->ifChatEnabled('jabber')) {
+               $helperInstance->addFieldText('jabber', "Jabber:");
+               $helperInstance->addInputTextField('jabber');
+       } // END - if
+
+       if ($helperInstance->ifChatEnabled('yahoo')) {
+               $helperInstance->addFieldText('yahoo', "Yahoo!:");
+               $helperInstance->addInputTextField('yahoo');
+       } // END - if
+
+       if ($helperInstance->ifChatEnabled('aol')) {
+               $helperInstance->addFieldText('aol', "AOL-Screenname:");
+               $helperInstance->addInputTextField('aol');
+       } // END - if
+
+       if ($helperInstance->ifChatEnabled('msn')) {
+               $helperInstance->addFieldText('msn', "MSN:");
+               $helperInstance->addInputTextField('msn');
+       } // END - if
+
+       if (!$helperInstance->ifRegisterRequiresEmailVerification()) {
+               $helperInstance->addFormExtraNote(1, "Die Benachrichtigungen per sind im Loginbereich verfeinerbar, welche du genau haben willst.");
+       } // END - Extra note
+
+} // END - ask profile data
+
+// Spielregeln abfragen
+$helperInstance->addFormGroup('rules', "Bitte lese dir die Spieleregeln gut durch und kreuze dann &quot;Ja, ich akzeptiere die aktuellen Spielregeln&quot; an.");
+$helperInstance->addFieldText('rules', "Ja, ich akzeptiere die aktuellen Spielregeln:");
+$helperInstance->addInputCheckboxField('rules', false);
+
+// Add CAPTCHA?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha', "Bitte wiederhole den angezeigten Code damit die Anmeldung abgeschlossen werden kann.");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Final note and submit buttons
+$helperInstance->addFormGroup('buttons', "Wenn du alle ben&ouml;tigten Felder korrekt ausgef&uuml;t hast, kannst du die Anmeldung abschliessen.");
+
+$helperInstance->addInputResetButton("Alles nochmal eingeben");
+$helperInstance->addInputSubmitButton("Anmeldung zum Spiel abschliessen");
+$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
+$helperInstance->flushContent();
+
+// [EOC]
+?>
+<div id="content_header">
+       Anmeldung bei <span class="app_name">{?app_full_name?}</span>
+</div>
+
+<div id="register_box">
+       {?shipsimu_register?}
+</div>
diff --git a/application/shipsimu/templates/de/code/shipsimu_main.ctp b/application/shipsimu/templates/de/code/shipsimu_main.ctp
new file mode 100644 (file)
index 0000000..3dd1296
--- /dev/null
@@ -0,0 +1,27 @@
+{?header?}
+
+<div id="main_header">
+       {?shipsimu_header?}
+</div>
+
+<div id="menu">
+       {?menu?}
+</div>
+
+<div id="advert">
+       {?nav_advert?}
+</div>
+
+<div id="language">
+       {?language_selector?}
+</div>
+
+<div id="main_content">
+       {?content?}
+</div>
+
+<div id="main_footer">
+       {?shipsimu_footer?}
+</div>
+
+{?footer?}
diff --git a/application/shipsimu/templates/de/code/status.ctp b/application/shipsimu/templates/de/code/status.ctp
new file mode 100644 (file)
index 0000000..730a240
--- /dev/null
@@ -0,0 +1,7 @@
+<div id="content_header">
+       Es besteht ein Problem mit Ihrem Account
+</div>
+
+<div id="news_frame">
+       {?status_problem?}
+</div>
diff --git a/application/shipsimu/templates/de/emails/.htaccess b/application/shipsimu/templates/de/emails/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/de/emails/text_resend_link.tpl b/application/shipsimu/templates/de/emails/text_resend_link.tpl
new file mode 100644 (file)
index 0000000..ab28bab
--- /dev/null
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<text-mail>
+       <mail-data>
+               <sender-address value="$config[admin_email]" />
+               <subject-line value="Anforderung deines Best&auml;tigungslinks" />
+               <recipient-address value="{?email?}" />
+               <message>
+               <![CDATA[Hallo {?username?}!
+
+Du (oder ein anderer) hattest soeben deinen Best&auml;tigungslink erneut angefordert. Solltest du dies nicht gewesen sein, bitten wir dich den Vorfall zu entschuldigen.
+
+Hier ist nun dein Best&auml;tigungslink. Der alte aus der Anmeldemail ist somit nicht mehr g&uuml;ltig!
+
+$config[base_url]/index.php?app={?app_short_name?}&page=confirm&username={?username?}&confirm={?confirm_hash?}
+
+Solltest du die URL nicht anklicken k&ouml;nnen, versuche diese in die Adresszeile deines Browsers zu kopieren.
+
+Alternativ kannst du im Spielebereich unter Best&auml;tigungscode den folgenden Code reinkopieren oder eingeben:
+
+{?confirm_hash?}
+
+Solltest du Fragen dazu oder Probleme mit der Best&auml;tigung haben, so melde dich bitte beim Support-Team.
+
+Mit freundlichen Gr&uuml;&szlig;en,
+  Dein {?app_short_name?}-Team
+
+{?mail_footer?}]]>
+               </message>
+       </mail-data>
+</text-mail>
diff --git a/application/shipsimu/templates/de/html/.htaccess b/application/shipsimu/templates/de/html/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/de/html/nav_advert.tpl b/application/shipsimu/templates/de/html/nav_advert.tpl
new file mode 100644 (file)
index 0000000..22da43b
--- /dev/null
@@ -0,0 +1 @@
+<!-- Put your ads code here which shall be shown below the navigation //-->
diff --git a/application/shipsimu/templates/de/html/selector_ship-simu.tpl b/application/shipsimu/templates/de/html/selector_ship-simu.tpl
new file mode 100644 (file)
index 0000000..b96640e
--- /dev/null
@@ -0,0 +1,17 @@
+<div id="selector_content">
+       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
+               Gr&uuml;nden Sie eine virtuelle Reederei an den bedeutestens
+               Welth&auml;fen! Oder treten Sie einer Reederei als Angestellter bei und
+               arbeiten Sie sich bis in die Chef-Etagge hoch!
+       </div>
+
+       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
+               Oder fangen Sie als Matrose auf einem Passagierschiff (virtuell) an zu
+               arbeiten und werden Sie nach wenigen Kreuzfahrten bald Kapit&auml;n!
+       </div>
+
+       <div style="text-align: left; padding-top: 15px; padding-left: 10px; padding-right: 10px">
+               Oder buchen Sie eine virtuelle Kreuzfahrt durch die bekannten Meeren in
+               {!POINTS!} in einer Luxus-Suite!
+       </div>
+</div>
diff --git a/application/shipsimu/templates/de/image/base_code.xml b/application/shipsimu/templates/de/image/base_code.xml
new file mode 100644 (file)
index 0000000..5de71be
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<image>
+       <type value="{?image_type?}" />
+       <base>
+               <name value="{?image_name?}" />
+       </base>
+       <resolution>
+               <width value="{?image_width?}" />
+               <height value="{?image_height?}" />
+       </resolution>
+       <background-color>
+               <red value="{?image_bg_red?}" />
+               <green value="{?image_bg_green?}" />
+               <blue value="{?image_bg_blue?}" />
+       </background-color>
+       <foreground-color>
+               <red value="{?image_fg_red?}" />
+               <green value="{?image_fg_green?}" />
+               <blue value="{?image_fg_blue?}" />
+       </foreground-color>
+       <image-string value="groupable">
+               <string-name value="{?image_string_name?}" />
+               <x value="{?image_x?}" />
+               <y value="{?image_y?}" />
+               <font-size value="{?image_size?}" />
+               <text value="{?image_string?}" />
+       </image-string>
+</image>
diff --git a/application/shipsimu/templates/de/image/code_captcha.img b/application/shipsimu/templates/de/image/code_captcha.img
new file mode 100644 (file)
index 0000000..223e4fb
--- /dev/null
@@ -0,0 +1,78 @@
+<?php
+// Needed in every image template to initialy set the image type
+$helper = ImageHelper::createImageHelper($this, 'png');
+$helper->setImageName('code_captcha');
+$helper->setBaseImage('base_code');
+
+// Set image dimensions
+$helper->setWidth(100);
+$helper->setHeight(50);
+
+// Get random number
+$rand = $helper->getRngInstance()->randomNumber(0, 6);
+
+// Background and foreground color
+switch ($rand) {
+       case 1:
+               // First varriant
+               $helper->setBackgroundColorRedGreenBlue('rand', 0x90  , 0x00  );
+               $helper->setForegroundColorRedGreenBlue(0x00  , 0xff  , 'rand');
+               break;
+
+       case 2:
+               // Second varriant
+               $helper->setBackgroundColorRedGreenBlue(0x90  , 'rand', 0x00  );
+               $helper->setForegroundColorRedGreenBlue(0xff  , 0x00  , 'rand');
+               break;
+
+       case 3:
+               // Third varriant
+               $helper->setBackgroundColorRedGreenBlue('rand', 0x00  , 0x90  );
+               $helper->setForegroundColorRedGreenBlue(0x00  , 'rand', 0xff  );
+               break;
+
+       case 4:
+               // Forth varriant
+               $helper->setBackgroundColorRedGreenBlue(0x00  , 0x90  , 'rand');
+               $helper->setForegroundColorRedGreenBlue(0x00  , 'rand', 0xa0  );
+               break;
+
+       case 5:
+               // Fith varriant
+               $helper->setBackgroundColorRedGreenBlue('rand', 0x00  , 0x90  );
+               $helper->setForegroundColorRedGreenBlue(0x00  , 0xe0  , 'rand');
+               break;
+
+       default:
+               // Last varriant
+               $helper->setBackgroundColorRedGreenBlue(0x00  , 'rand', 0x90  );
+               $helper->setForegroundColorRedGreenBlue(0xff  , 0x00  , 'rand');
+               break;
+}
+
+// Random X/Y factors...
+$xRand = $helper->getRngInstance()->randomNumber(0, 45);
+$yRand = $helper->getRngInstance()->randomNumber(0, 25);
+
+// Add code
+$helper->addTextLine('code');
+$helper->setCoord((5 + $xRand), (5 + $yRand));
+$helper->setFontSize('rand');
+$helper->setImageString('{?decrypted_code?}');
+
+// Only for debug!
+/*
+$helper->addTextLine('debug');
+$helper->setCoord(90, 35);
+$helper->setFontSize(3);
+$helper->setImageString($rand);
+*/
+
+// Flush content to the template engine
+$helper->flushContent();
+
+// Comment this out if image is done
+//$this->debugInstance();
+
+// [EOF]
+?>
diff --git a/application/shipsimu/templates/de/image/emergency_exit.img b/application/shipsimu/templates/de/image/emergency_exit.img
new file mode 100644 (file)
index 0000000..bf67aa7
--- /dev/null
@@ -0,0 +1,18 @@
+<?php
+// Needed in every image template to initialy set the image type
+$helper = ImageHelper::createImageHelper($this, 'png');
+$helper->setImageName('emergency_exit');
+$helper->setBaseImage('base_exit');
+
+// Set image dimensions
+$helper->setWidth(100);
+$helper->setHeight(50);
+
+// Flush content to the template engine
+//$helper->flushContent();
+
+// Comment this out if image is done
+$this->debugInstance();
+
+// [EOF]
+?>
diff --git a/application/shipsimu/templates/de/menu/.htaccess b/application/shipsimu/templates/de/menu/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/de/menu/base_menu.xml b/application/shipsimu/templates/de/menu/base_menu.xml
new file mode 100644 (file)
index 0000000..1c93350
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general menu XML file. We should later on convert this into a DTD.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<menu>
+       <block-list block-count="{?block_count?}">
+               <block>
+                       <block-header>
+                               <title>
+                                       <title-id>{?menu_title_id?}</title-id>
+                                       <title-class>{!menu_title_class?}</title-class>
+                                       <title-text>{?menu_title?}</title-text>
+                               </title>
+                       </block-header>
+                       <entry-list entry-count="{?entry_count?}">
+                               <entry>
+                                       <entry-id>{?entry_id?}</entry-id>
+                                       <anchor>
+                                               <anchor-id>{?anchor_id?}</anchor-id>
+                                               <anchor-text>{?anchor_text?}</anchor-text>
+                                               <anchor-title>{?anchor_title?}</anchor-title>
+                                               <anchor-href>{?anchor_href?}</anchor-href>
+                                       </anchor>
+                               </entry>
+                       </entry-list>
+                       <block-footer>
+                               <footer-id>{!footer_id?}</footer>
+                               <footer-class>{?footer_design_class?}</footer-class>
+                               <footer-text>{?menu_footer?}</footer-text>
+                       </block-footer>
+               </block>
+       </block-list>
+</menu>
diff --git a/application/shipsimu/templates/de/menu/generic_menu_entries.xml b/application/shipsimu/templates/de/menu/generic_menu_entries.xml
new file mode 100644 (file)
index 0000000..65c742e
--- /dev/null
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+Generic menu entries. You should leave this template for smooth upgrades.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<menu>
+       <block-list block-count="{?block_count?}">
+               <block>
+                       <block-header>
+                               <title>
+                                       <title-id><![CDATA[home_menu_title]]></title-id>
+                                       <title-class><![CDATA[menu_title]]></title-class>
+                                       <title-text><![CDATA[Home:]]></title-text>
+                               </title>
+                       </block-header>
+                       <entry-list entry-count="{?entry_count?}">
+                               <entry>
+                                       <entry-id><![CDATA[home_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_home]]></anchor-id>
+                                               <anchor-text><![CDATA[Home]]></anchor-text>
+                                               <anchor-title><![CDATA[Zur Startseite]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                               <entry>
+                                       <entry-id><![CDATA[login_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_login]]></anchor-id>
+                                               <anchor-text><![CDATA[Einloggen]]></anchor-text>
+                                               <anchor-title><![CDATA[Zum Spiel {?app_name?} einloggen]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=login]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                               <entry>
+                                       <entry-id><![CDATA[register_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_register]]></anchor-id>
+                                               <anchor-text><![CDATA[Anmeldung]]></anchor-text>
+                                               <anchor-title><![CDATA[Zur Anmeldeseite]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=register]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                               <entry>
+                                       <entry-id><![CDATA[pillory_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_pillory]]></anchor-id>
+                                               <anchor-text><![CDATA[Pranger]]></anchor-text>
+                                               <anchor-title><![CDATA[Zum Pranger]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=pillory]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                       </entry-list>
+                       <block-footer>
+                               <footer-id><![CDATA[home_menu_footer]]></footer-id>
+                               <footer-class><![CDATA[menu_footer]]></footer-class>
+                               <footer-text><![CDATA[Leer]]></footer-text>
+                       </block-footer>
+               </block>
+               <block>
+                       <block-header>
+                               <title>
+                                       <title-id><![CDATA[law_menu_title]]></title-id>
+                                       <title-class><![CDATA[menu_title]]></title-class>
+                                       <title-text><![CDATA[Rechtliches:]]></title-text>
+                               </title>
+                       </block-header>
+                       <entry-list entry-count="{?entry_count?}">
+                               <entry>
+                                       <entry-id><![CDATA[imprint_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_imprint]]></anchor-id>
+                                               <anchor-text><![CDATA[Impressum]]></anchor-text>
+                                               <anchor-title><![CDATA[Impressum]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=imprint]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                               <entry>
+                                       <entry-id><![CDATA[terms_entry]]></entry-id>
+                                       <anchor>
+                                               <anchor-id><![CDATA[menu_terms]]></anchor-id>
+                                               <anchor-text><![CDATA[ANBs]]></anchor-text>
+                                               <anchor-title><![CDATA[Allgemeine Nutzungsbedingungen]]></anchor-title>
+                                               <anchor-href><![CDATA[index.php?app={?app_short_name?}&amp;page=terms]]></anchor-href>
+                                       </anchor>
+                               </entry>
+                       </entry-list>
+                       <block-footer>
+                               <footer-id><![CDATA[law_menu_footer]]></footer-id>
+                               <footer-class><![CDATA[menu_footer]]></footer-class>
+                               <footer-text><![CDATA[Leer]]></footer-text>
+                       </block-footer>
+               </block>
+       </block-list>
+</menu>
diff --git a/application/shipsimu/templates/game/!MISSING b/application/shipsimu/templates/game/!MISSING
new file mode 100644 (file)
index 0000000..57cf1de
--- /dev/null
@@ -0,0 +1,2 @@
+<construction-company extends="{?construction_template?}" />
+<construction-contract extends="{?contract_template?}" />
diff --git a/application/shipsimu/templates/game/.htaccess b/application/shipsimu/templates/game/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/building/.htaccess b/application/shipsimu/templates/game/building/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/building/advanced_research_lab.xml b/application/shipsimu/templates/game/building/advanced_research_lab.xml
new file mode 100644 (file)
index 0000000..48d3e5e
--- /dev/null
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+An advanced research laboratory for conducting simple experiments.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<building extends="base_building">
+       <!-- General building data //-->
+       <building-data>
+               <!-- General data, like short name, type, level and many more. //-->
+               <building-data>
+                       <name>advanced_research_lab</name>
+                       <type>research</type>
+               </building-data>
+       </building-data>
+       <!-- We also have technology denpencies for a building. These must be
+            understand by construction companies who made contracts with the
+            shipping company to construct this building. //-->
+       <dependencies>
+               <!-- A list of required technology to construct this building. //-->
+               <!-- @TODO Find technology types //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- Arcgictecture is required. //-->
+                       <technology-dependency>
+                               <technology-name>architecture</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>10</technology-level>
+                       </technology-dependency>
+                       <!-- Labory equipment is required. //-->
+                       <technology-dependency research-dependency-count="{?research_dependency_count?}">
+                               <technology-name>laboratory_equipment</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>8</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</building>
diff --git a/application/shipsimu/templates/game/building/base_building.xml b/application/shipsimu/templates/game/building/base_building.xml
new file mode 100644 (file)
index 0000000..0949690
--- /dev/null
@@ -0,0 +1,169 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general building template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<building>
+       <!-- General building data //-->
+       <building-data>
+               <!-- Estimated dimensions of the building. //-->
+               <estimated-dimensions>
+                       <!-- Width of the building. //-->
+                       <width>{?width?}</width>
+                       <!-- Height of the building. //-->
+                       <height>{?height?}</height>
+                       <!-- Length of the building. //-->
+                       <length>{?length?}</length>
+               </estimated-dimensions>
+               <!--A summary for this building. //-->
+               <summary>
+                       <![CDATA[{?summary?}]]>
+               </summary>
+               <!-- A full description of this building. //-->
+               <description>
+                       <![CDATA[{?description?}]]>
+               </description>
+               <!-- General data, like short name, type, level and many more. //-->
+               <building-data>
+                       <id>{?id?}</id>
+                       <name>{?name?}</name>
+                       <type>{?type?}</type>
+                       <level>{?level?}</level>
+                       <max-floors>{?max_floors?}</max-floors>
+                       <!-- The owner of this building. //-->
+                       <owner id="{?owner_id?}" type="{?owner_type?}" owned-start="{?owner_start_timestamp?}" owned-end="{?owner_end_timestamp?}" />
+                       <!-- The occupant of this building. //-->
+                       <occupant id="{?occupant_id?}" type="{?occupant_type?}" owned-start="{?occupant_start_timestamp?}" owned-end="{?occupant_end_timestamp?}" />
+                       <!-- When this building was constructed. //-->
+                       <constructed>
+                               <!-- When construction has started. //-->
+                               <construction-started timestamp="{?construction_start_timestamp?}" />
+                               <!-- And when it was finished. //-->
+                               <construction-finished timestamp="{?construction_end_timestamp?}" />
+                       </constructed>
+                       <!-- When this building was destructed. //-->
+                       <destructed>
+                               <!-- When destruction has started. //-->
+                               <destruction-started timestamp="{?destruction_start_timestamp?}" />
+                               <!-- And when it was finished. //-->
+                               <destruction-finished timestamp="{?destruction_end_timestamp?}" />
+                               <!-- A short reason why this building must be destructed or
+                                    demolished. //-->
+                               <destruction-reason>
+                                       <![CDATA[{?destruction_reason?}]]>
+                               </destruction-reason>
+                       </deconstructed>
+               </building-data>
+       </building-data>
+       <!-- All sorts of costs for a building. //-->
+       <costs>
+               <!-- The land-price has to be payed to the simplified government. //-->
+               <land-price currency="{?land_currency?}" />
+               <!-- Construction costs may be empty when this building is bougth from
+                    an other user e.g. a broker //-->
+               <construction-costs>
+                       <currency>{?construction_currency?}</currency>
+                       <construction-company extends="{?construction_template?}">
+                               <!-- The construction company. //-->
+                               <company>
+                                       <company-id>{?construct_id?}</company-id>
+                                       <!-- A construction of a building requires personel. We
+                                            summary their salery here for simplicy. //-->
+                                       <personel-costs currency="{?personel_currency?}" />
+                                       <!-- A lot resources like steel and concrete are required
+                                            for new high buildings. Some older or futuristic may
+                                            require different resources. //-->
+                                       <resource-list extends="{?resources_template?}">
+                                               <!-- A single resource and its amount to construct this
+                                                    building. //-->
+                                               <resource>
+                                                       <resource-id>{?resource_id?}</resource-id>
+                                                       <amount>{?resource_amount?}</amount>
+                                                       <!-- The merchant dealing with this resource. //-->
+                                                       <resource-merchant extends="{?merchant_template?}">
+                                                               <merchant id="{?merchant_id?}" />
+                                                       </resource-merchant>
+                                               </resource>
+                                       </resource-list>
+                               </company>
+                               <!-- The construction contract for constructing this building. //-->
+                               <construction-contract extends="{?contract_template?}">
+                                       <construction-contract id="{?construct_contract_id?}" />
+                               </construction-contract>
+                       </construction-company>
+               </construction-costs>
+               <!-- Running costs are all costs that the owner/occupant has to pay for upkeeping
+                    it like house cleaning. simplified repair costs and in some way
+                    taxes. //-->
+               <running-costs>
+                       <!-- Taxes for the occupied lot. //-->
+                       <taxes currency="{?taxes_currency?}" />
+                       <!-- A building has mostly maintenance costs. //-->
+                       <maintenance>
+                               <!-- Almost all buildings needs to be cleaned. //-->
+                               <cleaning-costs>
+                                       <currency>{?cleaning_currency?}</currency>
+                                       <!-- The cleaning company. //-->
+                                       <cleaning-company id="{?cleaning_id?}" />
+                                       <!-- The contract for cleaning this building. //-->
+                                       <cleaning-contract contract_id="{?cleaning_contract_id?}" />
+                               </cleaning-costs>
+                               <repair-costs>
+                                       <currency>{?repair_currency?}</currency>
+                                       <repair contract_id="{?repair_contract_id?}" />
+                               </repair-costs>
+                       </maintenance>
+               </running-costs>
+               <!-- For constructing a building you sometimes need to take mortgage to
+                    fund the construction costs. //-->
+               <mortgage>
+                       <currency>{?mortgage_currency?}</currency>
+                       <!-- The bank paying the mortage, if not provided, the following
+                            mortage broker must be provided. //-->
+                       <bank id="{?bank_id?}" />
+                       <!-- A mortage broker who has payed the mortage. //-->
+                       <mortgage-broker id="{?broker_id?}" />
+                       <!-- The contract behind the mortage. //-->
+                       <contract id="{?mortage_id?}" />
+               </mortgage>
+       </costs>
+       <!-- We also have technology denpencies for a building. These must be
+            understand by construction companies who made contracts with the
+            shipping company to construct this building. //-->
+       <dependencies>
+               <!-- A list of required technology to construct this building. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A single required technology to construct this building. //-->
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+       <!-- A list of floors this building has. //-->
+       <floor-list floor-count="{?floor_count?}">
+               <!-- A single floor where we can add rooms to. //-->
+               <floor>
+               </floor>
+       </floor-list>
+</building>
diff --git a/application/shipsimu/templates/game/building/research_lab.xml b/application/shipsimu/templates/game/building/research_lab.xml
new file mode 100644 (file)
index 0000000..091ad0a
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general research laboratory for conducting simple experiments.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<building extends="base_building">
+       <!-- General building data //-->
+       <building-data>
+               <!-- General data, like short name, type, level and many more. //-->
+               <building-data>
+                       <name>research_lab</name>
+                       <type>research</type>
+               </building-data>
+       </building-data>
+       <!-- We also have technology denpencies for a building. These must be
+            understand by construction companies who made contracts with the
+            shipping company to construct this building. //-->
+       <dependencies>
+               <!-- A list of required technology to construct this building. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- Arcgictecture is required. //-->
+                       <technology-dependency>
+                               <technology-name>architecture</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+                       <!-- Labory equipment is required. //-->
+                       <technology-dependency>
+                               <technology-name>laboratory_equipment</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</building>
diff --git a/application/shipsimu/templates/game/chemicals/.htaccess b/application/shipsimu/templates/game/chemicals/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/company/.htaccess b/application/shipsimu/templates/game/company/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/container/.htaccess b/application/shipsimu/templates/game/container/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/container/base_container.xml b/application/shipsimu/templates/game/container/base_container.xml
new file mode 100644 (file)
index 0000000..be79f56
--- /dev/null
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general container template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<container>
+       <!-- Some general data about this container. //-->
+       <container-data>
+               <!-- Id and type of this container. //-->
+               <id>{?id?}</id>
+               <!-- Uni* name, mostly adapted from template name, for this container. //-->
+               <name>{?name?}</name>
+               <!-- Look at container_types.xml for details. //-->
+               <type>{?type?}</type>
+               <!-- Dimension of the container. //-->
+               <dimensions>
+                       <width>{?width?}</width>
+                       <length>{?length?}</length>
+                       <height>{?height?}</height>
+               </dimensions>
+       </container-data>
+       <!-- The owner of the container, this should be a company, //-->
+       <owner>
+               <company id="{?owner_id?}" />
+       </owner>
+       <!-- The sender of the container, this should be a company and must not be
+            the owner. //-->
+       <sender>
+               <company id="{?sender_id?}" />
+       </sender>
+       <!-- The recipient of the container, this should be a company and can be the
+            owner. //-->
+       <recipient>
+               <company id="{?recipient_id?}" />
+       </recipient>
+       <!-- The transported content inside of the container. This can be more than one item. //-->
+       <content-list content-count="{?content_count?}">
+               <!-- A single content of the container which should be transportated. //-->
+               <content>
+                       <content-id>{?content_id?}</content-id>
+                       <content-type>{?content_type?}</content-type>
+                       <content-amount>{?content_amount?}</content-amount>
+               </content>
+       </content-list>
+       <!-- A system, freezer or colder or something else, which maintains a
+            constant temperature. This is useful for biological content like
+            fruits. But it is optional. You can currently specify multiple systems,
+            e.g. ventilation and maybe cooling aggregate or so. //-->
+       <maintenance-system-list maintenance-system-count="{?maintenance_system_count?}">
+               <!-- A single maintenance system. //-->
+               <maintenance-system>
+                       <maintenance-id>{?maintenance_id?}</maintenance-id>
+                       <maintenance-name>{?maintenance_name?}</maintenance-name>
+                       <maintenance-type>{?maintenance_type?}</maintenance-type>
+               </maintenance-system>
+       </maintenance-system-list>
+</container>
diff --git a/application/shipsimu/templates/game/contract/.htaccess b/application/shipsimu/templates/game/contract/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/contract/base_contract.xml b/application/shipsimu/templates/game/contract/base_contract.xml
new file mode 100644 (file)
index 0000000..bb59563
--- /dev/null
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general contract
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<contract>
+       <!-- Parties of a contract are listed here. At least two, of course. //-->
+       <contract-party-list party-count="{?coutract_party_count?}">
+               <!-- All contract parties are enlisted with this tag. //-->
+               <contract-party>
+                       <!-- The signer's data, for signer_type please refer to signer_types.xml //-->
+                       <signer id="{?signer_id?}" type="{?signer_type?}" />
+               </contract-party>
+       </contract-party-list>
+       <!-- General contract data like data of signature or cancelation //-->
+       <contract-data id="{?id?}" type="{?type?}">
+               <!-- When this contract was signed. //-->
+               <signed timestamp="{?signed_timestamp?}" />
+               <!-- And when it was canceled. //-->
+               <canceled timestamp="{?canceled_timestamp?}" />
+               <!-- A short reason for cancelation. //-->
+               <cancelation-reason>
+                       <![CDATA[{?cancelation_reason?}]]>
+               </cancelation-reason>
+               <!-- A free-text description. //-->
+               <description>
+                       <![CDATA[{?description?}]]>
+               </description>
+       </contract-data>
+       <!-- The subject-(matter) of a contract. If this changes, the contract
+            needs to be renewed. //-->
+       <contract-subject>
+               <!-- @TODO We need to make this more XML than free text. //-->
+               <![CDATA[{?subject?}]]>
+       </contract-subject>
+</contract>
diff --git a/application/shipsimu/templates/game/drink/.htaccess b/application/shipsimu/templates/game/drink/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/drink/base_drink.xml b/application/shipsimu/templates/game/drink/base_drink.xml
new file mode 100644 (file)
index 0000000..6ac3a06
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general drink template for juice, mineral water, milk et cetera.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<drink>
+</drink>
diff --git a/application/shipsimu/templates/game/electronic/.htaccess b/application/shipsimu/templates/game/electronic/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/electronic/base_electronic.xml b/application/shipsimu/templates/game/electronic/base_electronic.xml
new file mode 100644 (file)
index 0000000..06945a5
--- /dev/null
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general electronic template. These electronics can be transported by different
+types of transportation companies. Is can be anything from cellphones over other
+communication electronics to commercial computers (default) or medical devices.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic>
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <!-- Id and type for this electronic. //-->
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>{?width?}</width>
+                       <height>{?height?}</height>
+                       <length>{?length?}</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- A list research dependencies for this electronical device. //-->
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <research-dependency>
+                               <research-id>{?research_id?}</research-id>
+                               <research-name>{?research_name?}</research-name>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/electronic/cellphone.xml b/application/shipsimu/templates/game/electronic/cellphone.xml
new file mode 100644 (file)
index 0000000..2c7f2d8
--- /dev/null
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A common cellular phone.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic extends="base_electronic}">
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <!-- Id and type for this electronic. //-->
+               <name>cellphone</name>
+               <type>communication</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>30</width>
+                       <height>35</height>
+                       <length>30</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <name>cellular_network</name>
+                               <level>1</level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- A list research dependencies for this electronical device. //-->
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <research-dependency>
+                               <name>electronics</name>
+                               <level>6</level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/electronic/hifi_system.xml b/application/shipsimu/templates/game/electronic/hifi_system.xml
new file mode 100644 (file)
index 0000000..76a1a8e
--- /dev/null
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A commercial, compact Hi-Fi (High Fidelity) sound system.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic extends="{?base_electronic?}">
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <name>hifi_system</name>
+               <type>entertainment</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>70</width>
+                       <height>70</height>
+                       <length>80</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <technology-dependency>
+                               <name>intergrated_currents</name>
+                               <level>6</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>sound_equalizer</name>
+                               <level>3</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>radio_receiving</name>
+                               <level>4</level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- A list research dependencies for this electronical device. //-->
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <!-- A single research dependency. //-->
+                       <research-dependency>
+                               <name>electronics</name>
+                               <level>4</level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/electronic/radio_receiver.xml b/application/shipsimu/templates/game/electronic/radio_receiver.xml
new file mode 100644 (file)
index 0000000..ce5eb0d
--- /dev/null
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A commercial, simple radio receiver.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic extends="{?base_electronic?}">
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <name>radio_receiver</name>
+               <type>entertainment</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>30</width>
+                       <height>40</height>
+                       <length>20</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <technology-dependency>
+                               <name>intergrated_currents</name>
+                               <level>3</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>radio_receiving</name>
+                               <level>1</level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- A list research dependencies for this electronical device. //-->
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <!-- A single technollogy dependency. //-->
+                       <research-dependency>
+                               <name>electronics</name>
+                               <level>3</level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/electronic/surround_system.xml b/application/shipsimu/templates/game/electronic/surround_system.xml
new file mode 100644 (file)
index 0000000..31651a3
--- /dev/null
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A high-end surround sound system developed e.g. for home-cinema.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic extends="base_electronic">
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <!-- Id and type for this electronic. //-->
+               <name>surround_system</name>
+               <type>entertainment</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>120</width>
+                       <height>140</height>
+                       <length>120</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <technology-dependency>
+                               <name>sound_processor</name>
+                               <level>3</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>sound_equalizer</name>
+                               <level>5</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>radio_receiving</name>
+                               <level>6</level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/electronic/television.xml b/application/shipsimu/templates/game/electronic/television.xml
new file mode 100644 (file)
index 0000000..44da2f1
--- /dev/null
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A regular, commercial television.
+
+For simplification we have only width, length, height and total weight. This is
+in reality mostly the case because the electronics will be placed into a small
+box for transportation.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic extends="base_electronic">
+       <!-- General data of the electronics. //-->
+       <electronic-data>
+               <!-- Id and type for this electronic. //-->
+               <name>television</name>
+               <type>entertainment</type>
+               <!-- Simplified dimensions of the electronics because it will be placed
+                    into a small box for transportation. //-->
+               <dimensions>
+                       <width>100</width>
+                       <height>110</height>
+                       <length>90</length>
+               </dimensions>
+       </electronic-data>
+       <!-- An electronical device may depend on one or more technologies, at least
+            'electronics'. //-->
+       <dependencies>
+               <!-- A list technology dependencies for this electronical device. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technollogical dependency. //-->
+                       <technology-dependency>
+                               <name>video_receiving</name>
+                               <level>1</level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <name>transistor</name>
+                               <level>1</level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</electronic>
diff --git a/application/shipsimu/templates/game/engine/.htaccess b/application/shipsimu/templates/game/engine/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/engine/base_engine.xml b/application/shipsimu/templates/game/engine/base_engine.xml
new file mode 100644 (file)
index 0000000..675d90f
--- /dev/null
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general engine template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<engine>
+       <!-- General data about this engine. //-->
+       <engine-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <horse-power>{?horse_power?}</horse-power>
+       </engine-data>
+       <!-- Type of fuel we need. May be left out if this "engine" is e.g. a sail. //-->
+       <fuel>
+               <fuel-id>{?fuel_id?}</fuel-id>
+               <fuel-name>{?fuel_name?}</fuel-name>
+               <fuel-type>{?fuel_type?}</fuel-type>
+       </fuel>
+       <!-- Simplified dimensions of this engine. Can be left out for sails. //-->
+       <dimensions>
+               <width>{?width?}</width>
+               <height>{?height?}</height>
+               <length>{?length?}</length>
+       </dimensions>
+       <!-- Some engine require knowledge in specific technologies. //-->
+       <depenndencies>
+               <!-- A list of required technology to build this engine. A better level
+                    may increase the horse power of this engine. Some ships require
+                    higher horse power or else it won't move. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A single technology dependency. //-->
+                       <technology-dependency>
+                               <technology-id>{[?technology_id?}</technology-id>
+                               <technology-name>{[?technology_name?}</technology-name>
+                               <technology-level>{[?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </depenndencies>
+</engine>
diff --git a/application/shipsimu/templates/game/farmer/.htaccess b/application/shipsimu/templates/game/farmer/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/farmer/base_farmer.xml b/application/shipsimu/templates/game/farmer/base_farmer.xml
new file mode 100644 (file)
index 0000000..6542df2
--- /dev/null
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general farmer template
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<farmer>
+       <!-- General data about this farmer, like name (not the player's nickname)
+            type, birthday. //-->
+       <farmer-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <!-- The productivity may depend on the age of the farmer. //-->
+               <birthday>
+                       <month>{?month?}</month>
+                       <day>{?day?}</day>
+                       <year>{?year?}</year>
+               </birthday>
+               <!-- Productivity, experience and others. //-->
+               <productivity>{?productivity?}</productivity>
+               <experience>{?experience?}</experience>
+       </farmer-data>
+       <!-- List of all products this farmer is producing. //-->
+       <produce-list produce-count="{?produce_count?}">
+               <!-- A single produce this farmer is producing. //-->
+               <produce>
+                       <produce-id>{?produce_id?}</produce-id>
+                       <produce-name>{?produce_name?}</produce-name>
+                       <produce-type>{?produce_type?}</produce-type>
+                       <!-- A list of technology dependency required to create this
+                            produce. //-->
+                       <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                               <!-- A single technology dependency. //-->
+                               <technology-dependency>
+                                       <technology-id>{?technology_id?}</technology-id>
+                                       <technology-name>{?technology_name?}</technology-name>
+                                       <technology-level>{?technology_level?}</technology-level>
+                               </technology-dependency>
+                       </technology-dependency-list>
+               </produce>
+       </produce-list>
+</farmer>
diff --git a/application/shipsimu/templates/game/fruit/.htaccess b/application/shipsimu/templates/game/fruit/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/fruit/base_fruit.xml b/application/shipsimu/templates/game/fruit/base_fruit.xml
new file mode 100644 (file)
index 0000000..482faad
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general fruit template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<fruit extends="base_produce">
+</fruit>
diff --git a/application/shipsimu/templates/game/fuel/.htaccess b/application/shipsimu/templates/game/fuel/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/fuel/base_fuel.xml b/application/shipsimu/templates/game/fuel/base_fuel.xml
new file mode 100644 (file)
index 0000000..0f023fb
--- /dev/null
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general fuel template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<fuel>
+       <fuel-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+       </fuel-data>
+</fuel>
diff --git a/application/shipsimu/templates/game/grain/.htaccess b/application/shipsimu/templates/game/grain/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/grain/base_grain.xml b/application/shipsimu/templates/game/grain/base_grain.xml
new file mode 100644 (file)
index 0000000..eac45e4
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general grain template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<grain>
+</grain>
diff --git a/application/shipsimu/templates/game/lifestock/.htaccess b/application/shipsimu/templates/game/lifestock/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/lifestock/base_lifestock.xml b/application/shipsimu/templates/game/lifestock/base_lifestock.xml
new file mode 100644 (file)
index 0000000..267077b
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general lifestock template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<lifestock>
+</lifestock>
diff --git a/application/shipsimu/templates/game/merchant/.htaccess b/application/shipsimu/templates/game/merchant/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/merchant/base_merchant.xml b/application/shipsimu/templates/game/merchant/base_merchant.xml
new file mode 100644 (file)
index 0000000..22d4c78
--- /dev/null
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general merchant template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<merchant>
+       <!-- General data about this merchant like id, type, summary or description. //-->
+       <merchant-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?</type>
+               <!-- A summary what this merchant is trading. //-->
+               <summary>
+                       <![CDATA[{?summary?}]]>
+               </summary>
+               <!-- A full description about this merchant. //-->
+               <description>
+                       <![CDATA[{?description?}]]>
+               </description>
+       </merchant-data>
+       <!-- The owner of this merchant. If left out the AI of the game will play
+            this merchant. //-->
+       <owner>
+               <company id="{?owner_id?}" />
+       </owner>
+       <!-- A detailed trading list of goods this merchant is trading. Amount, when
+            the first item was added or the last one was removed are being stored
+            with every goods. //-->
+       <goods-list goods-count="{?goods_count?}">
+               <!-- A single goods this merchant is trading. //-->
+               <goods>
+                       <goods-id>{?goods_id?}</goods-id>
+                       <goods-name>{?goods_name?}</goods-name>
+                       <goods-type>{?goods_type?}</goods-type>
+                       <goods-amount>{?goods_amount?}</goods-amount>
+                       <goods-first-added>{?goods_added?}</goods-first-added>
+                       <goods-last-removed>{?goods_remoed?}</goods-last-removed>
+               </goods>
+       </goods-list>
+</merchant>
diff --git a/application/shipsimu/templates/game/mineral/.htaccess b/application/shipsimu/templates/game/mineral/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/mineral/base_mineral.xml b/application/shipsimu/templates/game/mineral/base_mineral.xml
new file mode 100644 (file)
index 0000000..64847ff
--- /dev/null
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general mineral template. Some mineral requires technology in a specific
+level to get mined by the user. For example crystals needs drilling machines
+and undergroup drilling vehicles. These are all represented as 'technologies' so
+a mineral may have dependencies on technologies. :-)
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<mineral>
+       <!-- General data for this mineral like id, type, summary or description. //-->
+       <mineral-data>
+               <id>{?id?}</id>
+               <type>{?type?}</type>
+               <!-- A summary for this mineral. //-->
+               <mineral-summary>
+                       <![CDATA[{?summary?}]]>
+               </mineral-summary>
+               <!-- A full description for this mineral. //-->
+               <mineral-description>
+                       <![CDATA[{?description?}]]>
+               </mineral-description>
+       </mineral-data>
+       <!-- To mine some minerals some knowledge in one or two technologies is
+            required. Here you can list each technology with its required level. //-->
+       <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+               <!-- A single technology required to mine this mineral. //-->
+               <technology-dependency id="{?technology_id?}" level="{?technology_level?}" />
+       </technology-dependency-list>
+</mineral>
diff --git a/application/shipsimu/templates/game/produce/.htaccess b/application/shipsimu/templates/game/produce/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/produce/base_produce.xml b/application/shipsimu/templates/game/produce/base_produce.xml
new file mode 100644 (file)
index 0000000..29ca874
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general produce template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<produce>
+</produce>
diff --git a/application/shipsimu/templates/game/research/.htaccess b/application/shipsimu/templates/game/research/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/research/base_research.xml b/application/shipsimu/templates/game/research/base_research.xml
new file mode 100644 (file)
index 0000000..3c4d185
--- /dev/null
@@ -0,0 +1,133 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+This is a general research proposal template. A research is the theoretical
+requirement to gain a specific technology or to be able to construct special
+buildings, ships et cetera. A research may not be gainable but conductable e.g.
+in a research lab.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal>
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <max-level>{?max_level?}</max-level>
+               <!-- All researches end up with results which can be improvements to
+                    to existing technology or how research is conducted. Some research
+                    may have multiple results and they all might not be good. //-->
+               <research-result-list research-result-count="{?research_result_count?}">
+                       <!-- A single research result. //-->
+                       <research-result>
+                               <!-- A list of modified technology when this research is completed. //-->
+                               <modify-technology-list modify-technology-count="{?modify_technology_count?}">
+                                       <!-- A single technology modification. //-->
+                                       <modify-technology id="{?modify_technology_id?}" amount="{?modify_technology_amount?}" />
+                               </modify-technology-list>
+                       </research-result>
+               </research-result-list>
+               <!-- A summary for this research proposal. //-->
+               <research-summary>
+                       <![CDATA[{?summary?}]]>
+               </research-summary>
+               <!-- A full description for this research proposal. //-->
+               <research-description>
+                       <![CDATA[{?description?}]]>
+               </research-description>
+       </research-data>
+       <!-- This is somewhat a "research history". //-->
+       <research-level-list research-level-count="{?research_level_count?}">
+               <!-- A research level X has its own summary and a full description.
+                    It also can have dependencies which makes it possible to add different
+                    dependencies for higher research levels. //-->
+               <research-level>
+                       <level>{?level?}</level>
+                       <!-- When the research of this level has been started ... //-->
+                       <research-started timestamp="{?started?}" />
+                       <!-- ... and when it has ended so when the research results are
+                            available. //-->
+                       <research-finished timestamp="{?finished?}" />
+                       <!-- A summary for this research level. //-->
+                       <level-summary>
+                               <![CDATA[{?level_summary?}]]>
+                       </level-summary>
+                       <!-- A full description for this research level. //-->
+                       <level-description>
+                               <![CDATA[{?level_description?}]]>
+                       </level-description>
+                       <!-- A research level may depend on none, some or all of these
+                            'dependency types'. We are doing this this way to keep this XML
+                            simple but still flexible enougth to fit all proposal needs. //-->
+                       <level-dependencies>
+                               <level-technology-dependency-list level-technology-dependency-count="{?level_technology_dependency_count?}">
+                                       <level-technology-dependency>
+                                               <level-technology-id>{?level_technology_id?}</level-technology-id>
+                                               <level-technology-name>{?level_technology_name?}</level-technology-name>
+                                               <level-technology-type>{?level_technology_type?}</level-technology-type>
+                                               <level-technology-level>{?level_technology_level?}</level-technology-level>
+                                       </level-technology-dependency>
+                               </level-technology-dependency-list>
+                               <level-research-dependency-list level-research-dependency-count="{?level_research_dependency_count?}">
+                                       <level-research-dependency>
+                                               <level-research-id>{?level_research_id?}</level-research-id>
+                                               <level-research-name>{?level_research_name?}</level-research-name>
+                                               <level-research-type>{?level_research_type?}</level-research-type>
+                                               <level-research-level>{?level_research_level?}</level-research-level>
+                                       </level-research-dependency>
+                               </level-research-dependency-list>
+                               <level-building-dependency-list level-building-dependency-count="{?level_building_dependency_count?}">
+                                       <level-building-dependency>
+                                               <level-building-id>{?level_building_id?}</level-building-id>
+                                               <level-building-name>{?level_building_name?}</level-building-name>
+                                               <level-building-type>{?level_building_type?}</level-building-type>
+                                               <level-building-level>{?level_building_level?}</level-building-level>
+                                       </level-building-dependency>
+                               </level-building-dependency-list>
+                       </level-dependencies>
+               </research-level>
+       </research-level-list>
+       <dependencies>
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <research-dependency>
+                               <research-id>{?research_id?}</research-id>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+               <building-dependency-list building-dependency-count="{?building_dependency_count?}">
+                       <building-dependency>
+                               <building-id>{?building_id?}</building-id>
+                               <building-name>{?building_name?}</building-name>
+                               <building-type>{?building_type?}</building-type>
+                               <building-level>{?building_level?}</building-level>
+                       </building-dependency>
+               </building-dependency-list>
+       </dependencies>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/research/electricity.xml b/application/shipsimu/templates/game/research/electricity.xml
new file mode 100644 (file)
index 0000000..c6b3480
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A electricity research proposal template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal extends="base_research">
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <name>electricity</name>
+               <type>electronics</type>
+               <max-level>10</max-level>
+       </research-data>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/research/electronics.xml b/application/shipsimu/templates/game/research/electronics.xml
new file mode 100644 (file)
index 0000000..c2a1f6e
--- /dev/null
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A electronics research proposal template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal extends="base_research">
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <name>electronics</name>
+               <type>electronics</type>
+               <max-level>20</max-level>
+       </research-data>
+       <dependencies>
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-name>plastics</technology-name>
+                               <technology-type>chemicals</technology-type>
+                               <technology-level>2</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <research-dependency>
+                               <research-name>electricity</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>4</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/research/mathematics.xml b/application/shipsimu/templates/game/research/mathematics.xml
new file mode 100644 (file)
index 0000000..843c44e
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+Mathematics research purpose
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal>
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <name>mathematics</name>
+               <type>base</type>
+               <max-level>10</max-level>
+       </research-data>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/research/radio_receiving.xml b/application/shipsimu/templates/game/research/radio_receiving.xml
new file mode 100644 (file)
index 0000000..3428478
--- /dev/null
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A radio-receiving research proposal template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal extends="base_research">
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <name>radio_receiving</name>
+               <type>electronics</type>
+               <max-level>10</max-level>
+       </research-data>
+       <dependencies>
+               <!-- All research proposal dependencies for this research proposal. //-->
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <!-- A research proposal dependency for this research proposal. //-->
+                       <technology-dependency>
+                               <technology-name>signal_modulation</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/research/statics.xml b/application/shipsimu/templates/game/research/statics.xml
new file mode 100644 (file)
index 0000000..302412e
--- /dev/null
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+Statistics research purpose
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<research-proposal>
+       <!-- General data of this research like id, summar or description. //-->
+       <research-data>
+               <name>statics</name>
+               <type>construction</type>
+               <max-level>20</max-level>
+       </research-data>
+       <dependencies>
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <research-dependency-list dependency-count="{?research_dependency_count?}">
+                       <research-dependency>
+                               <technology-name>mathematics</technology-name>
+                               <technology-type>{?research_type?}</technology-type>
+                               <technology-level>4</technology-level>
+                       </research-dependency>
+               </research-dependency-list>
+               <building-dependency-list dependency-count="{?building_dependency_count?}">
+                       <building-dependency>
+                               <building-name>{?building_name?}</building-name>
+                               <building-type>{?building_type?}</building-type>
+                               <building-level>{?building_level?}</building-level>
+                       </building-dependency>
+               </building-dependency-list>
+       </dependencies>
+</research-proposal>
diff --git a/application/shipsimu/templates/game/resource/.htaccess b/application/shipsimu/templates/game/resource/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/resource/base_resource.xml b/application/shipsimu/templates/game/resource/base_resource.xml
new file mode 100644 (file)
index 0000000..8860210
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general resource template. Resources need to be harvested and them
+transportaed to facilities which can process them. To harvest some resources
+the player may need knowledge in some technology.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<resource>
+       <!-- General data for this resource like id, type, summary or description. //-->
+       <resource-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <!-- A summary for this resource. //-->
+               <resource-summary>
+                       <![CDATA[{?summary?}]]>
+               </resource-summary>
+               <!-- A full description for this resource. //-->
+               <resource-description>
+                       <![CDATA[{?description?}]]>
+               </resource-description>
+       </resource-data>
+       <!-- To harvest some resource some knowledge in one or two technologies is
+            required. Here you can list each technology with its required level. //-->
+       <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+               <!-- A single technology dependency to harvest this resource. //-->
+               <technology-dependency>
+                       <technology-id>{?technology_id?}</technology-id>
+                       <technology-name>{?technology_name?}</technology-name>
+                       <technology-type>{?technology_type?}</technology-type>
+                       <technology-level>{?technology_level?}</technology-level>
+               </technology-dependency>
+       </technology-dependency-list>
+</resource>
diff --git a/application/shipsimu/templates/game/ship/.htaccess b/application/shipsimu/templates/game/ship/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/ship/base_ship.xml b/application/shipsimu/templates/game/ship/base_ship.xml
new file mode 100644 (file)
index 0000000..a33efe8
--- /dev/null
@@ -0,0 +1,134 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general ship template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<ship>
+       <!-- Some general data about this ship. Some may not be required for the
+            simulation at the moment. //-->
+       <ship-data>
+               <id>{?id?}</id>
+               <name><![CDATA[{?name?}]]></name>
+               <type>{?type?}</type>
+               <ship-propeller>{?propeller?}</ship-propeller>
+               <total-weight>{?weight?}</total-weight>
+               <total-displacement>{?displacement?}</total-displacement>
+               <!-- Some data about the construction phase, like company, contract. //-->
+               <construction>
+                       <!-- The construction company of this ship. //-->
+                       <construction-company>{?construction_id?}</construction-company>
+                       <!-- The signed construction contract for this ship. //-->
+                       <construction-contract>{?construction_contract_id?}</construction-contract>
+                       <!-- When the construction has started. //-->
+                       <construction-started>{?construction_started?}</construction-started>
+                       <!-- And when the ship was constructed. //-->
+                       <construction-finished>{?construction_finished?</construction-finished>
+               </construction>
+       </ship-data>
+       <!-- A list of shipping companies who owned this ship. //-->
+       <shipping-company-list>
+               <!-- A single company who owned this ship for a tme span. //-->
+               <shipping-company>
+                       <company-id>{?company_id?}</company-id>
+                       <!-- A time span when the company owned this ship. //-->
+                       <holder-timespan>
+                               <started>{?holder_started?}</started>
+                               <ended>{?holder_ended?}</ended>
+                       </hoolder-timespan>
+                       <!-- A contract signed for changing ownership. //-->
+                       <contract id="{?contract_id?}" />
+               </shipping-company>
+       </shipping-company-list>
+       <!-- A list of structures to build this ship. If you need more than of a
+            structure type just specify the neccessary amount. //-->
+       <ship-structure-list>
+               <!-- A single ship structure. This can be anything from the wheel house
+                    to theatre or little ships, decks and cabins. //-->
+               <ship-structure extends="{?structure_template?}">
+                       <structure-id>{?structure_id?}</structure-id>
+                       <structure-amount>{?structure_amount?}</structure-amount>
+                       <structure-type>{?structure_type?}</structure-type>
+               </ship-structure>
+       </ship-structure-list>
+       <!-- All ships require an engine, even when or 'engine' is a sail, to move
+            around. //-->
+       <engine extends="{?engine_template?}">
+               <engine-id>{?engine_id?{</engine-id>
+               <engine-type>{?engine_type?}</engine-type>
+       </engine>
+       <!-- A list of what this ship transportates. //-->
+       <transportation-list>
+               <!-- @TODO This section is not complete. //-->
+       </transportation-list>
+       <!-- A ship may require one or more of these system to operate. //-->
+       <ship-systems>
+               <!-- The electric system of latest ships has becom the most important
+                    on a ship. It powers all other systems and provides electrical
+                    power to all kind of commercials and cabins including interior and
+                    exterior lights. So you should be adviced to provide emergency
+                    systems and redudancy for this system. //-->
+               <electric-system>
+                       <!-- @TODO This section is not complete. //-->
+               </electric-system>
+               <!-- On latest ships you require to have a hydric system to operate
+                    heavy bulkheads which seperates sections on low-level decks. On
+                    passenger ships the hydraulic system have to operate front and/or
+                    rear doors to let drive vehicles in. //-->
+               <hydraulic-system>
+                       <!-- @TODO This section is not complete. //-->
+               </hydraulic-system>
+               <!-- Nearly all ships will have a navigation system. //-->
+               <navigation-system>
+                       <!-- @TODO This section is not complete. //-->
+               </navigation-system>
+               <!-- A guidance system which every ship should have... //-->
+               <guidance-system>
+                       <!-- @TODO This section is not complete. //-->
+               </guidance-system>
+               <!-- A fire reporting and fighting system. //-->
+               <fire-system>
+                       <!-- @TODO This section is not complete. //-->
+               </fire-system>
+       </ship-systems>
+       <!-- Ships depend on several technologies and maybe research proposals. //-->
+       <dependencies>
+               <!-- A list of technology dependencies for this ship. //-->
+               <technology-dependency-list>
+                       <!-- A single technology dependencies for this ship. //-->
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- A list of research proposals dependencies for this ship. //-->
+               <research-dependency-list>
+                       <!-- A single research proposals  dependencies for this ship. //-->
+                       <research-dependency>
+                               <research-id>{?research_id?}</research-id>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</ship>
diff --git a/application/shipsimu/templates/game/tank/.htaccess b/application/shipsimu/templates/game/tank/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/tank/base_tank.xml b/application/shipsimu/templates/game/tank/base_tank.xml
new file mode 100644 (file)
index 0000000..c943576
--- /dev/null
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general tank template for different types of fuel.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<tank>
+       <tank-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+       </tank-data>
+       <content>
+               <content-id>{?content_id?}</content-id>
+               <content-name>{?content_name?}</content-name>
+               <content-type>{?content_type?}</content-type>
+       </content>
+       <dependencies>
+               <technology-dependency-list dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</tank>
diff --git a/application/shipsimu/templates/game/technology/.htaccess b/application/shipsimu/templates/game/technology/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/technology/architecture.xml b/application/shipsimu/templates/game/technology/architecture.xml
new file mode 100644 (file)
index 0000000..6547cc5
--- /dev/null
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A architecture technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>architecture</name>
+               <type>construction</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <!-- @TODO Find a technology type //-->
+                               <technology-name>drawings</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <!-- @TODO Find research types //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <research-dependency>
+                               <research-name>statics</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>3</research-level>
+                       </research-dependency>
+                       <research-dependency>
+                               <research-name>mathematics</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>6</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/base_technology.xml b/application/shipsimu/templates/game/technology/base_technology.xml
new file mode 100644 (file)
index 0000000..846a215
--- /dev/null
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology>
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <id>{?id?}</id>
+               <name>{?name?}</name>
+               <type>{?type?}</type>
+               <!-- The date/time when this technology was gained, e.g. by research. //-->
+               <technology-gained timestamp="{?gained?}" />
+               <!-- A summary of this technology. //-->
+               <technology-summary>
+                       <![CDATA[{?summary?}]]>
+               </technology-summary>
+               <!-- A full description of this technology. //-->
+               <technology-description>
+                       <![CDATA[{?description?}]]>
+               </technology-description>
+       </technology-data>
+       <!-- All levels of this technology are held in this tag. //-->
+       <technology-level-list>
+               <!-- A single technology level with its basic data, own summary and
+                    description. //-->
+               <technology-level>
+                       <level>{?list_level?}</level>
+                       <gained>{?level_gained?}</gained>
+                       <!-- A summary of this technology level. //-->
+                       <technology-level-summary>
+                               <![CDATA[{?level_summary?}]]>
+                       </technology-level-summary>
+                       <!--  A full description of this technology level. //-->
+                       <technology-level-description>
+                               <![CDATA[{?level_description?}]]>
+                       </technology-level-description>
+                       <!-- A specific technology level may depend on some further technologies or research
+                            proposals. //-->
+                       <level-dependencies>
+                               <!-- All technology dependencies for this technology. //-->
+                               <technology-level-dependency-list>
+                                       <!-- A technology dependency for this technology. //-->
+                                       <technology-level-dependency>
+                                               <technology-level-id>{?technology_level_id?}</technology-level-id>
+                                               <technology-level-name>{?technology_level_name?}</technology-level-name>
+                                               <technology-level-level>{?technology_level_level?}</technology-level-level>
+                                       </technology-level-dependency>
+                               </technology-level-dependency-list>
+                               <!-- All research dependencies for this technology. //-->
+                               <research-level-dependency-list>
+                                       <!-- A research dependency for this technology. //-->
+                                       <research-level-dependency>
+                                               <research-level-id>{?research_level_id?}</research-level-id>
+                                               <research-level-name>{?research_level_name?}</research-level-name>
+                                               <research-level-level>{?research_level_level?}</research-level-level>
+                                       </research-level-dependency>
+                               </research-dependency-list>
+                       </level-dependencies>
+               </technology-level>
+       </technology-level-list>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list>
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-id>{?technology_id?}</technology-id>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list>
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-id>{?research_id?}</research-id>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/cellular_network.xml b/application/shipsimu/templates/game/technology/cellular_network.xml
new file mode 100644 (file)
index 0000000..77f4a82
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A cellular network technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>cellular_network</name>
+               <type>communication</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- @TODO Find some technology dependencies. //-->
+                       <technology-dependency>
+                               <technology-name></technology-name>
+                               <technology-type></technology-type>
+                               <technology-level></technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <!-- @TODO Find a research type //-->
+                       <research-dependency>
+                               <technology-name>electronics</technology-name>
+                               <technology-type>{?research_type?}</technology-type>
+                               <technology-level>5</technology-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/drawings.xml b/application/shipsimu/templates/game/technology/drawings.xml
new file mode 100644 (file)
index 0000000..43dbf50
--- /dev/null
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A drawings technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>drawings</name>
+               <type>base</type>
+       </technology-data>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/glass_making.xml b/application/shipsimu/templates/game/technology/glass_making.xml
new file mode 100644 (file)
index 0000000..7679857
--- /dev/null
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A glass-making technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>glass_making</name>
+               <type>production</type>
+       </technology-data>
+       <!-- All levels of this technology are held in this tag. //-->
+       <technology-level-list technology-level-count="{?technology_level_count?}">
+               <!-- A single technology level with its basic data, own summary and
+                    description. //-->
+               <technology-level>
+                       <level>{?list_level?}</level>
+                       <!-- A specific technology level may depend on some further technologies or research
+                            proposals. //-->
+                       <level-dependencies>
+                               <!-- All technology dependencies for this technology. //-->
+                               <technology-level-dependency-list>
+                                       <!-- A technology dependency for this technology. //-->
+                                       <technology-level-dependency>
+                                               <technology-name>{?technology_level_name?}</technology-name>
+                                               <technology-type>{?technology_level_type?}</technology-type>
+                                               <technology-level>{?technology_level_level?}</technology-level>
+                                       </technology-level-dependency>
+                               </technology-level-dependency-list technology-level-dependency-count="{?technology_level_dependency_count?}">
+                               <!-- All research dependencies for this technology. //-->
+                               <research-level-dependency-list research-level-dependency-count="{?research_level_dependency_count?}">
+                                       <!-- A research dependency for this technology. //-->
+                                       <research-level-dependency>
+                                               <research-name>{?research_level_name?}</research-name>
+                                               <research-type>{?research_level_type?}</research-type>
+                                               <research-level>{?research_level_level?}</research-level>
+                                       </research-level-dependency>
+                               </research-dependency-list>
+                       </level-dependencies>
+               </technology-level>
+       </technology-level-list>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>{?technology_level?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/household_devices.xml b/application/shipsimu/templates/game/technology/household_devices.xml
new file mode 100644 (file)
index 0000000..e19e14f
--- /dev/null
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A generic household device template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>household_devices</name>
+               <type>electronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-name>plastics</technology-name>
+                               <technology-type>chemicals</technology-type>
+                               <technology-level>3</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research proposal dependencies for this research. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- @TODO Find a research type //-->
+                       <research-dependency>
+                               <research-name>electronics</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>1</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/intergrated_currents.xml b/application/shipsimu/templates/game/technology/intergrated_currents.xml
new file mode 100644 (file)
index 0000000..bdfebce
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A intergrated-current (IC) technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>intergrated_currents</name>
+               <type>eletronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>transistor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>10</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>silicium_mining</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>1</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/laboratory_equipment.xml b/application/shipsimu/templates/game/technology/laboratory_equipment.xml
new file mode 100644 (file)
index 0000000..1b40430
--- /dev/null
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A laboratory-equipment technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>laboratory_equipment</name>
+               <type>equipment</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals. //-->
+       <dependencies>
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-name>plastics</technology-name>
+                               <technology-type>chemicals</technology-type>
+                               <technology-level>3</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>glass_making</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/naval_architecture.xml b/application/shipsimu/templates/game/technology/naval_architecture.xml
new file mode 100644 (file)
index 0000000..5a00d72
--- /dev/null
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A naval architecture technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="architecture">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>naval_architecture</name>
+               <type>ship_construction</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <technology-dependency>
+                               <technology-name>architecture</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>3</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>statics</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>drawings</technology-name>
+                               <technology-type>{?technology_type?}</technology-type>
+                               <technology-level>6</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <research-dependency>
+                               <research-name>mathematics</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>8</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/plastics.xml b/application/shipsimu/templates/game/technology/plastics.xml
new file mode 100644 (file)
index 0000000..94f2720
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A plastics technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>plastics</name>
+               <type>production</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <!-- @TODO Find a chemical name and level for this technology. //-->
+                               <technology-name>{?technology_name?}</technology-name>
+                               <technology-type>chemicals</technology-type>
+                               <technology-level>{?technology_name?}</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>chemistry</research-name>
+                               <research-type>chemicals</research-type>
+                               <research-level>3</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/signal_amplifying.xml b/application/shipsimu/templates/game/technology/signal_amplifying.xml
new file mode 100644 (file)
index 0000000..5cc9e01
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A signal amplifying technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>signal_amplifying</name>
+               <type>electronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>transistor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>3</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>modulation</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>1</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/signal_modulation.xml b/application/shipsimu/templates/game/technology/signal_modulation.xml
new file mode 100644 (file)
index 0000000..186a569
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A signal modulation technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>signal_modulation</name>
+               <type>electronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>transistor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>3</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>modulation</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>1</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/sound_equalizer.xml b/application/shipsimu/templates/game/technology/sound_equalizer.xml
new file mode 100644 (file)
index 0000000..8d10f58
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A sound-processing technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>sound_equalizer</name>
+               <type>electronic</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>transistor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <!-- @TODO Should we find some theory behind equalizing? //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/sound_processor.xml b/application/shipsimu/templates/game/technology/sound_processor.xml
new file mode 100644 (file)
index 0000000..d223b4f
--- /dev/null
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A sound-processing technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>sound_processor</name>
+               <type>electronic</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>intergrated_current</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>7</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>surround_mixing</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <!-- @TODO Should we find some theory behind processing? //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/surround_mixing.xml b/application/shipsimu/templates/game/technology/surround_mixing.xml
new file mode 100644 (file)
index 0000000..9c674de
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A sound-processing technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>surround_mixing</name>
+               <type>electronic</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>intergrated_current</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>6</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <!-- @TODO Should we find some theory behind surround mixer? //-->
+               <research-dependency-list research-dependency-count="{?research-dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <research-dependency>
+                               <research-name>{?research_name?}</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>{?research_level?}</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/transistor.xml b/application/shipsimu/templates/game/technology/transistor.xml
new file mode 100644 (file)
index 0000000..f41d448
--- /dev/null
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A transistor technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>transistor</name>
+               <type>eletronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>semiconductor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>plastics</technology-name>
+                               <technology-type>chemicals</technology-type>
+                               <technology-level>5</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+               <!-- All research dependencies for this technology. //-->
+               <research-dependency-list research-dependency-count="{?research_dependency_count?}">
+                       <!-- A research dependency for this technology. //-->
+                       <!-- @TODO Find a research type //-->
+                       <research-dependency>
+                               <research-name>silicium_mining</research-name>
+                               <research-type>{?research_type?}</research-type>
+                               <research-level>1</research-level>
+                       </research-dependency>
+               </research-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/technology/video_receiving.xml b/application/shipsimu/templates/game/technology/video_receiving.xml
new file mode 100644 (file)
index 0000000..353d40a
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A transistor technology template.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<technology extends="base_technology">
+       <!-- General technology data like type, level, summary or description. //-->
+       <technology-data>
+               <name>video_receiving</name>
+               <type>eletronics</type>
+       </technology-data>
+       <!-- A technology may depend on some other technologies or research
+            proposals to gain the first level of this technology. //-->
+       <dependencies>
+               <!-- All technology dependencies for this technology. //-->
+               <technology-dependency-list technology-dependency-count="{?technology_dependency_count?}">
+                       <!-- A technology dependency for this technology. //-->
+                       <technology-dependency>
+                               <technology-name>signal_amplifying</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>signal_modulation</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+                       <technology-dependency>
+                               <technology-name>transistor</technology-name>
+                               <technology-type>electronics</technology-type>
+                               <technology-level>1</technology-level>
+                       </technology-dependency>
+               </technology-dependency-list>
+       </dependencies>
+</technology>
diff --git a/application/shipsimu/templates/game/types/.htaccess b/application/shipsimu/templates/game/types/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/types/building_types.xml b/application/shipsimu/templates/game/types/building_types.xml
new file mode 100644 (file)
index 0000000..58da39a
--- /dev/null
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid types of buildings.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<building-type-list building-type-count="{?building_type_count?}">
+       <!-- Research buildings. //-->
+       <building type type="research" />
+</building-type-list>
diff --git a/application/shipsimu/templates/game/types/container_types.xml b/application/shipsimu/templates/game/types/container_types.xml
new file mode 100644 (file)
index 0000000..46a0c35
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid container types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<container-type-list container-type-count="{?container_type_count?}">
+       <!-- A large cargo container made of steel, a very usual one which can be
+            used to transport very lots of things like entertainment electronics
+            and many more. //-->
+       <container-type type="large_cargo" />
+       <!-- The smaller brother of the above large container. This container is
+            usually half size of the large one. So two of them can be placed where
+            one large container fits... //-->
+       <container-type type="medium_cargo" />
+       <!-- @TODO Add more containers. //-->
+</container-type-list>
diff --git a/application/shipsimu/templates/game/types/content_types.xml b/application/shipsimu/templates/game/types/content_types.xml
new file mode 100644 (file)
index 0000000..f2853a6
--- /dev/null
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid content types, e.g. to be placed in container.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<content-type-list content-type-count="{?content_type_count?}">
+       <!-- All types of resources can be transportated. //-->
+       <content-type type="resource" />
+       <!-- All types of minerals can be transportated. //-->
+       <content-type type="mineral" />
+       <!-- All types of electronics can be transportated e.g. entertainment or communication electronics. //-->
+       <content-type type="electronic" />
+       <!-- @TODO Add more container content types. //-->
+</content-type-list>
diff --git a/application/shipsimu/templates/game/types/contract_types.xml b/application/shipsimu/templates/game/types/contract_types.xml
new file mode 100644 (file)
index 0000000..1e1ce09
--- /dev/null
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid contract types.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<contract-type-list contract-type-count="{?contract-type_count?}">
+       <!-- A construction contract, possible signers: Construction company, customer, creditor //-->
+       <contract-type type="construction_contract" max-signers="3">
+               <!-- All valid signer types for this contract //-->
+               <signer-type-list extends="signer_types" signer-type-count="{?signer_type_count?}">
+                       <signer-type type="player" slot="all" max="3" />
+                       <signer-type type="moneybank" slot="creditor" max="1" />
+                       <signer-type type="construction_company" slot="construction_company" max="1" />
+               </signer-type-list>
+               <!-- And the corresponding slot types //-->
+               <slots>
+                       <slot type="construction_company" must-have="true" />
+                       <slot type="customer" must-have="true" />
+                       <slot type="creditor" must-have="false" />
+               </slots>
+       </contract-type>
+       <!-- @TODO Add more contract types. //-->
+</contract-type-list>
diff --git a/application/shipsimu/templates/game/types/electronic_types.xml b/application/shipsimu/templates/game/types/electronic_types.xml
new file mode 100644 (file)
index 0000000..a5248dd
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid types of electronics. This can be cellphones, computers, hifi systems
+and many many more.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<electronic-type-list electronic-type-count="{?electronic_type_count?}">
+       <!-- All common communication devices. //-->
+       <electronic-type type="communication" />
+       <!-- All commercial systems for entertainment. //-->
+       <electronic-type type="entertainment" />
+       <!-- @TODO Add more types. //-->
+</electronic-type-list>
diff --git a/application/shipsimu/templates/game/types/engine_types.xml b/application/shipsimu/templates/game/types/engine_types.xml
new file mode 100644 (file)
index 0000000..ea42838
--- /dev/null
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid engine types.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<enngine-type-list engine-type-count="{?engine_type_count?}">
+       <!-- Modern ships has a motorized (steam, oil or diesel) engine. //-->
+       <engine-type type="motor" />
+</enngine-type-list>
diff --git a/application/shipsimu/templates/game/types/farmer_types.xml b/application/shipsimu/templates/game/types/farmer_types.xml
new file mode 100644 (file)
index 0000000..a11f5cc
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid farmer types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<farmer-type-list farmer-type-count="{?farmer_type_count?}">
+</farmer-type-list>
diff --git a/application/shipsimu/templates/game/types/fuel_types.xml b/application/shipsimu/templates/game/types/fuel_types.xml
new file mode 100644 (file)
index 0000000..00399a4
--- /dev/null
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid fuel types.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<fuel-type-list fuel-type-count="{?fuel_type_count?}">
+       <!-- Fosil fuels can be oil, cerosine or diesel. //-->
+       <fuel-type type="fosil" />
+</fuel-type-list>
diff --git a/application/shipsimu/templates/game/types/merchant_types.xml b/application/shipsimu/templates/game/types/merchant_types.xml
new file mode 100644 (file)
index 0000000..878359f
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid merchant types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<merchant-type-list merchant-type-count="{?merchant_type_count?}">
+</merchant-type-list>
diff --git a/application/shipsimu/templates/game/types/owner_occupants.xml b/application/shipsimu/templates/game/types/owner_occupants.xml
new file mode 100644 (file)
index 0000000..e72ceea
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All types of owners and occupants
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished definition
+
+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/>
+//-->
+<owner-occupant-type-list owner-occupant-type-count="{?owner_occupant_type_count?}">
+</owner-occupants-type-list>
diff --git a/application/shipsimu/templates/game/types/product_types.xml b/application/shipsimu/templates/game/types/product_types.xml
new file mode 100644 (file)
index 0000000..8c82ddc
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid product types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<product-type-list product-type-count="{?product_type_count?}">
+</product-type-list>
diff --git a/application/shipsimu/templates/game/types/research_types.xml b/application/shipsimu/templates/game/types/research_types.xml
new file mode 100644 (file)
index 0000000..0fc7280
--- /dev/null
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid research proposal types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<research-type-list research-type-count="{?research_type_count?}">
+       <!-- A base research proposal which all others depend on. //-->
+       <research-type type="base" />
+       <!-- An electronics research proposal. This type may conflict with the
+            same technology. This is also why it is hard to devide between
+            technology and theory in this type. //-->
+       <research-type type="electronics" />
+</technology-type-list>
diff --git a/application/shipsimu/templates/game/types/ship_types.xml b/application/shipsimu/templates/game/types/ship_types.xml
new file mode 100644 (file)
index 0000000..2d47c7b
--- /dev/null
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All known and valid types of ships.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          This is a very simmple list, extend it.
+
+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/>
+//-->
+<ship-type-list ship-type-count="{?ship_type_count?}">
+       <!-- A small ship for passengers used in large habors and cities. //-->
+       <ship-type type="farry" />
+       <!-- Medium to large passenger ships, used to transportate passengers, their
+            cars and trucks or trains on long distances. //-->
+       <ship-type type="passenger" />
+       <!-- Medium to large container ships to transport their cargo on long
+            distances. //-->
+       <ship-type type="container" />
+       <!-- Medium to large oil tankers for long distances. //-->
+       <ship-type type="oiltanker" />
+       <!-- Medium to large gas tankers for long distances. //-->
+       <ship-type type="gastanker" />
+       <!-- @TODO Add more ship types. //-->
+</ship-type-list>
diff --git a/application/shipsimu/templates/game/types/signer_types.xml b/application/shipsimu/templates/game/types/signer_types.xml
new file mode 100644 (file)
index 0000000..611853a
--- /dev/null
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid signer types and how they should translated into database and table
+names.
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@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/>
+//-->
+<signer-type-list signer-type-count="{?signer_type_count?}">
+       <!-- The type 'player' which is in facts the user. //-->
+       <signer-type type="player" table="user" column="userid" />
+       <!-- @TODO Add more types, e.g. company //-->
+</signer-types-list>
diff --git a/application/shipsimu/templates/game/types/tank_types.xml b/application/shipsimu/templates/game/types/tank_types.xml
new file mode 100644 (file)
index 0000000..2aa4d22
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid tank types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<tank-type-list tank-type-count="{?tank_type_count?}">
+</tank-type-list>
diff --git a/application/shipsimu/templates/game/types/technology_types.xml b/application/shipsimu/templates/game/types/technology_types.xml
new file mode 100644 (file)
index 0000000..b139d89
--- /dev/null
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+All valid technology types
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<technology-type-list technology-type-count="{?technology_type_count?}">
+       <!-- A base technology which all others depend on. //-->
+       <technology-type type="base" />
+       <!-- Technology required for construction of buildings. //-->
+       <technology-type type="building" />
+       <!-- Different chemicals. //-->
+       <technology-type type="chemicals" />
+       <!-- Technologies for common communication devices. //-->
+       <technology-type type="communication" />
+       <!-- Technologies for different constructions. //-->
+       <technology-type type="construction" />
+       <!-- Different electronics technologies. //-->
+       <technology-type type="electronics" />
+       <!-- Different equipment technologies. //-->
+       <technology-type type="equipment" />
+       <!-- Different production technologies. //-->
+       <technology-type type="production" />
+       <!-- Technologies for different ship constructions. //-->
+       <technology-type type="ship_construction" />
+</technology-type-list>
diff --git a/application/shipsimu/templates/game/vegetable/.htaccess b/application/shipsimu/templates/game/vegetable/.htaccess
new file mode 100644 (file)
index 0000000..3a42882
--- /dev/null
@@ -0,0 +1 @@
+Deny from all
diff --git a/application/shipsimu/templates/game/vegetable/base_vegetable.xml b/application/shipsimu/templates/game/vegetable/base_vegetable.xml
new file mode 100644 (file)
index 0000000..80925e5
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+A general vegetable template
+
+@author                Roland Haeder <webmaster@ship-simu.org>
+@version       0.0.0
+@copyright     Copyright (c) 2007, 2008 Roland Haeder, 2009 Ship-Simu Developer Team
+@license       GNU GPL 3.0 or any newer version
+@link          http://www.ship-simu.org
+@todo          Unfinished template
+
+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/>
+//-->
+<vegetable extends="base_produce">
+</vegetable>
diff --git a/core b/core
new file mode 160000 (submodule)
index 0000000..c776f0a
--- /dev/null
+++ b/core
@@ -0,0 +1 @@
+Subproject commit c776f0aeecb50d67e57b30c61bc84d80192090c2
diff --git a/inc b/inc
new file mode 120000 (symlink)
index 0000000..1f8dea2
--- /dev/null
+++ b/inc
@@ -0,0 +1 @@
+core/inc
\ No newline at end of file