MediaWiki  master
MediaWikiServices.php
Go to the documentation of this file.
1 <?php
2 
3 namespace MediaWiki;
4 
6 use BagOStuff;
8 use CommentStore;
9 use Config;
10 use ConfigFactory;
12 use CryptHKDF;
18 use GenderCache;
19 use GlobalVarConfig;
22 use JobQueueGroup;
23 use JobRunner;
24 use Language;
25 use LinkCache;
26 use Liuggio\StatsdClient\Factory\StatsdDataFactoryInterface;
122 use MessageCache;
123 use MimeAnalyzer;
124 use MWException;
125 use NamespaceInfo;
126 use ObjectCache;
128 use PageProps;
129 use Parser;
130 use ParserCache;
131 use ParserFactory;
132 use PasswordFactory;
133 use PasswordReset;
134 use ProxyLookup;
135 use ReadOnlyMode;
136 use RepoGroup;
137 use ResourceLoader;
138 use SearchEngine;
141 use SiteLookup;
142 use SiteStore;
143 use SkinFactory;
144 use TitleFactory;
145 use TitleFormatter;
146 use TitleParser;
149 use UserCache;
151 use WANObjectCache;
157 use Wikimedia\NonSerializable\NonSerializableTrait;
158 use Wikimedia\ObjectFactory;
161 use Wikimedia\RequestTimeout\CriticalSectionProvider;
162 use Wikimedia\Services\NoSuchServiceException;
163 use Wikimedia\Services\SalvageableService;
164 use Wikimedia\Services\ServiceContainer;
166 
203 class MediaWikiServices extends ServiceContainer {
204  use NonSerializableTrait;
205 
209  private static $globalInstanceAllowed = false;
210 
214  private static $instance = null;
215 
227  public static function allowGlobalInstance() {
228  self::$globalInstanceAllowed = true;
229 
230  if ( self::$instance ) {
231  // TODO: in 1.37, getInstance() should fail if $globalInstanceAllowed is false! (T153256)
232  // Until then, we have to reset service instances that have already been created.
233  // No need to warn here, getService() has already triggered a deprecation warning.
234  self::resetGlobalInstance( null, 'quick' );
235  }
236  }
237 
244  public static function hasInstance() {
245  return self::$instance !== null;
246  }
247 
264  public static function getInstance(): self {
265  // TODO: in 1.37, getInstance() should fail if $globalInstanceAllowed is false! (T153256)
266  if ( !self::$globalInstanceAllowed ) {
267  wfDeprecatedMsg( 'Premature access to service container', '1.36' );
268  }
269 
270  if ( self::$instance === null ) {
271  // NOTE: constructing GlobalVarConfig here is not particularly pretty,
272  // but some information from the global scope has to be injected here,
273  // even if it's just a file name or database credentials to load
274  // configuration from.
275  $bootstrapConfig = new GlobalVarConfig();
276  self::$instance = self::newInstance( $bootstrapConfig, 'load' );
277 
278  // Provides a traditional hook point to allow extensions to configure services.
279  // NOTE: Ideally this would be in newInstance() but it causes an infinite run loop
280  $runner = new HookRunner( self::$instance->getHookContainer() );
281  $runner->onMediaWikiServices( self::$instance );
282  }
283  return self::$instance;
284  }
285 
286  public function getService( $name ) {
287  // TODO: in 1.37, getInstance() should fail if $globalInstanceAllowed is false! (T153256)
288  if ( !self::$globalInstanceAllowed && $this === self::$instance ) {
289  wfDeprecatedMsg( "Premature access to service '$name'", '1.36', false, 3 );
290  }
291 
292  return parent::getService( $name );
293  }
294 
308  public static function forceGlobalInstance( MediaWikiServices $services ) {
309  if ( !defined( 'MW_PHPUNIT_TEST' ) && !defined( 'MW_PARSER_TEST' ) ) {
310  throw new MWException( __METHOD__ . ' must not be used outside unit tests.' );
311  }
312 
313  $old = self::getInstance();
314  self::$instance = $services;
315 
316  return $old;
317  }
318 
358  public static function resetGlobalInstance( Config $bootstrapConfig = null, $quick = '' ) {
359  if ( self::$instance === null ) {
360  // no global instance yet, nothing to reset
361  return;
362  }
363 
364  self::failIfResetNotAllowed( __METHOD__ );
365 
366  if ( $bootstrapConfig === null ) {
367  $bootstrapConfig = self::$instance->getBootstrapConfig();
368  }
369 
370  $oldInstance = self::$instance;
371 
372  self::$instance = self::newInstance( $bootstrapConfig, 'load' );
373 
374  // Provides a traditional hook point to allow extensions to configure services.
375  $runner = new HookRunner( $oldInstance->getHookContainer() );
376  $runner->onMediaWikiServices( self::$instance );
377 
378  self::$instance->importWiring( $oldInstance, [ 'BootstrapConfig' ] );
379 
380  if ( $quick === 'quick' ) {
381  self::$instance->salvage( $oldInstance );
382  } else {
383  $oldInstance->destroy();
384  }
385  }
386 
396  private function salvage( self $other ) {
397  foreach ( $this->getServiceNames() as $name ) {
398  // The service could be new in the new instance and not registered in the
399  // other instance (e.g. an extension that was loaded after the instantiation of
400  // the other instance. Skip this service in this case. See T143974
401  try {
402  $oldService = $other->peekService( $name );
403  } catch ( NoSuchServiceException $e ) {
404  continue;
405  }
406 
407  if ( $oldService instanceof SalvageableService ) {
409  $newService = $this->getService( $name );
410  $newService->salvage( $oldService );
411  }
412  }
413 
414  $other->destroy();
415  }
416 
432  private static function newInstance( Config $bootstrapConfig, $loadWiring = '' ) {
433  $instance = new self( $bootstrapConfig );
434 
435  // Load the default wiring from the specified files.
436  if ( $loadWiring === 'load' ) {
437  $wiringFiles = $bootstrapConfig->get( 'ServiceWiringFiles' );
438  $instance->loadWiringFiles( $wiringFiles );
439  }
440 
441  return $instance;
442  }
443 
459  public static function disableStorageBackend() {
460  // TODO: also disable some Caches, JobQueues, etc
461  $destroy = [ 'DBLoadBalancer', 'DBLoadBalancerFactory' ];
462  $services = self::getInstance();
463 
464  foreach ( $destroy as $name ) {
465  $services->disableService( $name );
466  }
467 
469  }
470 
483  public static function resetChildProcessServices() {
484  // NOTE: for now, just reset everything. Since we don't know the interdependencies
485  // between services, we can't do this more selectively at this time.
486  self::resetGlobalInstance();
487 
488  // Child, reseed because there is no bug in PHP:
489  // https://bugs.php.net/bug.php?id=42465
490  mt_srand( getmypid() );
491  }
492 
514  public function resetServiceForTesting( $name, $destroy = true ) {
515  if ( !defined( 'MW_PHPUNIT_TEST' ) && !defined( 'MW_PARSER_TEST' ) ) {
516  throw new MWException( 'resetServiceForTesting() must not be used outside unit tests.' );
517  }
518 
519  $this->resetService( $name, $destroy );
520  }
521 
549  public static function failIfResetNotAllowed( $method ) {
550  if ( !defined( 'MW_PHPUNIT_TEST' )
551  && !defined( 'MW_PARSER_TEST' )
552  && !defined( 'MEDIAWIKI_INSTALL' )
553  && !defined( 'RUN_MAINTENANCE_IF_MAIN' )
554  && defined( 'MW_SERVICE_BOOTSTRAP_COMPLETE' )
555  ) {
556  throw new MWException( $method . ' may only be called during bootstrapping and unit tests!' );
557  }
558  }
559 
565  public function __construct( Config $config ) {
566  parent::__construct();
567 
568  // Register the given Config object as the bootstrap config service.
569  $this->defineService( 'BootstrapConfig', static function () use ( $config ) {
570  return $config;
571  } );
572  }
573 
574  // CONVENIENCE GETTERS ////////////////////////////////////////////////////
575 
580  public function getActionFactory(): ActionFactory {
581  return $this->getService( 'ActionFactory' );
582  }
583 
588  public function getActorMigration(): ActorMigration {
589  return $this->getService( 'ActorMigration' );
590  }
591 
596  public function getActorNormalization(): ActorNormalization {
597  return $this->getService( 'ActorNormalization' );
598  }
599 
604  public function getActorStore(): ActorStore {
605  return $this->getService( 'ActorStore' );
606  }
607 
612  public function getActorStoreFactory(): ActorStoreFactory {
613  return $this->getService( 'ActorStoreFactory' );
614  }
615 
620  public function getArchivedRevisionLookup(): ArchivedRevisionLookup {
621  return $this->getService( 'ArchivedRevisionLookup' );
622  }
623 
628  public function getAuthManager(): AuthManager {
629  return $this->getService( 'AuthManager' );
630  }
631 
636  public function getBacklinkCacheFactory(): BacklinkCacheFactory {
637  return $this->getService( 'BacklinkCacheFactory' );
638  }
639 
644  public function getBadFileLookup(): BadFileLookup {
645  return $this->getService( 'BadFileLookup' );
646  }
647 
652  public function getBlobStore(): BlobStore {
653  return $this->getService( 'BlobStore' );
654  }
655 
660  public function getBlobStoreFactory(): BlobStoreFactory {
661  return $this->getService( 'BlobStoreFactory' );
662  }
663 
668  public function getBlockActionInfo(): BlockActionInfo {
669  return $this->getService( 'BlockActionInfo' );
670  }
671 
676  public function getBlockErrorFormatter(): BlockErrorFormatter {
677  return $this->getService( 'BlockErrorFormatter' );
678  }
679 
684  public function getBlockManager(): BlockManager {
685  return $this->getService( 'BlockManager' );
686  }
687 
692  public function getBlockPermissionCheckerFactory(): BlockPermissionCheckerFactory {
693  return $this->getService( 'BlockPermissionCheckerFactory' );
694  }
695 
700  public function getBlockRestrictionStore(): BlockRestrictionStore {
701  return $this->getService( 'BlockRestrictionStore' );
702  }
703 
708  public function getBlockUserFactory(): BlockUserFactory {
709  return $this->getService( 'BlockUserFactory' );
710  }
711 
716  public function getBlockUtils(): BlockUtils {
717  return $this->getService( 'BlockUtils' );
718  }
719 
733  public function getBootstrapConfig(): Config {
734  return $this->getService( 'BootstrapConfig' );
735  }
736 
741  public function getBotPasswordStore(): BotPasswordStore {
742  return $this->getService( 'BotPasswordStore' );
743  }
744 
749  public function getCentralIdLookup(): CentralIdLookup {
750  return $this->getService( 'CentralIdLookup' );
751  }
752 
757  public function getCentralIdLookupFactory(): CentralIdLookupFactory {
758  return $this->getService( 'CentralIdLookupFactory' );
759  }
760 
765  public function getChangeTagDefStore(): NameTableStore {
766  return $this->getService( 'ChangeTagDefStore' );
767  }
768 
773  public function getCollationFactory(): CollationFactory {
774  return $this->getService( 'CollationFactory' );
775  }
776 
781  public function getCommentFormatter(): CommentFormatter {
782  return $this->getService( 'CommentFormatter' );
783  }
784 
789  public function getCommentStore(): CommentStore {
790  return $this->getService( 'CommentStore' );
791  }
792 
797  public function getConfigFactory(): ConfigFactory {
798  return $this->getService( 'ConfigFactory' );
799  }
800 
805  public function getConfigRepository(): ConfigRepository {
806  return $this->getService( 'ConfigRepository' );
807  }
808 
814  return $this->getService( 'ConfiguredReadOnlyMode' );
815  }
816 
821  public function getContentHandlerFactory(): IContentHandlerFactory {
822  return $this->getService( 'ContentHandlerFactory' );
823  }
824 
829  public function getContentLanguage(): Language {
830  return $this->getService( 'ContentLanguage' );
831  }
832 
837  public function getContentModelChangeFactory(): ContentModelChangeFactory {
838  return $this->getService( 'ContentModelChangeFactory' );
839  }
840 
845  public function getContentModelStore(): NameTableStore {
846  return $this->getService( 'ContentModelStore' );
847  }
848 
853  public function getContentRenderer(): ContentRenderer {
854  return $this->getService( 'ContentRenderer' );
855  }
856 
861  public function getContentTransformer(): ContentTransformer {
862  return $this->getService( 'ContentTransformer' );
863  }
864 
869  public function getContributionsLookup(): ContributionsLookup {
870  return $this->getService( 'ContributionsLookup' );
871  }
872 
877  public function getCriticalSectionProvider(): CriticalSectionProvider {
878  return $this->getService( 'CriticalSectionProvider' );
879  }
880 
885  public function getCryptHKDF(): CryptHKDF {
886  return $this->getService( 'CryptHKDF' );
887  }
888 
893  public function getDatabaseBlockStore(): DatabaseBlockStore {
894  return $this->getService( 'DatabaseBlockStore' );
895  }
896 
902  return $this->getService( 'DateFormatterFactory' );
903  }
904 
909  public function getDBLoadBalancer(): ILoadBalancer {
910  return $this->getService( 'DBLoadBalancer' );
911  }
912 
917  public function getDBLoadBalancerFactory(): LBFactory {
918  return $this->getService( 'DBLoadBalancerFactory' );
919  }
920 
925  public function getDeletePageFactory(): DeletePageFactory {
926  return $this->getService( 'DeletePageFactory' );
927  }
928 
933  public function getEmailer(): IEmailer {
934  return $this->getService( 'Emailer' );
935  }
936 
942  return $this->getService( 'EventRelayerGroup' );
943  }
944 
950  return $this->getService( 'ExternalStoreAccess' );
951  }
952 
958  return $this->getService( 'ExternalStoreFactory' );
959  }
960 
966  return $this->getService( 'FileBackendGroup' );
967  }
968 
973  public function getGenderCache(): GenderCache {
974  return $this->getService( 'GenderCache' );
975  }
976 
981  public function getGlobalIdGenerator(): GlobalIdGenerator {
982  return $this->getService( 'GlobalIdGenerator' );
983  }
984 
989  public function getGrantsInfo(): GrantsInfo {
990  return $this->getService( 'GrantsInfo' );
991  }
992 
997  public function getGrantsLocalization(): GrantsLocalization {
998  return $this->getService( 'GrantsLocalization' );
999  }
1000 
1005  public function getGroupPermissionsLookup(): GroupPermissionsLookup {
1006  return $this->getService( 'GroupPermissionsLookup' );
1007  }
1008 
1013  public function getHookContainer(): HookContainer {
1014  return $this->getService( 'HookContainer' );
1015  }
1016 
1022  return $this->getService( 'HtmlCacheUpdater' );
1023  }
1024 
1029  public function getHttpRequestFactory(): HttpRequestFactory {
1030  return $this->getService( 'HttpRequestFactory' );
1031  }
1032 
1037  public function getInterwikiLookup(): InterwikiLookup {
1038  return $this->getService( 'InterwikiLookup' );
1039  }
1040 
1045  public function getJobQueueGroup(): JobQueueGroup {
1046  return $this->getService( 'JobQueueGroup' );
1047  }
1048 
1053  public function getJobQueueGroupFactory(): JobQueueGroupFactory {
1054  return $this->getService( 'JobQueueGroupFactory' );
1055  }
1056 
1061  public function getJobRunner(): JobRunner {
1062  return $this->getService( 'JobRunner' );
1063  }
1064 
1069  public function getJsonCodec(): JsonCodec {
1070  return $this->getService( 'JsonCodec' );
1071  }
1072 
1077  public function getLanguageConverterFactory(): LanguageConverterFactory {
1078  return $this->getService( 'LanguageConverterFactory' );
1079  }
1080 
1085  public function getLanguageFactory(): LanguageFactory {
1086  return $this->getService( 'LanguageFactory' );
1087  }
1088 
1093  public function getLanguageFallback(): LanguageFallback {
1094  return $this->getService( 'LanguageFallback' );
1095  }
1096 
1101  public function getLanguageNameUtils(): LanguageNameUtils {
1102  return $this->getService( 'LanguageNameUtils' );
1103  }
1104 
1109  public function getLinkBatchFactory(): LinkBatchFactory {
1110  return $this->getService( 'LinkBatchFactory' );
1111  }
1112 
1117  public function getLinkCache(): LinkCache {
1118  return $this->getService( 'LinkCache' );
1119  }
1120 
1128  public function getLinkRenderer(): LinkRenderer {
1129  return $this->getService( 'LinkRenderer' );
1130  }
1131 
1136  public function getLinkRendererFactory(): LinkRendererFactory {
1137  return $this->getService( 'LinkRendererFactory' );
1138  }
1139 
1145  return $this->getService( 'LocalisationCache' );
1146  }
1147 
1158  return $this->getService( 'LocalServerObjectCache' );
1159  }
1160 
1165  public function getLockManagerGroupFactory(): LockManagerGroupFactory {
1166  return $this->getService( 'LockManagerGroupFactory' );
1167  }
1168 
1174  return $this->getService( 'MagicWordFactory' );
1175  }
1176 
1184  public function getMainConfig(): Config {
1185  return $this->getService( 'MainConfig' );
1186  }
1187 
1196  public function getMainObjectStash(): BagOStuff {
1197  return $this->getService( 'MainObjectStash' );
1198  }
1199 
1209  return $this->getService( 'MainWANObjectCache' );
1210  }
1211 
1217  return $this->getService( 'MediaHandlerFactory' );
1218  }
1219 
1224  public function getMergeHistoryFactory(): MergeHistoryFactory {
1225  return $this->getService( 'MergeHistoryFactory' );
1226  }
1227 
1232  public function getMessageCache(): MessageCache {
1233  return $this->getService( 'MessageCache' );
1234  }
1235 
1240  public function getMessageFormatterFactory(): IMessageFormatterFactory {
1241  return $this->getService( 'MessageFormatterFactory' );
1242  }
1243 
1248  public function getMetricsFactory(): MetricsFactory {
1249  return $this->getService( 'MetricsFactory' );
1250  }
1251 
1256  public function getMimeAnalyzer(): MimeAnalyzer {
1257  return $this->getService( 'MimeAnalyzer' );
1258  }
1259 
1264  public function getMovePageFactory(): MovePageFactory {
1265  return $this->getService( 'MovePageFactory' );
1266  }
1267 
1272  public function getNamespaceInfo(): NamespaceInfo {
1273  return $this->getService( 'NamespaceInfo' );
1274  }
1275 
1280  public function getNameTableStoreFactory(): NameTableStoreFactory {
1281  return $this->getService( 'NameTableStoreFactory' );
1282  }
1283 
1291  public function getObjectFactory(): ObjectFactory {
1292  return $this->getService( 'ObjectFactory' );
1293  }
1294 
1300  return $this->getService( 'OldRevisionImporter' );
1301  }
1302 
1307  public function getPageEditStash(): PageEditStash {
1308  return $this->getService( 'PageEditStash' );
1309  }
1310 
1315  public function getPageProps(): PageProps {
1316  return $this->getService( 'PageProps' );
1317  }
1318 
1323  public function getPageStore(): PageStore {
1324  return $this->getService( 'PageStore' );
1325  }
1326 
1331  public function getPageStoreFactory(): PageStoreFactory {
1332  return $this->getService( 'PageStoreFactory' );
1333  }
1334 
1339  public function getPageUpdaterFactory(): PageUpdaterFactory {
1340  return $this->getService( 'PageUpdaterFactory' );
1341  }
1342 
1347  public function getParser(): Parser {
1348  return $this->getService( 'Parser' );
1349  }
1350 
1355  public function getParserCache(): ParserCache {
1356  return $this->getService( 'ParserCache' );
1357  }
1358 
1363  public function getParserCacheFactory(): ParserCacheFactory {
1364  return $this->getService( 'ParserCacheFactory' );
1365  }
1366 
1371  public function getParserFactory(): ParserFactory {
1372  return $this->getService( 'ParserFactory' );
1373  }
1374 
1379  public function getParserOutputAccess(): ParserOutputAccess {
1380  return $this->getService( 'ParserOutputAccess' );
1381  }
1382 
1388  return $this->getService( 'PasswordFactory' );
1389  }
1390 
1395  public function getPasswordReset(): PasswordReset {
1396  return $this->getService( 'PasswordReset' );
1397  }
1398 
1403  public function getPerDbNameStatsdDataFactory(): StatsdDataFactoryInterface {
1404  return $this->getService( 'PerDbNameStatsdDataFactory' );
1405  }
1406 
1411  public function getPermissionManager(): PermissionManager {
1412  return $this->getService( 'PermissionManager' );
1413  }
1414 
1419  public function getPreferencesFactory(): PreferencesFactory {
1420  return $this->getService( 'PreferencesFactory' );
1421  }
1422 
1427  public function getProxyLookup(): ProxyLookup {
1428  return $this->getService( 'ProxyLookup' );
1429  }
1430 
1435  public function getReadOnlyMode(): ReadOnlyMode {
1436  return $this->getService( 'ReadOnlyMode' );
1437  }
1438 
1443  public function getRedirectLookup(): RedirectLookup {
1444  return $this->getService( 'RedirectLookup' );
1445  }
1446 
1451  public function getRedirectStore(): RedirectStore {
1452  return $this->getService( 'RedirectStore' );
1453  }
1454 
1459  public function getRepoGroup(): RepoGroup {
1460  return $this->getService( 'RepoGroup' );
1461  }
1462 
1467  public function getResourceLoader(): ResourceLoader {
1468  return $this->getService( 'ResourceLoader' );
1469  }
1470 
1475  public function getRestrictionStore(): RestrictionStore {
1476  return $this->getService( 'RestrictionStore' );
1477  }
1478 
1483  public function getRevertedTagUpdateManager(): RevertedTagUpdateManager {
1484  return $this->getService( 'RevertedTagUpdateManager' );
1485  }
1486 
1491  public function getRevisionFactory(): RevisionFactory {
1492  return $this->getService( 'RevisionFactory' );
1493  }
1494 
1499  public function getRevisionLookup(): RevisionLookup {
1500  return $this->getService( 'RevisionLookup' );
1501  }
1502 
1507  public function getRevisionRenderer(): RevisionRenderer {
1508  return $this->getService( 'RevisionRenderer' );
1509  }
1510 
1515  public function getRevisionStore(): RevisionStore {
1516  return $this->getService( 'RevisionStore' );
1517  }
1518 
1523  public function getRevisionStoreFactory(): RevisionStoreFactory {
1524  return $this->getService( 'RevisionStoreFactory' );
1525  }
1526 
1531  public function getRollbackPageFactory(): RollbackPageFactory {
1532  return $this->getService( 'RollbackPageFactory' );
1533  }
1534 
1539  public function getRowCommentFormatter(): RowCommentFormatter {
1540  return $this->getService( 'RowCommentFormatter' );
1541  }
1542 
1547  public function newSearchEngine(): SearchEngine {
1548  // New engine object every time, since they keep state
1549  return $this->getService( 'SearchEngineFactory' )->create();
1550  }
1551 
1557  return $this->getService( 'SearchEngineConfig' );
1558  }
1559 
1565  return $this->getService( 'SearchEngineFactory' );
1566  }
1567 
1572  public function getShellboxClientFactory(): ShellboxClientFactory {
1573  return $this->getService( 'ShellboxClientFactory' );
1574  }
1575 
1580  public function getShellCommandFactory(): CommandFactory {
1581  return $this->getService( 'ShellCommandFactory' );
1582  }
1583 
1588  public function getSignatureValidatorFactory(): SignatureValidatorFactory {
1589  return $this->getService( 'SignatureValidatorFactory' );
1590  }
1591 
1596  public function getSiteLookup(): SiteLookup {
1597  return $this->getService( 'SiteLookup' );
1598  }
1599 
1604  public function getSiteStore(): SiteStore {
1605  return $this->getService( 'SiteStore' );
1606  }
1607 
1612  public function getSkinFactory(): SkinFactory {
1613  return $this->getService( 'SkinFactory' );
1614  }
1615 
1620  public function getSlotRoleRegistry(): SlotRoleRegistry {
1621  return $this->getService( 'SlotRoleRegistry' );
1622  }
1623 
1628  public function getSlotRoleStore(): NameTableStore {
1629  return $this->getService( 'SlotRoleStore' );
1630  }
1631 
1636  public function getSpamChecker(): SpamChecker {
1637  return $this->getService( 'SpamChecker' );
1638  }
1639 
1644  public function getSpecialPageFactory(): SpecialPageFactory {
1645  return $this->getService( 'SpecialPageFactory' );
1646  }
1647 
1653  return $this->getService( 'StatsdDataFactory' );
1654  }
1655 
1660  public function getTalkPageNotificationManager(): TalkPageNotificationManager {
1661  return $this->getService( 'TalkPageNotificationManager' );
1662  }
1663 
1668  public function getTempFSFileFactory(): TempFSFileFactory {
1669  return $this->getService( 'TempFSFileFactory' );
1670  }
1671 
1676  public function getTidy(): TidyDriverBase {
1677  return $this->getService( 'Tidy' );
1678  }
1679 
1684  public function getTitleFactory(): TitleFactory {
1685  return $this->getService( 'TitleFactory' );
1686  }
1687 
1692  public function getTitleFormatter(): TitleFormatter {
1693  return $this->getService( 'TitleFormatter' );
1694  }
1695 
1700  public function getTitleParser(): TitleParser {
1701  return $this->getService( 'TitleParser' );
1702  }
1703 
1709  return $this->getService( 'TrackingCategories' );
1710  }
1711 
1716  public function getUnblockUserFactory(): UnblockUserFactory {
1717  return $this->getService( 'UnblockUserFactory' );
1718  }
1719 
1724  public function getUndeletePageFactory(): UndeletePageFactory {
1725  return $this->getService( 'UndeletePageFactory' );
1726  }
1727 
1733  return $this->getService( 'UploadRevisionImporter' );
1734  }
1735 
1740  public function getUserCache(): UserCache {
1741  return $this->getService( 'UserCache' );
1742  }
1743 
1748  public function getUserEditTracker(): UserEditTracker {
1749  return $this->getService( 'UserEditTracker' );
1750  }
1751 
1756  public function getUserFactory(): UserFactory {
1757  return $this->getService( 'UserFactory' );
1758  }
1759 
1764  public function getUserGroupManager(): UserGroupManager {
1765  return $this->getService( 'UserGroupManager' );
1766  }
1767 
1772  public function getUserGroupManagerFactory(): UserGroupManagerFactory {
1773  return $this->getService( 'UserGroupManagerFactory' );
1774  }
1775 
1780  public function getUserIdentityLookup(): UserIdentityLookup {
1781  return $this->getService( 'UserIdentityLookup' );
1782  }
1783 
1789  return $this->getService( 'UserNamePrefixSearch' );
1790  }
1791 
1796  public function getUserNameUtils(): UserNameUtils {
1797  return $this->getService( 'UserNameUtils' );
1798  }
1799 
1804  public function getUserOptionsLookup(): UserOptionsLookup {
1805  return $this->getService( 'UserOptionsLookup' );
1806  }
1807 
1812  public function getUserOptionsManager(): UserOptionsManager {
1813  return $this->getService( 'UserOptionsManager' );
1814  }
1815 
1821  return $this->getService( 'VirtualRESTServiceClient' );
1822  }
1823 
1829  return $this->getService( 'WatchedItemQueryService' );
1830  }
1831 
1837  return $this->getService( 'WatchedItemStore' );
1838  }
1839 
1845  public function getWatchlistNotificationManager(): WatchlistManager {
1846  wfDeprecated( __METHOD__, '1.36' );
1847  return $this->getWatchlistManager();
1848  }
1849 
1854  public function getWatchlistManager(): WatchlistManager {
1855  return $this->getService( 'WatchlistManager' );
1856  }
1857 
1862  public function getWikiExporterFactory(): WikiExporterFactory {
1863  return $this->getService( 'WikiExporterFactory' );
1864  }
1865 
1871  return $this->getService( 'WikiImporterFactory' );
1872  }
1873 
1878  public function getWikiPageFactory(): WikiPageFactory {
1879  return $this->getService( 'WikiPageFactory' );
1880  }
1881 
1887  return $this->getService( 'OldRevisionImporter' );
1888  }
1889 
1895  return $this->getService( 'WikiRevisionOldRevisionImporterNoUpdates' );
1896  }
1897 
1903  return $this->getService( 'UploadRevisionImporter' );
1904  }
1905 
1906 }
MediaWiki\MediaWikiServices\getJobQueueGroup
getJobQueueGroup()
Definition: MediaWikiServices.php:1045
EventRelayerGroup
Factory class for spawning EventRelayer objects using configuration.
Definition: EventRelayerGroup.php:26
MediaWiki\MediaWikiServices\getMessageCache
getMessageCache()
Definition: MediaWikiServices.php:1232
MediaWiki\MediaWikiServices\getBlockErrorFormatter
getBlockErrorFormatter()
Definition: MediaWikiServices.php:676
ObjectCache\clear
static clear()
Clear all the cached instances.
Definition: ObjectCache.php:282
ObjectCache
Functions to get cache objects.
Definition: ObjectCache.php:64
LinkCache
Cache for article titles (prefixed DB keys) and ids linked from one source.
Definition: LinkCache.php:41
MediaWiki\MediaWikiServices\getShellCommandFactory
getShellCommandFactory()
Definition: MediaWikiServices.php:1580
MediaWiki\Block\BlockPermissionCheckerFactory
Factory class for BlockPermissionChecker.
Definition: BlockPermissionCheckerFactory.php:33
Wikimedia\Metrics\MetricsFactory
Definition: MetricsFactory.php:40
MediaWiki\MediaWikiServices\getInterwikiLookup
getInterwikiLookup()
Definition: MediaWikiServices.php:1037
MediaWiki\Block\BlockUserFactory
Definition: BlockUserFactory.php:30
MediaWiki\MediaWikiServices\getSpamChecker
getSpamChecker()
Definition: MediaWikiServices.php:1636
MediaWiki\MediaWikiServices\getResourceLoader
getResourceLoader()
Definition: MediaWikiServices.php:1467
MediaWiki\MediaWikiServices\getSearchEngineConfig
getSearchEngineConfig()
Definition: MediaWikiServices.php:1556
UploadRevisionImporter
Definition: UploadRevisionImporter.php:6
Wikimedia\UUID\GlobalIdGenerator
Class for getting statistically unique IDs without a central coordinator.
Definition: GlobalIdGenerator.php:34
FileBackendGroup
Class to handle file backend registration.
Definition: FileBackendGroup.php:36
MediaWiki\MediaWikiServices\getCentralIdLookup
getCentralIdLookup()
Definition: MediaWikiServices.php:749
MagicWordFactory
A factory that stores information about MagicWords, and creates them on demand with caching.
Definition: MagicWordFactory.php:37
MediaWiki\MediaWikiServices\getSiteLookup
getSiteLookup()
Definition: MediaWikiServices.php:1596
MediaWiki\MediaWikiServices\getParserFactory
getParserFactory()
Definition: MediaWikiServices.php:1371
MediaWiki\MediaWikiServices\getBlockManager
getBlockManager()
Definition: MediaWikiServices.php:684
MediaWiki\MediaWikiServices\getJobRunner
getJobRunner()
Definition: MediaWikiServices.php:1061
UserCache
Definition: UserCache.php:32
MediaWiki\Block\BlockManager
A service class for checking blocks.
Definition: BlockManager.php:47
MediaWiki\MediaWikiServices\getBlockRestrictionStore
getBlockRestrictionStore()
Definition: MediaWikiServices.php:700
MediaWiki\MediaWikiServices\getDBLoadBalancer
getDBLoadBalancer()
Definition: MediaWikiServices.php:909
MediaWiki\Permissions\GroupPermissionsLookup
Definition: GroupPermissionsLookup.php:30
MediaWiki\MediaWikiServices\getRollbackPageFactory
getRollbackPageFactory()
Definition: MediaWikiServices.php:1531
MediaWiki\MediaWikiServices
MediaWikiServices is the service locator for the application scope of MediaWiki.
Definition: MediaWikiServices.php:203
MimeAnalyzer
Implements functions related to MIME types such as detection and mapping to file extension.
Definition: MimeAnalyzer.php:33
Page\ParserOutputAccess
Service for getting rendered output of a given page.
Definition: ParserOutputAccess.php:48
MediaWiki\Revision\RevisionStore
Service for looking up page revisions.
Definition: RevisionStore.php:89
MediaWiki\MediaWikiServices\getCollationFactory
getCollationFactory()
Definition: MediaWikiServices.php:773
MediaWiki\Block\BlockErrorFormatter
A service class for getting formatted information about a block.
Definition: BlockErrorFormatter.php:36
MediaWiki\Http\HttpRequestFactory
Factory creating MWHttpRequest objects.
Definition: HttpRequestFactory.php:35
MediaWiki\MediaWikiServices\getContentModelStore
getContentModelStore()
Definition: MediaWikiServices.php:845
MediaWiki\MediaWikiServices\getChangeTagDefStore
getChangeTagDefStore()
Definition: MediaWikiServices.php:765
MediaWiki\MediaWikiServices\getLanguageConverterFactory
getLanguageConverterFactory()
Definition: MediaWikiServices.php:1077
MediaWiki\Languages\LanguageFactory
Internationalisation code See https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation for more...
Definition: LanguageFactory.php:42
MediaWiki\Linker\LinkRenderer
Class that generates HTML links for pages.
Definition: LinkRenderer.php:43
MediaWiki\MediaWikiServices\getBlockPermissionCheckerFactory
getBlockPermissionCheckerFactory()
Definition: MediaWikiServices.php:692
MediaWiki\MediaWikiServices\getRevisionLookup
getRevisionLookup()
Definition: MediaWikiServices.php:1499
MediaWiki\Block\BlockUtils
Backend class for blocking utils.
Definition: BlockUtils.php:45
MediaWiki\SpecialPage\SpecialPageFactory
Factory for handling the special page list and generating SpecialPage objects.
Definition: SpecialPageFactory.php:63
ReadOnlyMode
A service class for fetching the wiki's current read-only mode.
Definition: ReadOnlyMode.php:11
MediaWiki\MediaWikiServices\getWatchlistManager
getWatchlistManager()
Definition: MediaWikiServices.php:1854
MediaWiki\MediaWikiServices\getContentTransformer
getContentTransformer()
Definition: MediaWikiServices.php:861
MediaWiki\MediaWikiServices\getActorStoreFactory
getActorStoreFactory()
Definition: MediaWikiServices.php:612
MediaWiki\MediaWikiServices\getBootstrapConfig
getBootstrapConfig()
Returns the Config object containing the bootstrap configuration.
Definition: MediaWikiServices.php:733
MediaWiki\MediaWikiServices\getArchivedRevisionLookup
getArchivedRevisionLookup()
Definition: MediaWikiServices.php:620
MediaWiki\FileBackend\LockManager\LockManagerGroupFactory
Service to construct LockManagerGroups.
Definition: LockManagerGroupFactory.php:11
MediaWiki\MediaWikiServices\getCommentStore
getCommentStore()
Definition: MediaWikiServices.php:789
MediaWiki\MediaWikiServices\getGlobalIdGenerator
getGlobalIdGenerator()
Definition: MediaWikiServices.php:981
MediaWiki\MediaWikiServices\getPageUpdaterFactory
getPageUpdaterFactory()
Definition: MediaWikiServices.php:1339
MediaWiki\MediaWikiServices\getSlotRoleStore
getSlotRoleStore()
Definition: MediaWikiServices.php:1628
Page\RollbackPageFactory
Definition: RollbackPageFactory.php:32
GenderCache
Caches user genders when needed to use correct namespace aliases.
Definition: GenderCache.php:36
MediaWiki\Languages\LanguageFallback
Definition: LanguageFallback.php:31
ConfiguredReadOnlyMode
A read-only mode service which does not depend on LoadBalancer.
Definition: ConfiguredReadOnlyMode.php:9
CommentStore
Handle database storage of comments such as edit summaries and log reasons.
Definition: CommentStore.php:42
MediaWiki\MediaWikiServices\getExternalStoreAccess
getExternalStoreAccess()
Definition: MediaWikiServices.php:949
MediaWiki\MediaWikiServices\getUserNamePrefixSearch
getUserNamePrefixSearch()
Definition: MediaWikiServices.php:1788
MediaWiki\MediaWikiServices\getBacklinkCacheFactory
getBacklinkCacheFactory()
Definition: MediaWikiServices.php:636
MediaWiki\MediaWikiServices\getUserOptionsManager
getUserOptionsManager()
Definition: MediaWikiServices.php:1812
BagOStuff
Class representing a cache/ephemeral data store.
Definition: BagOStuff.php:86
MediaWiki\Linker\LinkRendererFactory
Factory to create LinkRender objects.
Definition: LinkRendererFactory.php:34
SearchEngineFactory
Factory class for SearchEngine.
Definition: SearchEngineFactory.php:12
MediaWiki\Revision\RevisionFactory
Service for constructing RevisionRecord objects.
Definition: RevisionFactory.php:37
MediaWiki\MediaWikiServices\getTrackingCategories
getTrackingCategories()
Definition: MediaWikiServices.php:1708
MediaWiki\MediaWikiServices\getActorMigration
getActorMigration()
Definition: MediaWikiServices.php:588
MediaWiki\MediaWikiServices\getJsonCodec
getJsonCodec()
Definition: MediaWikiServices.php:1069
ActorMigration
This is not intended to be a long-term part of MediaWiki; it will be deprecated and removed once acto...
Definition: ActorMigration.php:15
MediaWiki\MediaWikiServices\getBlockUtils
getBlockUtils()
Definition: MediaWikiServices.php:716
MediaWiki\MediaWikiServices\getWikiPageFactory
getWikiPageFactory()
Definition: MediaWikiServices.php:1878
MediaWiki\Block\DatabaseBlockStore
Definition: DatabaseBlockStore.php:47
Parser\ParserCacheFactory
Definition: ParserCacheFactory.php:40
MediaWiki\MediaWikiServices\getPermissionManager
getPermissionManager()
Definition: MediaWikiServices.php:1411
MediaWiki\MediaWikiServices\getLanguageFallback
getLanguageFallback()
Definition: MediaWikiServices.php:1093
MediaWiki\MediaWikiServices\getGenderCache
getGenderCache()
Definition: MediaWikiServices.php:973
MediaWiki\CommentFormatter\CommentFormatter
This is the main service interface for converting single-line comments from various DB comment fields...
Definition: CommentFormatter.php:16
MediaWiki\User\ActorStoreFactory
Definition: ActorStoreFactory.php:35
MediaWiki\MediaWikiServices\getEventRelayerGroup
getEventRelayerGroup()
Definition: MediaWikiServices.php:941
MediaWiki\MediaWikiServices\getLockManagerGroupFactory
getLockManagerGroupFactory()
Definition: MediaWikiServices.php:1165
MediaWiki\Languages\LanguageConverterFactory
An interface for creating language converters.
Definition: LanguageConverterFactory.php:46
SiteLookup
Definition: SiteLookup.php:28
MediaWiki\Revision\RevisionLookup
Service for looking up page revisions.
Definition: RevisionLookup.php:38
MediaWiki\MediaWikiServices\getCentralIdLookupFactory
getCentralIdLookupFactory()
Definition: MediaWikiServices.php:757
ExternalStoreAccess
This is the main interface for fetching or inserting objects with ExternalStore.
Definition: ExternalStoreAccess.php:42
MediaHandlerFactory
Class to construct MediaHandler objects.
Definition: MediaHandlerFactory.php:31
MediaWiki\MediaWikiServices\getActionFactory
getActionFactory()
Definition: MediaWikiServices.php:580
MediaWiki\User\TalkPageNotificationManager
Manages user talk page notifications.
Definition: TalkPageNotificationManager.php:35
MediaWiki\MediaWikiServices\getOldRevisionImporter
getOldRevisionImporter()
Definition: MediaWikiServices.php:1299
MediaWiki\MediaWikiServices\getRowCommentFormatter
getRowCommentFormatter()
Definition: MediaWikiServices.php:1539
MediaWiki\MediaWikiServices\getPasswordReset
getPasswordReset()
Definition: MediaWikiServices.php:1395
MediaWiki\Languages\LanguageNameUtils
A service that provides utilities to do with language names and codes.
Definition: LanguageNameUtils.php:43
MediaWiki\MediaWikiServices\getUploadRevisionImporter
getUploadRevisionImporter()
Definition: MediaWikiServices.php:1732
MediaWiki\MediaWikiServices\getContentRenderer
getContentRenderer()
Definition: MediaWikiServices.php:853
MediaWiki\MediaWikiServices\getProxyLookup
getProxyLookup()
Definition: MediaWikiServices.php:1427
MediaWiki\MediaWikiServices\getSkinFactory
getSkinFactory()
Definition: MediaWikiServices.php:1612
SiteStore
Definition: SiteStore.php:29
MediaWiki\MediaWikiServices\failIfResetNotAllowed
static failIfResetNotAllowed( $method)
Convenience method that throws an exception unless it is called during a phase in which resetting of ...
Definition: MediaWikiServices.php:549
MediaWiki\MediaWikiServices\getUserCache
getUserCache()
Definition: MediaWikiServices.php:1740
MediaWiki\MediaWikiServices\getInstance
static getInstance()
Returns the global default instance of the top level service locator.
Definition: MediaWikiServices.php:264
MediaWiki\MediaWikiServices\getWikiImporterFactory
getWikiImporterFactory()
Definition: MediaWikiServices.php:1870
MediaWiki\MediaWikiServices\getRedirectLookup
getRedirectLookup()
Definition: MediaWikiServices.php:1443
MediaWiki\Export\WikiExporterFactory
Factory service for WikiExporter instances.
Definition: WikiExporterFactory.php:35
MediaWiki\MediaWikiServices\getLocalisationCache
getLocalisationCache()
Definition: MediaWikiServices.php:1144
Config
Interface for configuration instances.
Definition: Config.php:30
MediaWiki\User\UserGroupManager
Managers user groups.
Definition: UserGroupManager.php:52
MediaWiki\MediaWikiServices\getJobQueueGroupFactory
getJobQueueGroupFactory()
Definition: MediaWikiServices.php:1053
Page\MergeHistoryFactory
Definition: MergeHistoryFactory.php:30
MediaWiki\MediaWikiServices\getSpecialPageFactory
getSpecialPageFactory()
Definition: MediaWikiServices.php:1644
MediaWiki\MediaWikiServices\getAuthManager
getAuthManager()
Definition: MediaWikiServices.php:628
MediaWiki\MediaWikiServices\getMagicWordFactory
getMagicWordFactory()
Definition: MediaWikiServices.php:1173
MediaWiki\MediaWikiServices\getPerDbNameStatsdDataFactory
getPerDbNameStatsdDataFactory()
Definition: MediaWikiServices.php:1403
wfDeprecatedMsg
wfDeprecatedMsg( $msg, $version=false, $component=false, $callerOffset=2)
Log a deprecation warning with arbitrary message text.
Definition: GlobalFunctions.php:1028
MWException
MediaWiki exception.
Definition: MWException.php:29
MediaWiki\MediaWikiServices\resetServiceForTesting
resetServiceForTesting( $name, $destroy=true)
Resets the given service for testing purposes.
Definition: MediaWikiServices.php:514
MediaWiki\MediaWikiServices\getCryptHKDF
getCryptHKDF()
Definition: MediaWikiServices.php:885
wfDeprecated
wfDeprecated( $function, $version=false, $component=false, $callerOffset=2)
Logs a warning that a deprecated feature was used.
Definition: GlobalFunctions.php:997
MediaWiki\MediaWikiServices\resetGlobalInstance
static resetGlobalInstance(Config $bootstrapConfig=null, $quick='')
Creates a new instance of MediaWikiServices and sets it as the global default instance.
Definition: MediaWikiServices.php:358
MediaWiki\MediaWikiServices\getTempFSFileFactory
getTempFSFileFactory()
Definition: MediaWikiServices.php:1668
MediaWiki\MediaWikiServices\getWatchedItemStore
getWatchedItemStore()
Definition: MediaWikiServices.php:1836
MediaWiki\Storage\PageEditStash
Class for managing stashed edits used by the page updater classes.
Definition: PageEditStash.php:50
DateFormatterFactory
Definition: DateFormatterFactory.php:3
MediaWiki\Watchlist\WatchlistManager
WatchlistManager service.
Definition: WatchlistManager.php:52
MediaWiki\MediaWikiServices\getContentHandlerFactory
getContentHandlerFactory()
Definition: MediaWikiServices.php:821
MediaWiki\MediaWikiServices\getMediaHandlerFactory
getMediaHandlerFactory()
Definition: MediaWikiServices.php:1216
Config\get
get( $name)
Get a configuration variable such as "Sitename" or "UploadMaintenance.".
MediaWiki\MediaWikiServices\getRevertedTagUpdateManager
getRevertedTagUpdateManager()
Definition: MediaWikiServices.php:1483
CryptHKDF
Definition: CryptHKDF.php:33
MediaWiki\MediaWikiServices\getWatchedItemQueryService
getWatchedItemQueryService()
Definition: MediaWikiServices.php:1828
MediaWiki\MediaWikiServices\getUserEditTracker
getUserEditTracker()
Definition: MediaWikiServices.php:1748
MediaWiki\Cache\LinkBatchFactory
Definition: LinkBatchFactory.php:39
MediaWiki\MediaWikiServices\getUserFactory
getUserFactory()
Definition: MediaWikiServices.php:1756
MediaWiki\MediaWikiServices\getMergeHistoryFactory
getMergeHistoryFactory()
Definition: MediaWikiServices.php:1224
MediaWiki\MediaWikiServices\getTitleParser
getTitleParser()
Definition: MediaWikiServices.php:1700
WatchedItemQueryService
Definition: WatchedItemQueryService.php:23
ProxyLookup
Definition: ProxyLookup.php:29
VirtualRESTServiceClient
Virtual HTTP service client loosely styled after a Virtual File System.
Definition: VirtualRESTServiceClient.php:45
MediaWiki\Interwiki\InterwikiLookup
Service interface for looking up Interwiki records.
Definition: InterwikiLookup.php:32
MediaWiki\MediaWikiServices\getPageStore
getPageStore()
Definition: MediaWikiServices.php:1323
MediaWiki\MediaWikiServices\getUndeletePageFactory
getUndeletePageFactory()
Definition: MediaWikiServices.php:1724
MediaWiki\User\UserNamePrefixSearch
Handles searching prefixes of user names.
Definition: UserNamePrefixSearch.php:39
MediaWiki\MediaWikiServices\getFileBackendGroup
getFileBackendGroup()
Definition: MediaWikiServices.php:965
MediaWiki
A helper class for throttling authentication attempts.
MediaWiki\MediaWikiServices\getParserCacheFactory
getParserCacheFactory()
Definition: MediaWikiServices.php:1363
MediaWiki\Block\UnblockUserFactory
Definition: UnblockUserFactory.php:30
MediaWiki\Content\Transform\ContentTransformer
A service to transform content.
Definition: ContentTransformer.php:15
MediaWiki\MediaWikiServices\getMessageFormatterFactory
getMessageFormatterFactory()
Definition: MediaWikiServices.php:1240
Page\WikiPageFactory
Definition: WikiPageFactory.php:19
MediaWiki\MediaWikiServices\newSearchEngine
newSearchEngine()
Definition: MediaWikiServices.php:1547
MediaWiki\MediaWikiServices\getMainConfig
getMainConfig()
Returns the Config object that provides configuration for MediaWiki core.
Definition: MediaWikiServices.php:1184
MediaWiki\MediaWikiServices\getObjectFactory
getObjectFactory()
ObjectFactory is intended for instantiating "handlers" from declarative definitions,...
Definition: MediaWikiServices.php:1291
MediaWiki\MediaWikiServices\getSearchEngineFactory
getSearchEngineFactory()
Definition: MediaWikiServices.php:1564
MediaWiki\Actions\ActionFactory
Definition: ActionFactory.php:45
MediaWiki\MediaWikiServices\getRestrictionStore
getRestrictionStore()
Definition: MediaWikiServices.php:1475
MediaWiki\Storage\BlobStoreFactory
Service for instantiating BlobStores.
Definition: BlobStoreFactory.php:35
GlobalVarConfig
Accesses configuration settings from $GLOBALS.
Definition: GlobalVarConfig.php:29
TitleParser
A title parser service for MediaWiki.
Definition: TitleParser.php:33
MediaWiki\MediaWikiServices\disableStorageBackend
static disableStorageBackend()
Disables all storage layer services.
Definition: MediaWikiServices.php:459
Page\DeletePageFactory
Definition: DeletePageFactory.php:10
MediaWiki\Collation\CollationFactory
Common factory to construct collation classes.
Definition: CollationFactory.php:36
MediaWiki\Content\Renderer\ContentRenderer
A service to render content.
Definition: ContentRenderer.php:15
MediaWiki\MediaWikiServices\getPageStoreFactory
getPageStoreFactory()
Definition: MediaWikiServices.php:1331
MediaWiki\MediaWikiServices\getRevisionStoreFactory
getRevisionStoreFactory()
Definition: MediaWikiServices.php:1523
MediaWiki\MediaWikiServices\getUserIdentityLookup
getUserIdentityLookup()
Definition: MediaWikiServices.php:1780
MediaWiki\MediaWikiServices\getDBLoadBalancerFactory
getDBLoadBalancerFactory()
Definition: MediaWikiServices.php:917
MediaWiki\MediaWikiServices\newInstance
static newInstance(Config $bootstrapConfig, $loadWiring='')
Creates a new MediaWikiServices instance and initializes it according to the given $bootstrapConfig.
Definition: MediaWikiServices.php:432
MediaWiki\MediaWikiServices\getTitleFormatter
getTitleFormatter()
Definition: MediaWikiServices.php:1692
MediaWiki\MediaWikiServices\getLinkBatchFactory
getLinkBatchFactory()
Definition: MediaWikiServices.php:1109
MediaWiki\Tidy\TidyDriverBase
Base class for HTML cleanup utilities.
Definition: TidyDriverBase.php:8
MediaWiki\MediaWikiServices\getHttpRequestFactory
getHttpRequestFactory()
Definition: MediaWikiServices.php:1029
MediaWiki\MediaWikiServices\getActorStore
getActorStore()
Definition: MediaWikiServices.php:604
MediaWiki\MediaWikiServices\getBlockActionInfo
getBlockActionInfo()
Definition: MediaWikiServices.php:668
MediaWiki\MediaWikiServices\getCriticalSectionProvider
getCriticalSectionProvider()
Definition: MediaWikiServices.php:877
MediaWiki\MediaWikiServices\getRevisionFactory
getRevisionFactory()
Definition: MediaWikiServices.php:1491
MediaWiki\MediaWikiServices\getParserCache
getParserCache()
Definition: MediaWikiServices.php:1355
Page\UndeletePageFactory
Definition: UndeletePageFactory.php:10
MediaWiki\MediaWikiServices\salvage
salvage(self $other)
@noinspection PhpDocSignatureInspection
Definition: MediaWikiServices.php:396
MediaWiki\MediaWikiServices\getRedirectStore
getRedirectStore()
Definition: MediaWikiServices.php:1451
MediaWiki\FileBackend\FSFile\TempFSFileFactory
Definition: TempFSFileFactory.php:10
MediaWiki\MediaWikiServices\getPreferencesFactory
getPreferencesFactory()
Definition: MediaWikiServices.php:1419
MediaWiki\MediaWikiServices\__construct
__construct(Config $config)
Definition: MediaWikiServices.php:565
MediaWiki\MediaWikiServices\getContentModelChangeFactory
getContentModelChangeFactory()
Definition: MediaWikiServices.php:837
UserNamePrefixSearch
Handles searching prefixes of user names.
Definition: UserNamePrefixSearch_deprecated.php:37
Page\RedirectStore
Definition: RedirectStore.php:31
MediaWiki\User\UserGroupManagerFactory
Factory service for UserGroupManager instances.
Definition: UserGroupManagerFactory.php:37
MediaWiki\User\UserIdentityLookup
Definition: UserIdentityLookup.php:33
ExternalStoreFactory
Definition: ExternalStoreFactory.php:14
MediaWiki\Revision\RevisionRenderer
The RevisionRenderer service provides access to rendered output for revisions.
Definition: RevisionRenderer.php:45
MediaWiki\Permissions\PermissionManager
A service class for checking permissions To obtain an instance, use MediaWikiServices::getInstance()-...
Definition: PermissionManager.php:52
MediaWiki\MediaWikiServices\getPasswordFactory
getPasswordFactory()
Definition: MediaWikiServices.php:1387
ParserFactory
Definition: ParserFactory.php:37
MediaWiki\MediaWikiServices\getService
getService( $name)
Definition: MediaWikiServices.php:286
MediaWiki\MediaWikiServices\getPageEditStash
getPageEditStash()
Definition: MediaWikiServices.php:1307
MediaWiki\MediaWikiServices\getWikiRevisionOldRevisionImporterNoUpdates
getWikiRevisionOldRevisionImporterNoUpdates()
Definition: MediaWikiServices.php:1894
MediaWiki\User\BotPasswordStore
Definition: BotPasswordStore.php:44
MediaWiki\MediaWikiServices\getHtmlCacheUpdater
getHtmlCacheUpdater()
Definition: MediaWikiServices.php:1021
MediaWiki\Content\IContentHandlerFactory
Definition: IContentHandlerFactory.php:10
MediaWiki\MediaWikiServices\getVirtualRESTServiceClient
getVirtualRESTServiceClient()
Definition: MediaWikiServices.php:1820
SkinFactory
Factory class to create Skin objects.
Definition: SkinFactory.php:31
MediaWiki\EditPage\SpamChecker
Service to check if text (either content or a summary) qualifies as spam.
Definition: SpamChecker.php:14
MediaWiki\MediaWikiServices\getBadFileLookup
getBadFileLookup()
Definition: MediaWikiServices.php:644
MediaWiki\MediaWikiServices\getConfigFactory
getConfigFactory()
Definition: MediaWikiServices.php:797
MediaWiki\JobQueue\JobQueueGroupFactory
Class to construct JobQueueGroups.
Definition: JobQueueGroupFactory.php:37
MediaWiki\Shell\CommandFactory
Factory facilitating dependency injection for Command.
Definition: CommandFactory.php:35
MediaWiki\MediaWikiServices\getWikiRevisionUploadImporter
getWikiRevisionUploadImporter()
Definition: MediaWikiServices.php:1902
MediaWiki\Preferences\PreferencesFactory
A PreferencesFactory is a MediaWiki service that provides the definitions of preferences for a given ...
Definition: PreferencesFactory.php:54
MediaWiki\MediaWikiServices\getTidy
getTidy()
Definition: MediaWikiServices.php:1676
WANObjectCache
Multi-datacenter aware caching interface.
Definition: WANObjectCache.php:131
MediaWiki\MediaWikiServices\getUserNameUtils
getUserNameUtils()
Definition: MediaWikiServices.php:1796
MediaWiki\MediaWikiServices\getUserGroupManagerFactory
getUserGroupManagerFactory()
Definition: MediaWikiServices.php:1772
HtmlCacheUpdater
Class to invalidate the CDN and HTMLFileCache entries associated with URLs/titles.
Definition: HtmlCacheUpdater.php:32
MediaWiki\MediaWikiServices\getRevisionRenderer
getRevisionRenderer()
Definition: MediaWikiServices.php:1507
MediaWiki\MediaWikiServices\getUserOptionsLookup
getUserOptionsLookup()
Definition: MediaWikiServices.php:1804
MediaWiki\MediaWikiServices\getCommentFormatter
getCommentFormatter()
Definition: MediaWikiServices.php:781
MediaWiki\User\CentralId\CentralIdLookupFactory
Definition: CentralIdLookupFactory.php:34
MediaWiki\MediaWikiServices\getContributionsLookup
getContributionsLookup()
Definition: MediaWikiServices.php:869
LocalisationCache
Class for caching the contents of localisation files, Messages*.php and *.i18n.php.
Definition: LocalisationCache.php:43
MediaWiki\Config\ConfigRepository
Object which holds currently registered configuration options.
Definition: ConfigRepository.php:33
MediaWiki\MediaWikiServices\hasInstance
static hasInstance()
Returns true if an instance has already been initialized.
Definition: MediaWikiServices.php:244
MediaWiki\Storage\NameTableStore
Definition: NameTableStore.php:36
MediaWiki\Block\BlockActionInfo
Defines the actions that can be blocked by a partial block.
Definition: BlockActionInfo.php:40
MediaWiki\MediaWikiServices\getExternalStoreFactory
getExternalStoreFactory()
Definition: MediaWikiServices.php:957
Parser
PHP Parser - Processes wiki markup (which uses a more user-friendly syntax, such as "[[link]]" for ma...
Definition: Parser.php:91
MediaWiki\Revision\RevisionStoreFactory
Factory service for RevisionStore instances.
Definition: RevisionStoreFactory.php:56
MediaWiki\Shell\ShellboxClientFactory
This is a service which provides a configured client to access a remote Shellbox installation.
Definition: ShellboxClientFactory.php:20
MediaWiki\User\UserOptionsLookup
Provides access to user options.
Definition: UserOptionsLookup.php:29
MediaWiki\MediaWikiServices\getDateFormatterFactory
getDateFormatterFactory()
Definition: MediaWikiServices.php:901
Page\MovePageFactory
Definition: MovePageFactory.php:30
SearchEngine
Contain a class for special pages.
Definition: SearchEngine.php:37
MediaWiki\MediaWikiServices\getTitleFactory
getTitleFactory()
Definition: MediaWikiServices.php:1684
MediaWiki\Auth\AuthManager
This serves as the entry point to the authentication system.
Definition: AuthManager.php:102
MediaWiki\Storage\BlobStore
Service for loading and storing data blobs.
Definition: BlobStore.php:35
MediaWiki\Revision\ContributionsLookup
Definition: ContributionsLookup.php:24
MediaWiki\User\UserOptionsManager
A service class to control user options.
Definition: UserOptionsManager.php:43
TrackingCategories
This class performs some operations related to tracking categories, such as creating a list of all su...
Definition: TrackingCategories.php:32
MediaWiki\MediaWikiServices\getMainWANObjectCache
getMainWANObjectCache()
Returns the main WAN cache, yielding EmptyBagOStuff if there is none.
Definition: MediaWikiServices.php:1208
MediaWiki\MediaWikiServices\getMimeAnalyzer
getMimeAnalyzer()
Definition: MediaWikiServices.php:1256
IBufferingStatsdDataFactory
MediaWiki adaptation of StatsdDataFactory that provides buffering functionality.
Definition: IBufferingStatsdDataFactory.php:13
MediaWiki\MediaWikiServices\getSiteStore
getSiteStore()
Definition: MediaWikiServices.php:1604
MediaWiki\MediaWikiServices\getBlobStore
getBlobStore()
Definition: MediaWikiServices.php:652
MediaWiki\Preferences\SignatureValidatorFactory
Definition: SignatureValidatorFactory.php:35
MediaWiki\MediaWikiServices\getMetricsFactory
getMetricsFactory()
Definition: MediaWikiServices.php:1248
MediaWiki\MediaWikiServices\getBotPasswordStore
getBotPasswordStore()
Definition: MediaWikiServices.php:741
Wikimedia\Message\IMessageFormatterFactory
A simple factory providing a message formatter for a given language code.
Definition: IMessageFormatterFactory.php:10
MediaWiki\MediaWikiServices\getUnblockUserFactory
getUnblockUserFactory()
Definition: MediaWikiServices.php:1716
MediaWiki\MediaWikiServices\getLocalServerObjectCache
getLocalServerObjectCache()
Returns the main server-local cache, yielding EmptyBagOStuff if there is none.
Definition: MediaWikiServices.php:1157
MediaWiki\MediaWikiServices\getMovePageFactory
getMovePageFactory()
Definition: MediaWikiServices.php:1264
ResourceLoader
ResourceLoader is a loading system for JavaScript and CSS resources.
Definition: ResourceLoader.php:59
OldRevisionImporter
Definition: OldRevisionImporter.php:6
MediaWiki\MediaWikiServices\getBlobStoreFactory
getBlobStoreFactory()
Definition: MediaWikiServices.php:660
MediaWiki\CommentFormatter\RowCommentFormatter
This is basically a CommentFormatter with a CommentStore dependency, allowing it to retrieve comment ...
Definition: RowCommentFormatter.php:15
MediaWiki\MediaWikiServices\getConfiguredReadOnlyMode
getConfiguredReadOnlyMode()
Definition: MediaWikiServices.php:813
MediaWiki\MediaWikiServices\getLanguageFactory
getLanguageFactory()
Definition: MediaWikiServices.php:1085
MediaWiki\MediaWikiServices\getRevisionStore
getRevisionStore()
Definition: MediaWikiServices.php:1515
MediaWiki\MediaWikiServices\getParserOutputAccess
getParserOutputAccess()
Definition: MediaWikiServices.php:1379
MediaWiki\User\UserEditTracker
Track info about user edit counts and timings.
Definition: UserEditTracker.php:21
MediaWiki\MediaWikiServices\getWikiRevisionOldRevisionImporter
getWikiRevisionOldRevisionImporter()
Definition: MediaWikiServices.php:1886
PageProps
Gives access to properties of a page.
Definition: PageProps.php:33
MediaWiki\MediaWikiServices\allowGlobalInstance
static allowGlobalInstance()
Allows a global service container instance to exist.
Definition: MediaWikiServices.php:227
MediaWiki\MediaWikiServices\getGroupPermissionsLookup
getGroupPermissionsLookup()
Definition: MediaWikiServices.php:1005
MediaWiki\User\UserNameUtils
UserNameUtils service.
Definition: UserNameUtils.php:42
CentralIdLookup
The CentralIdLookup service allows for connecting local users with cluster-wide IDs.
Definition: CentralIdLookup.php:35
MediaWiki\MediaWikiServices\getParser
getParser()
Definition: MediaWikiServices.php:1347
MediaWiki\MediaWikiServices\getLanguageNameUtils
getLanguageNameUtils()
Definition: MediaWikiServices.php:1101
MediaWiki\MediaWikiServices\getDatabaseBlockStore
getDatabaseBlockStore()
Definition: MediaWikiServices.php:893
MediaWiki\MediaWikiServices\getNamespaceInfo
getNamespaceInfo()
Definition: MediaWikiServices.php:1272
MediaWiki\MediaWikiServices\resetChildProcessServices
static resetChildProcessServices()
Resets any services that may have become stale after a child process returns from after pcntl_fork().
Definition: MediaWikiServices.php:483
MediaWiki\MediaWikiServices\getSlotRoleRegistry
getSlotRoleRegistry()
Definition: MediaWikiServices.php:1620
TitleFormatter
A title formatter service for MediaWiki.
Definition: TitleFormatter.php:35
MediaWiki\MediaWikiServices\getActorNormalization
getActorNormalization()
Definition: MediaWikiServices.php:596
Wikimedia\Rdbms\LBFactory
An interface for generating database load balancers.
Definition: LBFactory.php:42
MediaWiki\MediaWikiServices\getContentLanguage
getContentLanguage()
Definition: MediaWikiServices.php:829
TitleFactory
Creates Title objects.
Definition: TitleFactory.php:35
MediaWiki\MediaWikiServices\getConfigRepository
getConfigRepository()
Definition: MediaWikiServices.php:805
Page\ContentModelChangeFactory
Definition: ContentModelChangeFactory.php:32
MediaWiki\Mail\IEmailer
Interface for sending emails.
Definition: IEmailer.php:34
MediaWiki\Cache\BacklinkCacheFactory
Definition: BacklinkCacheFactory.php:33
MediaWiki\MediaWikiServices\getGrantsInfo
getGrantsInfo()
Definition: MediaWikiServices.php:989
RepoGroup
Prioritized list of file repositories.
Definition: RepoGroup.php:32
ParserCache
Cache for ParserOutput objects corresponding to the latest page revisions.
Definition: ParserCache.php:63
ConfigFactory
Factory class to create Config objects.
Definition: ConfigFactory.php:33
MediaWiki\Storage\PageUpdaterFactory
A factory for PageUpdater instances.
Definition: PageUpdaterFactory.php:56
MediaWiki\Storage\NameTableStoreFactory
Definition: NameTableStoreFactory.php:26
SearchEngineConfig
Configuration handling class for SearchEngine.
Definition: SearchEngineConfig.php:12
MediaWiki\MediaWikiServices\getDeletePageFactory
getDeletePageFactory()
Definition: MediaWikiServices.php:925
MediaWiki\MediaWikiServices\getPageProps
getPageProps()
Definition: MediaWikiServices.php:1315
MediaWiki\Revision\SlotRoleRegistry
A registry service for SlotRoleHandlers, used to define which slot roles are available on which page.
Definition: SlotRoleRegistry.php:48
MediaWiki\MediaWikiServices\getEmailer
getEmailer()
Definition: MediaWikiServices.php:933
MediaWiki\HookContainer\HookContainer
HookContainer class.
Definition: HookContainer.php:45
PasswordFactory
Factory class for creating and checking Password objects.
Definition: PasswordFactory.php:30
NamespaceInfo
This is a utility class for dealing with namespaces that encodes all the "magic" behaviors of them ba...
Definition: NamespaceInfo.php:35
MediaWiki\HookContainer\HookRunner
This class provides an implementation of the core hook interfaces, forwarding hook calls to HookConta...
Definition: HookRunner.php:557
MediaWiki\MediaWikiServices\getLinkRendererFactory
getLinkRendererFactory()
Definition: MediaWikiServices.php:1136
MediaWiki\MediaWikiServices\getBlockUserFactory
getBlockUserFactory()
Definition: MediaWikiServices.php:708
Page\RedirectLookup
Interface to handle redirects for a given page like getting the redirect target of an editable wiki p...
Definition: RedirectLookup.php:34
WikiImporterFactory
Factory service for WikiImporter instances.
Definition: WikiImporterFactory.php:33
MediaWiki\MediaWikiServices\getUserGroupManager
getUserGroupManager()
Definition: MediaWikiServices.php:1764
MediaWiki\Json\JsonCodec
Definition: JsonCodec.php:36
MediaWiki\MediaWikiServices\getGrantsLocalization
getGrantsLocalization()
Definition: MediaWikiServices.php:997
JobRunner
Job queue runner utility methods.
Definition: JobRunner.php:41
MediaWiki\MediaWikiServices\getTalkPageNotificationManager
getTalkPageNotificationManager()
Definition: MediaWikiServices.php:1660
MediaWiki\MediaWikiServices\getLinkRenderer
getLinkRenderer()
LinkRenderer instance that can be used if no custom options are needed.
Definition: MediaWikiServices.php:1128
MediaWiki\MediaWikiServices\getSignatureValidatorFactory
getSignatureValidatorFactory()
Definition: MediaWikiServices.php:1588
MediaWiki\Permissions\RestrictionStore
Class RestrictionStore.
Definition: RestrictionStore.php:28
MediaWiki\MediaWikiServices\getHookContainer
getHookContainer()
Definition: MediaWikiServices.php:1013
MediaWiki\MediaWikiServices\getWatchlistNotificationManager
getWatchlistNotificationManager()
Definition: MediaWikiServices.php:1845
MediaWiki\MediaWikiServices\getMainObjectStash
getMainObjectStash()
Returns the main object stash, yielding EmptyBagOStuff if there is none.
Definition: MediaWikiServices.php:1196
Page\PageStore
Definition: PageStore.php:28
WatchedItemStoreInterface
Definition: WatchedItemStoreInterface.php:31
MessageCache
Cache of messages that are defined by MediaWiki namespace pages or by hooks.
Definition: MessageCache.php:52
MediaWiki\MediaWikiServices\getWikiExporterFactory
getWikiExporterFactory()
Definition: MediaWikiServices.php:1862
MediaWiki\Revision\ArchivedRevisionLookup
Definition: ArchivedRevisionLookup.php:31
MediaWiki\MediaWikiServices\getLinkCache
getLinkCache()
Definition: MediaWikiServices.php:1117
MediaWiki\MediaWikiServices\getShellboxClientFactory
getShellboxClientFactory()
Definition: MediaWikiServices.php:1572
MediaWiki\Permissions\GrantsInfo
Users can authorize applications to use their account via OAuth.
Definition: GrantsInfo.php:32
Page\PageStoreFactory
Definition: PageStoreFactory.php:16
PasswordReset
Helper class for the password reset functionality shared by the web UI and the API.
Definition: PasswordReset.php:43
MediaWiki\MediaWikiServices\getReadOnlyMode
getReadOnlyMode()
Definition: MediaWikiServices.php:1435
MediaWiki\User\UserFactory
Creates User objects.
Definition: UserFactory.php:41
MediaWiki\Permissions\GrantsLocalization
This separate service is needed because the ::getGrantsLink method requires a LinkRenderer and if we ...
Definition: GrantsLocalization.php:37
Language
Internationalisation code See https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation for more...
Definition: Language.php:42
Wikimedia\Rdbms\ILoadBalancer
Database cluster connection, tracking, load balancing, and transaction manager interface.
Definition: ILoadBalancer.php:81
MediaWiki\MediaWikiServices\forceGlobalInstance
static forceGlobalInstance(MediaWikiServices $services)
Replaces the global MediaWikiServices instance.
Definition: MediaWikiServices.php:308
MediaWiki\User\ActorStore
Definition: ActorStore.php:43
MediaWiki\Storage\RevertedTagUpdateManager
Class for managing delayed RevertedTagUpdateJob waiting for user approval.
Definition: RevertedTagUpdateManager.php:36
JobQueueGroup
Class to handle enqueueing of background jobs.
Definition: JobQueueGroup.php:32
MediaWiki\Block\BlockRestrictionStore
Definition: BlockRestrictionStore.php:35
MediaWiki\MediaWikiServices\getStatsdDataFactory
getStatsdDataFactory()
Definition: MediaWikiServices.php:1652
MediaWiki\User\ActorNormalization
Service for dealing with the actor table.
Definition: ActorNormalization.php:32
MediaWiki\MediaWikiServices\getNameTableStoreFactory
getNameTableStoreFactory()
Definition: MediaWikiServices.php:1280
MediaWiki\MediaWikiServices\getRepoGroup
getRepoGroup()
Definition: MediaWikiServices.php:1459