MediaWiki  master
PoolWorkArticleViewCurrent Class Reference

PoolWorkArticleView for the current revision of a page, using ParserCache. More...

Inheritance diagram for PoolWorkArticleViewCurrent:
Collaboration diagram for PoolWorkArticleViewCurrent:

Public Member Functions

 __construct (string $workKey, PageRecord $page, RevisionRecord $revision, ParserOptions $parserOptions, RevisionRenderer $revisionRenderer, ParserCache $parserCache, ILBFactory $lbFactory, ChronologyProtector $chronologyProtector, LoggerSpi $loggerSpi, WikiPageFactory $wikiPageFactory, bool $cacheable=true, bool $triggerLinksUpdate=false)
 
 doWork ()
 
 fallback ( $fast)
 
 getCachedWork ()
 
- Public Member Functions inherited from PoolWorkArticleView
 __construct (string $workKey, RevisionRecord $revision, ParserOptions $parserOptions, RevisionRenderer $revisionRenderer, LoggerSpi $loggerSpi)
 
 error ( $status)
 
 renderRevision ()
 
- Public Member Functions inherited from PoolCounterWork
 __construct (string $type, string $key, PoolCounter $poolCounter=null)
 
 execute ( $skipcache=false)
 Get the result of the work (whatever it is), or the result of the error() function. More...
 
 logError ( $status)
 Log an error. More...
 

Additional Inherited Members

- Protected Member Functions inherited from PoolCounterWork
 isFastStaleEnabled ()
 Should fast stale mode be used? More...
 
- Protected Attributes inherited from PoolWorkArticleView
LoggerSpi $loggerSpi
 
ParserOptions $parserOptions
 
RevisionRecord $revision
 
- Protected Attributes inherited from PoolCounterWork
bool $cacheable = false
 
string $type = 'generic'
 

Detailed Description

PoolWorkArticleView for the current revision of a page, using ParserCache.

Access: internal

Definition at line 36 of file PoolWorkArticleViewCurrent.php.

Constructor & Destructor Documentation

◆ __construct()

PoolWorkArticleViewCurrent::__construct ( string  $workKey,
PageRecord  $page,
RevisionRecord  $revision,
ParserOptions  $parserOptions,
RevisionRenderer  $revisionRenderer,
ParserCache  $parserCache,
ILBFactory  $lbFactory,
ChronologyProtector  $chronologyProtector,
LoggerSpi  $loggerSpi,
WikiPageFactory  $wikiPageFactory,
bool  $cacheable = true,
bool  $triggerLinksUpdate = false 
)
Parameters
string$workKey
PageRecord$page
RevisionRecord$revisionRevision to render
ParserOptions$parserOptionsParserOptions to use for the parse
RevisionRenderer$revisionRenderer
ParserCache$parserCache
ILBFactory$lbFactory
ChronologyProtector$chronologyProtector
LoggerSpi$loggerSpi
WikiPageFactory$wikiPageFactory
bool$cacheableWhether it should store the result in cache or not
bool$triggerLinksUpdateWhether it should trigger an opportunistic LinksUpdate or not

Definition at line 65 of file PoolWorkArticleViewCurrent.php.

References PoolCounterWork\$cacheable, PoolWorkArticleView\$loggerSpi, PoolWorkArticleView\$parserOptions, PoolWorkArticleView\$revision, MediaWiki\Page\ProperPageIdentity\getId(), and MediaWiki\Revision\RevisionRecord\getPageId().

Member Function Documentation

◆ doWork()

PoolWorkArticleViewCurrent::doWork ( )
Returns
Status

Reimplemented from PoolWorkArticleView.

Definition at line 100 of file PoolWorkArticleViewCurrent.php.

References PoolWorkArticleView\renderRevision(), and wfTimestampNow().

◆ fallback()

PoolWorkArticleViewCurrent::fallback (   $fast)
Parameters
bool$fastFast stale request
Returns
Status|false

Reimplemented from PoolCounterWork.

Definition at line 144 of file PoolWorkArticleViewCurrent.php.

◆ getCachedWork()

PoolWorkArticleViewCurrent::getCachedWork ( )
Returns
Status|false

Reimplemented from PoolCounterWork.

Definition at line 131 of file PoolWorkArticleViewCurrent.php.


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