Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup Class Reference

EntityLookup that checks entities have been loaded through it and throws an exception if the accessing to that entity type is disabled. More...

+ Inheritance diagram for Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup:
+ Collaboration diagram for Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup:

Public Member Functions

 __construct (EntityLookup $entityLookup, array $disabledEntityTypes)
 
 getEntity (EntityId $entityId)
 
 hasEntity (EntityId $entityId)
 

Private Attributes

 $entityLookup
 
 $disabledEntityTypes = []
 

Detailed Description

EntityLookup that checks entities have been loaded through it and throws an exception if the accessing to that entity type is disabled.

Since
3.9
Author
Amir Sarabadani

Constructor & Destructor Documentation

◆ __construct()

Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup::__construct ( EntityLookup $entityLookup,
array $disabledEntityTypes )
Parameters
EntityLookup$entityLookup
string[]$disabledEntityTypes

Member Function Documentation

◆ getEntity()

Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup::getEntity ( EntityId $entityId)
See also
EntityLookup::getEntity
Parameters
EntityId$entityId
Exceptions
EntityLookupException
Returns
EntityDocument

Implements Wikibase\DataModel\Services\Lookup\EntityLookup.

◆ hasEntity()

Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup::hasEntity ( EntityId $entityId)
See also
EntityLookup::hasEntity
Parameters
EntityId$entityId
Returns
bool
Exceptions
EntityLookupException

Implements Wikibase\DataModel\Services\Lookup\EntityLookup.

Member Data Documentation

◆ $disabledEntityTypes

Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup::$disabledEntityTypes = []
private

◆ $entityLookup

Wikibase\DataModel\Services\Lookup\DisabledEntityTypesEntityLookup::$entityLookup
private

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