MediaWiki
master
ActorMigration.php
Go to the documentation of this file.
1
<?php
2
3
namespace
MediaWiki\User
;
4
5
use
MediaWiki\MediaWikiServices
;
6
use
Wikimedia\Rdbms\IDatabase
;
7
use
Wikimedia\Rdbms\IReadableDatabase
;
8
19
class
ActorMigration
extends
ActorMigrationBase
{
20
25
public
const
FIELD_INFOS
= [
26
// Deprecated since 1.39
27
'rev_user'
=> [],
28
];
29
34
public
static
function
newMigration
() {
35
return
MediaWikiServices::getInstance
()->getActorMigration();
36
}
37
42
public
static
function
newMigrationForImport
() {
43
$migration =
new
self
(
44
MediaWikiServices::getInstance
()->getActorStoreFactory()
45
);
46
$migration->setForImport(
true
);
47
return
$migration;
48
}
49
55
public
function
__construct
(
ActorStoreFactory
$actorStoreFactory
) {
56
parent::__construct(
57
self::FIELD_INFOS,
58
SCHEMA_COMPAT_NEW
,
59
$actorStoreFactory
60
);
61
}
62
68
public
function
getJoin
( $key ) {
69
return
parent::getJoin( $key );
70
}
71
79
public
function
getWhere
(
IReadableDatabase
$db, $key, $users, $useId =
true
) {
80
return
parent::getWhere( $db, $key, $users, $useId );
81
}
82
89
public
function
getInsertValues
(
IDatabase
$dbw, $key,
UserIdentity
$user ) {
90
return
parent::getInsertValues( $dbw, $key, $user );
91
}
92
93
}
SCHEMA_COMPAT_NEW
const SCHEMA_COMPAT_NEW
Definition
Defines.php:307
MediaWiki\MediaWikiServices
Service locator for MediaWiki core services.
Definition
MediaWikiServices.php:257
MediaWiki\MediaWikiServices\getInstance
static getInstance()
Returns the global default instance of the top level service locator.
Definition
MediaWikiServices.php:345
MediaWiki\User\ActorMigrationBase
Help migrate core and extension code with the actor table migration.
Definition
ActorMigrationBase.php:22
MediaWiki\User\ActorMigrationBase\$actorStoreFactory
ActorStoreFactory $actorStoreFactory
Definition
ActorMigrationBase.php:32
MediaWiki\User\ActorMigration
This is not intended to be a long-term part of MediaWiki; it will be deprecated and removed once acto...
Definition
ActorMigration.php:19
MediaWiki\User\ActorMigration\FIELD_INFOS
const FIELD_INFOS
Field information.
Definition
ActorMigration.php:25
MediaWiki\User\ActorMigration\newMigrationForImport
static newMigrationForImport()
Static constructor.
Definition
ActorMigration.php:42
MediaWiki\User\ActorMigration\getWhere
getWhere(IReadableDatabase $db, $key, $users, $useId=true)
Get WHERE condition for the actor.array With four keys:tables: (string[]) to include in the $table to...
Definition
ActorMigration.php:79
MediaWiki\User\ActorMigration\newMigration
static newMigration()
Static constructor.
Definition
ActorMigration.php:34
MediaWiki\User\ActorMigration\getJoin
getJoin( $key)
Get SELECT fields and joins for the actor key.array[] With three keys:tables: (string[]) to include i...
Definition
ActorMigration.php:68
MediaWiki\User\ActorMigration\getInsertValues
getInsertValues(IDatabase $dbw, $key, UserIdentity $user)
Get UPDATE fields for the actor.array to merge into $values to IDatabase->update() or $a to IDatabase...
Definition
ActorMigration.php:89
MediaWiki\User\ActorMigration\__construct
__construct(ActorStoreFactory $actorStoreFactory)
Definition
ActorMigration.php:55
MediaWiki\User\ActorStoreFactory
ActorStore factory for any wiki domain.
Definition
ActorStoreFactory.php:24
MediaWiki\User\UserIdentity
Interface for objects representing user identity.
Definition
UserIdentity.php:24
Wikimedia\Rdbms\IDatabase
Interface to a relational database.
Definition
IDatabase.php:31
Wikimedia\Rdbms\IReadableDatabase
A database connection without write operations.
Definition
IReadableDatabase.php:20
MediaWiki\User
Definition
ActorCache.php:7
includes
User
ActorMigration.php
Generated on Sat Jan 17 2026 22:52:05 for MediaWiki by
1.10.0