Wikibase
MediaWiki Wikibase extension
Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup Class Reference

A class for getting namespaces for federated properties one time per request. More...

Public Member Functions

 __construct (GenericActionApiClient $api, array $contentModelMapping)
 
 getNamespaceNameForEntityType (string $entityType)
 

Private Member Functions

 fetchNamespaces ()
 
 getNamespaceNameForContentModel (string $entityContentModel)
 

Private Attributes

 $namespaces
 
 $api
 
 $contentModelMapping
 

Detailed Description

A class for getting namespaces for federated properties one time per request.

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::__construct ( GenericActionApiClient  $api,
array  $contentModelMapping 
)

Member Function Documentation

◆ fetchNamespaces()

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::fetchNamespaces ( )
private

◆ getNamespaceNameForContentModel()

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::getNamespaceNameForContentModel ( string  $entityContentModel)
private

◆ getNamespaceNameForEntityType()

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::getNamespaceNameForEntityType ( string  $entityType)
Parameters
string$entityType
Returns
string|null Namespace name or null if no namespace is found for the entity

Member Data Documentation

◆ $api

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::$api
private

◆ $contentModelMapping

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::$contentModelMapping
private

◆ $namespaces

Wikibase\Repo\FederatedProperties\ApiEntityNamespaceInfoLookup::$namespaces
private

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