Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup Class Reference

An EntityTitleStoreLookup that guarantees to return the titles of pages that actually store the entities, and does dispatching based on the entity type. More...

+ Inheritance diagram for Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup:
+ Collaboration diagram for Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup:

Public Member Functions

 __construct (array $callbacks, EntityTitleStoreLookup $defaultLookup)
 
 getTitleForId (EntityId $id)
 
 getTitlesForIds (array $ids)
 Returns an array of Titles for the given entity ids, indexed by the id serialization.If an entity does not exist, the array element for the relevant id serialization will be null
Parameters
EntityId[]$ids
Returns
(Title|null)[]

 

Private Member Functions

 getIdsByType (array $ids)
 

Private Attributes

 $defaultLookup
 
 $serviceDispatcher
 

Detailed Description

An EntityTitleStoreLookup that guarantees to return the titles of pages that actually store the entities, and does dispatching based on the entity type.

Author
Thiemo Kreuz

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::__construct ( array $callbacks,
EntityTitleStoreLookup $defaultLookup )
Parameters
callable[]$callbacksindexed by entity type
EntityTitleStoreLookup$defaultLookup

Member Function Documentation

◆ getIdsByType()

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::getIdsByType ( array $ids)
private

◆ getTitleForId()

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::getTitleForId ( EntityId $id)
Parameters
EntityId$id
Returns
Title|null

Implements Wikibase\Lib\Store\EntityTitleLookup.

◆ getTitlesForIds()

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::getTitlesForIds ( array $ids)

Returns an array of Titles for the given entity ids, indexed by the id serialization.If an entity does not exist, the array element for the relevant id serialization will be null

Parameters
EntityId[]$ids
Returns
(Title|null)[]

Implements Wikibase\Lib\Store\EntityTitleLookup.

Member Data Documentation

◆ $defaultLookup

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::$defaultLookup
private

◆ $serviceDispatcher

Wikibase\Repo\Store\TypeDispatchingEntityTitleStoreLookup::$serviceDispatcher
private

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