MediaWiki master
MediaWiki\ResourceLoader\ResourceLoaderEventIngress Class Reference

The ingres adapter for the resource loader component. More...

Inherits MediaWiki\DomainEvent\DomainEventIngress, MediaWiki\Page\Event\PageRevisionUpdatedListener, and MediaWiki\Page\Event\PageDeletedListener.

Collaboration diagram for MediaWiki\ResourceLoader\ResourceLoaderEventIngress:

Public Member Functions

 __construct (LBFactory $lbFactory)
 
 handlePageDeletedEvent (PageDeletedEvent $event)
 Listener method for PageDeletedEvent, to be registered with a DomainEventSource.
 
 handlePageRevisionUpdatedEvent (PageRevisionUpdatedEvent $event)
 Listener method for PageRevisionUpdatedEvent, to be registered with a DomainEventSource.
 
- Public Member Functions inherited from MediaWiki\DomainEvent\DomainEventIngress
 initSubscriber (array $options)
 Called by DomainEventDispatcher to provide access to the list of events to subscribe to and any other relevant information from the extension.json.
 
 registerListeners (DomainEventSource $eventSource)
 This default implementation of registerListeners() will automatically register a listener method for each event passed to initEvents() or initSubscriber().
 

Public Attributes

const OBJECT_SPEC
 Object spec intended for use with DomainEventSource::registerSubscriber().
 

Additional Inherited Members

- Protected Member Functions inherited from MediaWiki\DomainEvent\DomainEventIngress
 getListenerOptions (string $eventType, string $suffix)
 Placeholder method for allowing subclasses to define listener options.
 
 registerForEvent (DomainEventSource $eventSource, string $eventType)
 Registered any listener methods for the given event.
 

Detailed Description

The ingres adapter for the resource loader component.

It updates resources related state based on domain events coming from other components.

Access: internal

Definition at line 20 of file ResourceLoaderEventIngress.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\ResourceLoader\ResourceLoaderEventIngress::__construct ( LBFactory $lbFactory)

Member Function Documentation

◆ handlePageDeletedEvent()

MediaWiki\ResourceLoader\ResourceLoaderEventIngress::handlePageDeletedEvent ( PageDeletedEvent $event)

Listener method for PageDeletedEvent, to be registered with a DomainEventSource.

@noinspection PhpUnused

Implements MediaWiki\Page\Event\PageDeletedListener.

Definition at line 67 of file ResourceLoaderEventIngress.php.

References MediaWiki\Page\Event\PageDeletedEvent\getDeletedPage(), MediaWiki\Page\Event\PageDeletedEvent\getLatestRevisionBefore(), and MediaWiki\ResourceLoader\WikiModule\invalidateModuleCache().

◆ handlePageRevisionUpdatedEvent()

Member Data Documentation

◆ OBJECT_SPEC

const MediaWiki\ResourceLoader\ResourceLoaderEventIngress::OBJECT_SPEC
Initial value:
= [
'class' => self::class,
'services' => [
'DBLoadBalancerFactory'
],
'events' => [
PageRevisionUpdatedEvent::TYPE,
PageDeletedEvent::TYPE,
],
]

Object spec intended for use with DomainEventSource::registerSubscriber().

Definition at line 26 of file ResourceLoaderEventIngress.php.


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