Wikibase
MediaWiki Wikibase extension
Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob Class Reference

Job for updating the repo after a page on the client has been deleted. More...

+ Inheritance diagram for Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob:
+ Collaboration diagram for Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob:

Public Member Functions

 __construct (Title $title, array $params=[])
 Constructs a UpdateRepoOnMoveJob propagating a page move to the repo. More...
 
 initServices (EntityLookup $entityLookup, EntityStore $entityStore, SummaryFormatter $summaryFormatter, LoggerInterface $logger, SiteLookup $siteLookup, MediawikiEditEntityFactory $editEntityFactory)
 
 getSummary ()
 Get a Summary object for the edit. More...
 
- Public Member Functions inherited from Wikibase\Repo\UpdateRepo\UpdateRepoJob
 run ()
 

Protected Member Functions

 initRepoJobServicesFromGlobalState ()
 Initialize repo services from global state. More...
 
 verifyValid (Item $item)
 Whether the propagated update is valid (and thus should be applied) More...
 
 applyChanges (Item $item)
 Apply the changes needed to the given Item.
Parameters
Item$item
Returns
bool
More...
 
- Protected Member Functions inherited from Wikibase\Repo\UpdateRepo\UpdateRepoJob
 initRepoJobServices (EntityLookup $entityLookup, EntityStore $entityStore, SummaryFormatter $summaryFormatter, LoggerInterface $logger, MediawikiEditEntityFactory $editEntityFactory)
 

Private Member Functions

 getSiteLink (Item $item, $globalId)
 Get a SiteLink for a specific item and site. More...
 

Private Attributes

 $siteLookup
 

Additional Inherited Members

- Protected Attributes inherited from Wikibase\Repo\UpdateRepo\UpdateRepoJob
 $entityLookup
 
 $entityStore
 
 $summaryFormatter
 
 $logger
 

Detailed Description

Job for updating the repo after a page on the client has been deleted.

Author
Marius Hoch < hoo@o.nosp@m.nlin.nosp@m.e.de >

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::__construct ( Title  $title,
array  $params = [] 
)

Constructs a UpdateRepoOnMoveJob propagating a page move to the repo.

Note
This is for use by Job::factory, don't call it directly; use newFrom*() instead.
the constructor's signature is dictated by Job::factory, so we'll have to live with it even though it's rather ugly for our use case.
See also
Job::factory
UpdateRepoJob::__construct
Parameters
Title$title
array$params

Member Function Documentation

◆ applyChanges()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::applyChanges ( Item  $item)
protected

Apply the changes needed to the given Item.

Parameters
Item$item
Returns
bool

Reimplemented from Wikibase\Repo\UpdateRepo\UpdateRepoJob.

◆ getSiteLink()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::getSiteLink ( Item  $item,
  $globalId 
)
private

Get a SiteLink for a specific item and site.

Parameters
Item$item
string$globalId
Returns
SiteLink|null

◆ getSummary()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::getSummary ( )

Get a Summary object for the edit.

Returns
Summary

Reimplemented from Wikibase\Repo\UpdateRepo\UpdateRepoJob.

◆ initRepoJobServicesFromGlobalState()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::initRepoJobServicesFromGlobalState ( )
protected

Initialize repo services from global state.

Reimplemented from Wikibase\Repo\UpdateRepo\UpdateRepoJob.

◆ initServices()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::initServices ( EntityLookup  $entityLookup,
EntityStore  $entityStore,
SummaryFormatter  $summaryFormatter,
LoggerInterface  $logger,
SiteLookup  $siteLookup,
MediawikiEditEntityFactory  $editEntityFactory 
)

◆ verifyValid()

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::verifyValid ( Item  $item)
protected

Whether the propagated update is valid (and thus should be applied)

Parameters
Item$item
Returns
bool

Reimplemented from Wikibase\Repo\UpdateRepo\UpdateRepoJob.

Member Data Documentation

◆ $siteLookup

Wikibase\Repo\UpdateRepo\UpdateRepoOnDeleteJob::$siteLookup
private

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