Wikibase
MediaWiki Wikibase extension
Wikibase\Repo\Content\ContentHandlerEntityTitleLookup Class Reference
+ Inheritance diagram for Wikibase\Repo\Content\ContentHandlerEntityTitleLookup:
+ Collaboration diagram for Wikibase\Repo\Content\ContentHandlerEntityTitleLookup:

Public Member Functions

 __construct (EntityContentFactory $entityContentFactory, EntitySourceDefinitions $entitySourceDefinitions, DatabaseEntitySource $localEntitySource, InterwikiLookup $interwikiLookup=null)
 
 getTitleForId (EntityId $id)
 Returns the Title object for the item with provided id. More...
 
 getTitlesForIds (array $ids)
 Returns Title objects for the entities with provided ids. More...
 

Private Member Functions

 getTitleForFederatedId (EntityId $id)
 If the EntityId is federated, return a Title for it. More...
 
 entityNotFromLocalEntitySource (EntityId $id)
 

Private Attributes

 $titleForIdCache
 
 $entityContentFactory
 
 $entitySourceDefinitions
 
 $localEntitySource
 
 $interwikiLookup
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::__construct ( EntityContentFactory  $entityContentFactory,
EntitySourceDefinitions  $entitySourceDefinitions,
DatabaseEntitySource  $localEntitySource,
InterwikiLookup  $interwikiLookup = null 
)

Member Function Documentation

◆ entityNotFromLocalEntitySource()

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::entityNotFromLocalEntitySource ( EntityId  $id)
private

◆ getTitleForFederatedId()

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::getTitleForFederatedId ( EntityId  $id)
private

If the EntityId is federated, return a Title for it.

Otherwise return null

◆ getTitleForId()

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::getTitleForId ( EntityId  $id)

Returns the Title object for the item with provided id.

Exceptions
MWException
OutOfBoundsException
InvalidArgumentException

Implements Wikibase\Lib\Store\EntityTitleLookup.

◆ getTitlesForIds()

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::getTitlesForIds ( array  $ids)

Returns Title objects for the entities with provided ids.

Parameters
EntityId[]$ids
Exceptions
MWException
OutOfBoundsException
InvalidArgumentException
Returns
Title[]

Implements Wikibase\Lib\Store\EntityTitleLookup.

Member Data Documentation

◆ $entityContentFactory

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::$entityContentFactory
private

◆ $entitySourceDefinitions

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::$entitySourceDefinitions
private

◆ $interwikiLookup

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::$interwikiLookup
private

◆ $localEntitySource

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::$localEntitySource
private

◆ $titleForIdCache

Wikibase\Repo\Content\ContentHandlerEntityTitleLookup::$titleForIdCache
private

The documentation for this class was generated from the following file: