Index: trunk/phase3/includes/db/DatabaseOracle.php |
— | — | @@ -706,5 +706,15 @@ |
707 | 707 | function getServer() { |
708 | 708 | return $this->mServer; |
709 | 709 | } |
| 710 | + |
| 711 | + /** |
| 712 | + * No-op lock functions |
| 713 | + */ |
| 714 | + public function lock( $lockName, $method ) { |
| 715 | + return true; |
| 716 | + } |
| 717 | + public function unlock( $lockName, $method ) { |
| 718 | + return true; |
| 719 | + } |
710 | 720 | |
711 | 721 | } // end DatabaseOracle class |
Index: trunk/phase3/includes/db/DatabasePostgres.php |
— | — | @@ -1327,4 +1327,13 @@ |
1328 | 1328 | return implode( ' || ', $stringList ); |
1329 | 1329 | } |
1330 | 1330 | |
| 1331 | + /* These are not used yet, but we know we don't want the default version */ |
| 1332 | + |
| 1333 | + public function lock( $lockName, $method ) { |
| 1334 | + return true; |
| 1335 | + } |
| 1336 | + public function unlock( $lockName, $method ) { |
| 1337 | + return true; |
| 1338 | + } |
| 1339 | + |
1331 | 1340 | } // end DatabasePostgres class |
Index: trunk/phase3/includes/db/Database.php |
— | — | @@ -2236,32 +2236,6 @@ |
2237 | 2237 | } |
2238 | 2238 | |
2239 | 2239 | /** |
2240 | | - * Acquire a lock, no-op to be overridden |
2241 | | - * by subclasses as needed. |
2242 | | - */ |
2243 | | - public function lock( $lockName, $method ) { |
2244 | | - return true; |
2245 | | - } |
2246 | | - /** |
2247 | | - * Release a lock, no-op to be overridden |
2248 | | - * by subclasses as needed. |
2249 | | - */ |
2250 | | - public function unlock( $lockName, $method ) { |
2251 | | - return true; |
2252 | | - } |
2253 | | -} |
2254 | | - |
2255 | | -/** |
2256 | | - * Database abstraction object for mySQL |
2257 | | - * Inherit all methods and properties of Database::Database(), |
2258 | | - * except for locking. |
2259 | | - * |
2260 | | - * @ingroup Database |
2261 | | - * @see Database |
2262 | | - */ |
2263 | | -class DatabaseMysql extends Database { |
2264 | | - |
2265 | | - /** |
2266 | 2240 | * Acquire a lock |
2267 | 2241 | * |
2268 | 2242 | * Abstracted from Filestore::lock() so child classes can implement for |
— | — | @@ -2284,7 +2258,6 @@ |
2285 | 2259 | return false; |
2286 | 2260 | } |
2287 | 2261 | } |
2288 | | - |
2289 | 2262 | /** |
2290 | 2263 | * Release a lock. |
2291 | 2264 | * |
— | — | @@ -2301,6 +2274,17 @@ |
2302 | 2275 | } |
2303 | 2276 | } |
2304 | 2277 | |
| 2278 | +/** |
| 2279 | + * Database abstraction object for mySQL |
| 2280 | + * Inherit all methods and properties of Database::Database() |
| 2281 | + * |
| 2282 | + * @ingroup Database |
| 2283 | + * @see Database |
| 2284 | + */ |
| 2285 | +class DatabaseMysql extends Database { |
| 2286 | + # Inherit all |
| 2287 | +} |
| 2288 | + |
2305 | 2289 | /****************************************************************************** |
2306 | 2290 | * Utility classes |
2307 | 2291 | *****************************************************************************/ |
Index: trunk/phase3/includes/db/DatabaseMssql.php |
— | — | @@ -997,6 +997,16 @@ |
998 | 998 | $this->query("$sql $matches[1],$matches[2])"); |
999 | 999 | } |
1000 | 1000 | } |
| 1001 | + |
| 1002 | + /** |
| 1003 | + * No-op lock functions |
| 1004 | + */ |
| 1005 | + public function lock( $lockName, $method ) { |
| 1006 | + return true; |
| 1007 | + } |
| 1008 | + public function unlock( $lockName, $method ) { |
| 1009 | + return true; |
| 1010 | + } |
1001 | 1011 | |
1002 | 1012 | } |
1003 | 1013 | |
Index: trunk/phase3/includes/db/DatabaseSqlite.php |
— | — | @@ -373,6 +373,16 @@ |
374 | 374 | $this->query("$sql $matches[1],$matches[2])"); |
375 | 375 | } |
376 | 376 | } |
| 377 | + |
| 378 | + /** |
| 379 | + * No-op lock functions |
| 380 | + */ |
| 381 | + public function lock( $lockName, $method ) { |
| 382 | + return true; |
| 383 | + } |
| 384 | + public function unlock( $lockName, $method ) { |
| 385 | + return true; |
| 386 | + } |
377 | 387 | |
378 | 388 | } |
379 | 389 | |