MediaWiki  master
ImportReporter Class Reference

Reporting callback. More...

Inheritance diagram for ImportReporter:
Collaboration diagram for ImportReporter:

Public Member Functions

 __construct ( $importer, $upload, $interwiki, $reason=false)
 
 close ()
 
 open ()
 
 reportLogItem (... $args)
 
 reportNotice ( $msg, array $params)
 
 reportPage ( $title, $foreignTitle, $revisionCount, $successCount, $pageInfo)
 
 setChangeTags (array $tags)
 Sets change tags to apply to the import log entry and null revision. More...
 
- Public Member Functions inherited from ContextSource
 canUseWikiPage ()
 Check whether a WikiPage object can be get with getWikiPage(). More...
 
 exportSession ()
 Export the resolved user IP, HTTP headers, user ID, and session ID. More...
 
 getConfig ()
 
 getContext ()
 Get the base IContextSource object. More...
 
 getLanguage ()
 
 getOutput ()
 
 getRequest ()
 
 getSkin ()
 
 getStats ()
 
 getTiming ()
 
 getTitle ()
 
 getUser ()
 
 getWikiPage ()
 Get the WikiPage object. More...
 
 msg ( $key)
 Get a Message object with context set Parameters are the same as wfMessage() More...
 
 setContext (IContextSource $context)
 

Private Attributes

 $logTags = []
 
 $mLogItemCount = 0
 
 $mOriginalLogCallback = null
 
 $mOriginalPageOutCallback = null
 
 $reason = false
 

Detailed Description

Reporting callback.

Definition at line 27 of file ImportReporter.php.

Constructor & Destructor Documentation

◆ __construct()

ImportReporter::__construct (   $importer,
  $upload,
  $interwiki,
  $reason = false 
)
Parameters
WikiImporter$importer
bool$upload
string$interwiki
string | bool$reason

Definition at line 40 of file ImportReporter.php.

References $reason.

Member Function Documentation

◆ close()

ImportReporter::close ( )

◆ open()

ImportReporter::open ( )

Definition at line 62 of file ImportReporter.php.

References ContextSource\getOutput().

◆ reportLogItem()

ImportReporter::reportLogItem (   $args)

Definition at line 72 of file ImportReporter.php.

References $args.

◆ reportNotice()

ImportReporter::reportNotice (   $msg,
array  $params 
)

◆ reportPage()

ImportReporter::reportPage (   $title,
  $foreignTitle,
  $revisionCount,
  $successCount,
  $pageInfo 
)
Parameters
Title$title
ForeignTitle$foreignTitle
int$revisionCount
int$successCount
array$pageInfo
Returns
void

Definition at line 87 of file ImportReporter.php.

References $linkRenderer, $reason, $title, DB_MASTER, WikiPage\factory(), ContextSource\getOutput(), ContextSource\getUser(), ContextSource\msg(), Revision\newNullRevision(), null, Hooks\run(), and wfGetDB().

◆ setChangeTags()

ImportReporter::setChangeTags ( array  $tags)

Sets change tags to apply to the import log entry and null revision.

Parameters
array$tags
Since
1.29

Definition at line 58 of file ImportReporter.php.

Member Data Documentation

◆ $logTags

ImportReporter::$logTags = []
private

Definition at line 29 of file ImportReporter.php.

◆ $mLogItemCount

ImportReporter::$mLogItemCount = 0
private

Definition at line 32 of file ImportReporter.php.

◆ $mOriginalLogCallback

ImportReporter::$mOriginalLogCallback = null
private

Definition at line 30 of file ImportReporter.php.

◆ $mOriginalPageOutCallback

ImportReporter::$mOriginalPageOutCallback = null
private

Definition at line 31 of file ImportReporter.php.

◆ $reason

ImportReporter::$reason = false
private

Definition at line 28 of file ImportReporter.php.

Referenced by __construct(), and reportPage().


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