MediaWiki REL1_40
|
Inherited by MediaWiki\Linker\LinkTargetStore.
Public Member Functions | |
acquireLinkTargetId (LinkTarget $linkTarget, IDatabase $dbw) | |
Attempt to assign an link target ID to the given $linkTarget. | |
getLinkTargetById (int $linkTargetId) | |
Find an link target by $id. | |
getLinkTargetId (LinkTarget $linkTarget) | |
Return link target id if exists. | |
newLinkTargetFromRow (stdClass $row) | |
Instantiate a new LinkTarget object based on a $row from the linktarget table. | |
Definition at line 29 of file LinkTargetLookup.php.
MediaWiki\Linker\LinkTargetLookup::acquireLinkTargetId | ( | LinkTarget | $linkTarget, |
IDatabase | $dbw ) |
Attempt to assign an link target ID to the given $linkTarget.
If it is already assigned, return the existing ID.
LinkTarget | $linkTarget | |
IDatabase | $dbw | The database connection to acquire the ID from. |
RuntimeException | if no linktarget ID has been assigned to this $linkTarget |
Implemented in MediaWiki\Linker\LinkTargetStore.
MediaWiki\Linker\LinkTargetLookup::getLinkTargetById | ( | int | $linkTargetId | ) |
Find an link target by $id.
int | $linkTargetId |
Implemented in MediaWiki\Linker\LinkTargetStore.
MediaWiki\Linker\LinkTargetLookup::getLinkTargetId | ( | LinkTarget | $linkTarget | ) |
Return link target id if exists.
LinkTarget | $linkTarget |
Implemented in MediaWiki\Linker\LinkTargetStore.
MediaWiki\Linker\LinkTargetLookup::newLinkTargetFromRow | ( | stdClass | $row | ) |
Instantiate a new LinkTarget object based on a $row from the linktarget table.
Use this method when a linktarget row was already fetched from the DB via a join. This method just constructs a new instance and does not try fetching missing values from the DB again.
stdClass | $row | with the following fields:
|
Implemented in MediaWiki\Linker\LinkTargetStore.