]> git.mxchange.org Git - friendica.git/commitdiff
Add some phpdoc
authorPhilipp Holzer <admin+github@philipp.info>
Sat, 27 Jul 2019 13:35:53 +0000 (15:35 +0200)
committerPhilipp Holzer <admin+github@philipp.info>
Sat, 27 Jul 2019 21:54:14 +0000 (23:54 +0200)
tests/Util/Database/StaticDatabase.php

index 6f9bdbe8b5db3c64b0d369e6b407ee8d90ffbce5..63544c4f679306e064358ae737ba8a62e0b4cf39 100644 (file)
@@ -6,6 +6,10 @@ use Friendica\Database\Database;
 use PDO;
 use PDOException;
 
+/**
+ * Overrides the Friendica database class for re-using the connection
+ * for different tests
+ */
 class StaticDatabase extends Database
 {
        /**
@@ -99,13 +103,16 @@ class StaticDatabase extends Database
        }
 
        /**
-        * @return ExtendedPDO
+        * @return ExtendedPDO The global, static connection
         */
        public static function getGlobConnection()
        {
                return self::$staticConnection;
        }
 
+       /**
+        * Perform a global commit for every nested transaction of the static connection
+        */
        public static function statCommit()
        {
                if (isset(self::$staticConnection)) {
@@ -115,6 +122,9 @@ class StaticDatabase extends Database
                }
        }
 
+       /**
+        * Perform a global rollback for every nested transaction of the static connection
+        */
        public static function statRollback()
        {
                if (isset(self::$staticConnection)) {