X-Git-Url: https://git.mxchange.org/?p=shipsimu.git;a=blobdiff_plain;f=inc%2Fclasses%2Fmiddleware%2Fdatabase%2Fclass_DatabaseConnection.php;h=6f0a4e1ef2660a5b0664689a5aaf11feb749b591;hp=736ece5e8cbb3ac68138c290dedbbb759f62e487;hb=df33e264f3246f80756d7e2da55d7f7c40f9088c;hpb=4f8c6dfcdc9b0a11ef041d0658f98d10a85e87fa diff --git a/inc/classes/middleware/database/class_DatabaseConnection.php b/inc/classes/middleware/database/class_DatabaseConnection.php index 736ece5..6f0a4e1 100644 --- a/inc/classes/middleware/database/class_DatabaseConnection.php +++ b/inc/classes/middleware/database/class_DatabaseConnection.php @@ -46,12 +46,6 @@ class DatabaseConnection extends BaseMiddleware implements DatabaseConnector, Re protected function __construct() { // Call parent constructor parent::__construct(__CLASS__); - - // Set description - $this->setObjectDescription("Datenbank-Mittelschicht"); - - // Create an unique ID - $this->generateUniqueId(); } // Create new database connection layer @@ -105,22 +99,12 @@ class DatabaseConnection extends BaseMiddleware implements DatabaseConnector, Re } /** - * Analyses if a unique ID has already been used or not. This method does - * only pass the given ID through to the "real" database layer. + * Getter for index key * - * @param $uniqueID A unique ID number which shall be checked - * before it will be used - * @param $inConstructor If called from a constructor or from - * somewhere else - * @return $isUnused true = The unique ID was not found in the database, - * false = It is already in use by an other object + * @return $indexKey Index key */ - public function isUniqueIdUsed ($uniqueID, $inConstructor = false) { - // Connect to the database - $this->dbLayer->connectToDatabase(); - - // Pass the returning result through - return $this->dbLayer->isUniqueIdUsed($uniqueID, $inConstructor); + public final function getIndexKey () { + return $this->dbLayer->getIndexKey(); } /**