MediaWiki REL1_37
LockManagerGroupFactory.php
Go to the documentation of this file.
1<?php
2
4
7
14
17
19 private $lbFactory;
20
22 private $instances = [];
23
32 $this->defaultDomain = $defaultDomain;
33 $this->lockManagerConfigs = $lockManagerConfigs;
34 $this->lbFactory = $lbFactory;
35 }
36
42 public function getLockManagerGroup( $domain = false ): LockManagerGroup {
43 if ( $domain === false || $domain === null ) {
44 $domain = $this->defaultDomain;
45 }
46
47 if ( !isset( $this->instances[$domain] ) ) {
48 $this->instances[$domain] =
49 new LockManagerGroup( $domain, $this->lockManagerConfigs, $this->lbFactory );
50 }
51
52 return $this->instances[$domain];
53 }
54}
if(ini_get('mbstring.func_overload')) if(!defined('MW_ENTRY_POINT'))
Pre-config setup: Before loading LocalSettings.php.
Definition Setup.php:88
Class to handle file lock manager registration.
LockManagerGroup[] $instances
(domain => LockManagerGroup)
__construct( $defaultDomain, array $lockManagerConfigs, LBFactory $lbFactory)
Do not call directly, use MediaWikiServices.
An interface for generating database load balancers.
Definition LBFactory.php:42