Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\DataAccess\MultipleEntitySourceServices Class Reference

TODO this has been introduced into data-access with a couple of points that still bind to wikibase lib: More...

+ Inheritance diagram for Wikibase\DataAccess\MultipleEntitySourceServices:
+ Collaboration diagram for Wikibase\DataAccess\MultipleEntitySourceServices:

Public Member Functions

 __construct (EntitySourceDefinitions $entitySourceDefinitions, GenericServices $genericServices, array $singleSourceServices)
 
 getPropertyInfoLookup ()
 
 getEntityStoreWatcher ()
 Returns a service that can be registered as a watcher to changes to entity data.
 
 entityUpdated (EntityRevision $entityRevision)
 Called when an entity is updated, created, or replaces a redirect.
 
 redirectUpdated (EntityRedirect $entityRedirect, $revisionId)
 Called when a redirect is updated, created, or replaces an entity.
 
 entityDeleted (EntityId $entityId)
 Called when an entity or redirect is deleted.
 
 getEntityNamespaceLookup ()
 
 getFullEntitySerializer ()
 Returns the entity serializer instance that generates the full (expanded) serialization.
 
 getCompactEntitySerializer ()
 Returns the entity serializer instance that generates the most compact serialization.
 
 getStorageEntitySerializer ()
 Returns the entity serializer that generates serialization that is used in the storage layer.
 
 getBaseDataModelSerializerFactory ()
 
 getCompactBaseDataModelSerializerFactory ()
 
 getLanguageFallbackChainFactory ()
 
 getStringNormalizer ()
 
 getTermBuffer ()
 
- Public Member Functions inherited from Wikibase\DataAccess\WikibaseServices
 getPrefetchingTermLookup ()
 
- Public Member Functions inherited from Wikibase\DataAccess\DataAccessServices
 getEntityPrefetcher ()
 
 getEntityRevisionLookup ()
 
 getTermSearchInteractorFactory ()
 

Private Attributes

 $entitySourceDefinitions
 
 $genericServices
 
 $singleSourceServices
 
 $entityRevisionLookup = null
 
 $termSearchInteractorFactory = null
 
 $prefetchingTermLookup = null
 
 $entityPrefetcher = null
 

Detailed Description

TODO this has been introduced into data-access with a couple of points that still bind to wikibase lib:

  • Wikibase\Lib\Store\EntityRevision; (could already be moved to data-access)
  • Wikibase\Lib\Store\EntityStoreWatcher; (only binds to EntityRevision within lib)

Constructor & Destructor Documentation

◆ __construct()

Wikibase\DataAccess\MultipleEntitySourceServices::__construct ( EntitySourceDefinitions  $entitySourceDefinitions,
GenericServices  $genericServices,
array  $singleSourceServices 
)
Parameters
EntitySourceDefinitions$entitySourceDefinitions
GenericServices$genericServices
SingleEntitySourceServices[]$singleSourceServicesindexed by source name

Member Function Documentation

◆ entityDeleted()

Wikibase\DataAccess\MultipleEntitySourceServices::entityDeleted ( EntityId  $entityId)

Called when an entity or redirect is deleted.

This is not called when an entity is replaced by a redirect or vice versa.

Parameters
EntityId$entityId

Implements Wikibase\Lib\Store\EntityStoreWatcher.

◆ entityUpdated()

Wikibase\DataAccess\MultipleEntitySourceServices::entityUpdated ( EntityRevision  $entityRevision)

Called when an entity is updated, created, or replaces a redirect.

This is not called when an entity is deleted or replaced by a redirect.

Parameters
EntityRevision$entityRevision

Implements Wikibase\Lib\Store\EntityStoreWatcher.

◆ getBaseDataModelSerializerFactory()

Wikibase\DataAccess\MultipleEntitySourceServices::getBaseDataModelSerializerFactory ( )
Returns
SerializerFactory A factory with knowledge about items, properties, and the elements they are made of, but no other entity types. Returns serializers that generate the full (expanded) serialization.

Implements Wikibase\DataAccess\WikibaseServices.

◆ getCompactBaseDataModelSerializerFactory()

Wikibase\DataAccess\MultipleEntitySourceServices::getCompactBaseDataModelSerializerFactory ( )
Returns
SerializerFactory A factory with knowledge about items, properties, and the elements they are made of, but no other entity types. Returns serializers that generate the most compact serialization.

Implements Wikibase\DataAccess\WikibaseServices.

◆ getCompactEntitySerializer()

Wikibase\DataAccess\MultipleEntitySourceServices::getCompactEntitySerializer ( )

Returns the entity serializer instance that generates the most compact serialization.

Returns
Serializer

Implements Wikibase\DataAccess\WikibaseServices.

◆ getEntityNamespaceLookup()

Wikibase\DataAccess\MultipleEntitySourceServices::getEntityNamespaceLookup ( )
Returns
EntityNamespaceLookup

Implements Wikibase\DataAccess\WikibaseServices.

◆ getEntityStoreWatcher()

Wikibase\DataAccess\MultipleEntitySourceServices::getEntityStoreWatcher ( )

Returns a service that can be registered as a watcher to changes to entity data.

Such watcher gets notified when entity is updated or deleted, or when the entity redirect is updated.

Returns
EntityStoreWatcher

Implements Wikibase\DataAccess\WikibaseServices.

◆ getFullEntitySerializer()

Wikibase\DataAccess\MultipleEntitySourceServices::getFullEntitySerializer ( )

Returns the entity serializer instance that generates the full (expanded) serialization.

Returns
Serializer

Implements Wikibase\DataAccess\WikibaseServices.

◆ getLanguageFallbackChainFactory()

Wikibase\DataAccess\MultipleEntitySourceServices::getLanguageFallbackChainFactory ( )
Returns
LanguageFallbackChainFactory

Implements Wikibase\DataAccess\WikibaseServices.

◆ getPropertyInfoLookup()

Wikibase\DataAccess\MultipleEntitySourceServices::getPropertyInfoLookup ( )
Note
Instance returned is not guaranteed to be a caching decorator. Callers should take care of caching themselves.
Returns
PropertyInfoLookup

Implements Wikibase\DataAccess\DataAccessServices.

◆ getStorageEntitySerializer()

Wikibase\DataAccess\MultipleEntitySourceServices::getStorageEntitySerializer ( )

Returns the entity serializer that generates serialization that is used in the storage layer.

Returns
Serializer

Implements Wikibase\DataAccess\WikibaseServices.

◆ getStringNormalizer()

Wikibase\DataAccess\MultipleEntitySourceServices::getStringNormalizer ( )
Returns
StringNormalizer

Implements Wikibase\DataAccess\WikibaseServices.

◆ getTermBuffer()

Wikibase\DataAccess\MultipleEntitySourceServices::getTermBuffer ( )
Returns
TermBuffer

Implements Wikibase\DataAccess\DataAccessServices.

◆ redirectUpdated()

Wikibase\DataAccess\MultipleEntitySourceServices::redirectUpdated ( EntityRedirect  $entityRedirect,
  $revisionId 
)

Called when a redirect is updated, created, or replaces an entity.

Not called when a redirect is deleted or replaced by an entity.

Parameters
EntityRedirect$entityRedirect
int$revisionId

Implements Wikibase\Lib\Store\EntityStoreWatcher.

Member Data Documentation

◆ $entityPrefetcher

Wikibase\DataAccess\MultipleEntitySourceServices::$entityPrefetcher = null
private

◆ $entityRevisionLookup

Wikibase\DataAccess\MultipleEntitySourceServices::$entityRevisionLookup = null
private

◆ $entitySourceDefinitions

Wikibase\DataAccess\MultipleEntitySourceServices::$entitySourceDefinitions
private

◆ $genericServices

Wikibase\DataAccess\MultipleEntitySourceServices::$genericServices
private

◆ $prefetchingTermLookup

Wikibase\DataAccess\MultipleEntitySourceServices::$prefetchingTermLookup = null
private

◆ $singleSourceServices

Wikibase\DataAccess\MultipleEntitySourceServices::$singleSourceServices
private

◆ $termSearchInteractorFactory

Wikibase\DataAccess\MultipleEntitySourceServices::$termSearchInteractorFactory = null
private

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