MediaWiki  1.29.1
WikiExporter.php
Go to the documentation of this file.
1 <?php
32 
36 class WikiExporter {
38  public $list_authors = false;
39 
41  public $dumpUploads = false;
42 
44  public $dumpUploadFileContents = false;
45 
47  public $author_list = "";
48 
49  const FULL = 1;
50  const CURRENT = 2;
51  const STABLE = 4; // extension defined
52  const LOGS = 8;
53  const RANGE = 16;
54 
55  const BUFFER = 0;
56  const STREAM = 1;
57 
58  const TEXT = 0;
59  const STUB = 1;
60 
62  public $buffer;
63 
65  public $text;
66 
68  public $sink;
69 
74  public static function schemaVersion() {
75  return "0.10";
76  }
77 
94  function __construct( $db, $history = WikiExporter::CURRENT,
96  $this->db = $db;
97  $this->history = $history;
98  $this->buffer = $buffer;
99  $this->writer = new XmlDumpWriter();
100  $this->sink = new DumpOutput();
101  $this->text = $text;
102  }
103 
111  public function setOutputSink( &$sink ) {
112  $this->sink =& $sink;
113  }
114 
115  public function openStream() {
116  $output = $this->writer->openStream();
117  $this->sink->writeOpenStream( $output );
118  }
119 
120  public function closeStream() {
121  $output = $this->writer->closeStream();
122  $this->sink->writeCloseStream( $output );
123  }
124 
130  public function allPages() {
131  $this->dumpFrom( '' );
132  }
133 
142  public function pagesByRange( $start, $end, $orderRevs ) {
143  if ( $orderRevs ) {
144  $condition = 'rev_page >= ' . intval( $start );
145  if ( $end ) {
146  $condition .= ' AND rev_page < ' . intval( $end );
147  }
148  } else {
149  $condition = 'page_id >= ' . intval( $start );
150  if ( $end ) {
151  $condition .= ' AND page_id < ' . intval( $end );
152  }
153  }
154  $this->dumpFrom( $condition, $orderRevs );
155  }
156 
164  public function revsByRange( $start, $end ) {
165  $condition = 'rev_id >= ' . intval( $start );
166  if ( $end ) {
167  $condition .= ' AND rev_id < ' . intval( $end );
168  }
169  $this->dumpFrom( $condition );
170  }
171 
175  public function pageByTitle( $title ) {
176  $this->dumpFrom(
177  'page_namespace=' . $title->getNamespace() .
178  ' AND page_title=' . $this->db->addQuotes( $title->getDBkey() ) );
179  }
180 
185  public function pageByName( $name ) {
187  if ( is_null( $title ) ) {
188  throw new MWException( "Can't export invalid title" );
189  } else {
190  $this->pageByTitle( $title );
191  }
192  }
193 
197  public function pagesByName( $names ) {
198  foreach ( $names as $name ) {
199  $this->pageByName( $name );
200  }
201  }
202 
203  public function allLogs() {
204  $this->dumpFrom( '' );
205  }
206 
211  public function logsByRange( $start, $end ) {
212  $condition = 'log_id >= ' . intval( $start );
213  if ( $end ) {
214  $condition .= ' AND log_id < ' . intval( $end );
215  }
216  $this->dumpFrom( $condition );
217  }
218 
226  protected function do_list_authors( $cond ) {
227  $this->author_list = "<contributors>";
228  // rev_deleted
229 
230  $res = $this->db->select(
231  [ 'page', 'revision' ],
232  [ 'DISTINCT rev_user_text', 'rev_user' ],
233  [
234  $this->db->bitAnd( 'rev_deleted', Revision::DELETED_USER ) . ' = 0',
235  $cond,
236  'page_id = rev_id',
237  ],
238  __METHOD__
239  );
240 
241  foreach ( $res as $row ) {
242  $this->author_list .= "<contributor>" .
243  "<username>" .
244  htmlentities( $row->rev_user_text ) .
245  "</username>" .
246  "<id>" .
247  $row->rev_user .
248  "</id>" .
249  "</contributor>";
250  }
251  $this->author_list .= "</contributors>";
252  }
253 
259  protected function dumpFrom( $cond = '', $orderRevs = false ) {
260  # For logging dumps...
261  if ( $this->history & self::LOGS ) {
262  $where = [ 'user_id = log_user' ];
263  # Hide private logs
264  $hideLogs = LogEventsList::getExcludeClause( $this->db );
265  if ( $hideLogs ) {
266  $where[] = $hideLogs;
267  }
268  # Add on any caller specified conditions
269  if ( $cond ) {
270  $where[] = $cond;
271  }
272  # Get logging table name for logging.* clause
273  $logging = $this->db->tableName( 'logging' );
274 
275  if ( $this->buffer == WikiExporter::STREAM ) {
276  $prev = $this->db->bufferResults( false );
277  }
278  $result = null; // Assuring $result is not undefined, if exception occurs early
279  try {
280  $result = $this->db->select( [ 'logging', 'user' ],
281  [ "{$logging}.*", 'user_name' ], // grab the user name
282  $where,
283  __METHOD__,
284  [ 'ORDER BY' => 'log_id', 'USE INDEX' => [ 'logging' => 'PRIMARY' ] ]
285  );
286  $this->outputLogStream( $result );
287  if ( $this->buffer == WikiExporter::STREAM ) {
288  $this->db->bufferResults( $prev );
289  }
290  } catch ( Exception $e ) {
291  // Throwing the exception does not reliably free the resultset, and
292  // would also leave the connection in unbuffered mode.
293 
294  // Freeing result
295  try {
296  if ( $result ) {
297  $result->free();
298  }
299  } catch ( Exception $e2 ) {
300  // Already in panic mode -> ignoring $e2 as $e has
301  // higher priority
302  }
303 
304  // Putting database back in previous buffer mode
305  try {
306  if ( $this->buffer == WikiExporter::STREAM ) {
307  $this->db->bufferResults( $prev );
308  }
309  } catch ( Exception $e2 ) {
310  // Already in panic mode -> ignoring $e2 as $e has
311  // higher priority
312  }
313 
314  // Inform caller about problem
315  throw $e;
316  }
317  # For page dumps...
318  } else {
319  $tables = [ 'page', 'revision' ];
320  $opts = [ 'ORDER BY' => 'page_id ASC' ];
321  $opts['USE INDEX'] = [];
322  $join = [];
323  if ( is_array( $this->history ) ) {
324  # Time offset/limit for all pages/history...
325  $revJoin = 'page_id=rev_page';
326  # Set time order
327  if ( $this->history['dir'] == 'asc' ) {
328  $op = '>';
329  $opts['ORDER BY'] = 'rev_timestamp ASC';
330  } else {
331  $op = '<';
332  $opts['ORDER BY'] = 'rev_timestamp DESC';
333  }
334  # Set offset
335  if ( !empty( $this->history['offset'] ) ) {
336  $revJoin .= " AND rev_timestamp $op " .
337  $this->db->addQuotes( $this->db->timestamp( $this->history['offset'] ) );
338  }
339  $join['revision'] = [ 'INNER JOIN', $revJoin ];
340  # Set query limit
341  if ( !empty( $this->history['limit'] ) ) {
342  $opts['LIMIT'] = intval( $this->history['limit'] );
343  }
344  } elseif ( $this->history & WikiExporter::FULL ) {
345  # Full history dumps...
346  # query optimization for history stub dumps
347  if ( $this->text == WikiExporter::STUB && $orderRevs ) {
348  $tables = [ 'revision', 'page' ];
349  $opts[] = 'STRAIGHT_JOIN';
350  $opts['ORDER BY'] = [ 'rev_page ASC', 'rev_id ASC' ];
351  $opts['USE INDEX']['revision'] = 'rev_page_id';
352  $join['page'] = [ 'INNER JOIN', 'rev_page=page_id' ];
353  } else {
354  $join['revision'] = [ 'INNER JOIN', 'page_id=rev_page' ];
355  }
356  } elseif ( $this->history & WikiExporter::CURRENT ) {
357  # Latest revision dumps...
358  if ( $this->list_authors && $cond != '' ) { // List authors, if so desired
359  $this->do_list_authors( $cond );
360  }
361  $join['revision'] = [ 'INNER JOIN', 'page_id=rev_page AND page_latest=rev_id' ];
362  } elseif ( $this->history & WikiExporter::STABLE ) {
363  # "Stable" revision dumps...
364  # Default JOIN, to be overridden...
365  $join['revision'] = [ 'INNER JOIN', 'page_id=rev_page AND page_latest=rev_id' ];
366  # One, and only one hook should set this, and return false
367  if ( Hooks::run( 'WikiExporter::dumpStableQuery', [ &$tables, &$opts, &$join ] ) ) {
368  throw new MWException( __METHOD__ . " given invalid history dump type." );
369  }
370  } elseif ( $this->history & WikiExporter::RANGE ) {
371  # Dump of revisions within a specified range
372  $join['revision'] = [ 'INNER JOIN', 'page_id=rev_page' ];
373  $opts['ORDER BY'] = [ 'rev_page ASC', 'rev_id ASC' ];
374  } else {
375  # Unknown history specification parameter?
376  throw new MWException( __METHOD__ . " given invalid history dump type." );
377  }
378  # Query optimization hacks
379  if ( $cond == '' ) {
380  $opts[] = 'STRAIGHT_JOIN';
381  $opts['USE INDEX']['page'] = 'PRIMARY';
382  }
383  # Build text join options
384  if ( $this->text != WikiExporter::STUB ) { // 1-pass
385  $tables[] = 'text';
386  $join['text'] = [ 'INNER JOIN', 'rev_text_id=old_id' ];
387  }
388 
389  if ( $this->buffer == WikiExporter::STREAM ) {
390  $prev = $this->db->bufferResults( false );
391  }
392  $result = null; // Assuring $result is not undefined, if exception occurs early
393  try {
394  Hooks::run( 'ModifyExportQuery',
395  [ $this->db, &$tables, &$cond, &$opts, &$join ] );
396 
397  # Do the query!
398  $result = $this->db->select( $tables, '*', $cond, __METHOD__, $opts, $join );
399  # Output dump results
400  $this->outputPageStream( $result );
401 
402  if ( $this->buffer == WikiExporter::STREAM ) {
403  $this->db->bufferResults( $prev );
404  }
405  } catch ( Exception $e ) {
406  // Throwing the exception does not reliably free the resultset, and
407  // would also leave the connection in unbuffered mode.
408 
409  // Freeing result
410  try {
411  if ( $result ) {
412  $result->free();
413  }
414  } catch ( Exception $e2 ) {
415  // Already in panic mode -> ignoring $e2 as $e has
416  // higher priority
417  }
418 
419  // Putting database back in previous buffer mode
420  try {
421  if ( $this->buffer == WikiExporter::STREAM ) {
422  $this->db->bufferResults( $prev );
423  }
424  } catch ( Exception $e2 ) {
425  // Already in panic mode -> ignoring $e2 as $e has
426  // higher priority
427  }
428 
429  // Inform caller about problem
430  throw $e;
431  }
432  }
433  }
434 
447  protected function outputPageStream( $resultset ) {
448  $last = null;
449  foreach ( $resultset as $row ) {
450  if ( $last === null ||
451  $last->page_namespace != $row->page_namespace ||
452  $last->page_title != $row->page_title ) {
453  if ( $last !== null ) {
454  $output = '';
455  if ( $this->dumpUploads ) {
456  $output .= $this->writer->writeUploads( $last, $this->dumpUploadFileContents );
457  }
458  $output .= $this->writer->closePage();
459  $this->sink->writeClosePage( $output );
460  }
461  $output = $this->writer->openPage( $row );
462  $this->sink->writeOpenPage( $row, $output );
463  $last = $row;
464  }
465  $output = $this->writer->writeRevision( $row );
466  $this->sink->writeRevision( $row, $output );
467  }
468  if ( $last !== null ) {
469  $output = '';
470  if ( $this->dumpUploads ) {
471  $output .= $this->writer->writeUploads( $last, $this->dumpUploadFileContents );
472  }
474  $output .= $this->writer->closePage();
475  $this->sink->writeClosePage( $output );
476  }
477  }
478 
482  protected function outputLogStream( $resultset ) {
483  foreach ( $resultset as $row ) {
484  $output = $this->writer->writeLogItem( $row );
485  $this->sink->writeLogItem( $row, $output );
486  }
487  }
488 }
Revision\DELETED_USER
const DELETED_USER
Definition: Revision.php:92
WikiExporter\schemaVersion
static schemaVersion()
Returns the export schema version.
Definition: WikiExporter.php:74
Title\newFromText
static newFromText( $text, $defaultNamespace=NS_MAIN)
Create a new Title from text, such as what one would find in a link.
Definition: Title.php:265
$tables
this hook is for auditing only RecentChangesLinked and Watchlist RecentChangesLinked and Watchlist Do not use this to implement individual filters if they are compatible with the ChangesListFilter and ChangesListFilterGroup structure use sub classes of those in conjunction with the ChangesListSpecialPageStructuredFilters hook This hook can be used to implement filters that do not implement that or custom behavior that is not an individual filter e g Watchlist & $tables
Definition: hooks.txt:990
WikiExporter\revsByRange
revsByRange( $start, $end)
Dumps a series of page and revision records for those pages in the database with revisions falling wi...
Definition: WikiExporter.php:164
WikiExporter\CURRENT
const CURRENT
Definition: WikiExporter.php:50
$last
$last
Definition: profileinfo.php:415
text
design txt This is a brief overview of the new design More thorough and up to date information is available on the documentation wiki at etc Handles the details of getting and saving to the user table of the and dealing with sessions and cookies OutputPage Encapsulates the entire HTML page that will be sent in response to any server request It is used by calling its functions to add text
Definition: design.txt:12
$result
The index of the header message $result[1]=The index of the body text message $result[2 through n]=Parameters passed to body text message. Please note the header message cannot receive/use parameters. 'ImportHandleLogItemXMLTag':When parsing a XML tag in a log item. Return false to stop further processing of the tag $reader:XMLReader object $logInfo:Array of information 'ImportHandlePageXMLTag':When parsing a XML tag in a page. Return false to stop further processing of the tag $reader:XMLReader object & $pageInfo:Array of information 'ImportHandleRevisionXMLTag':When parsing a XML tag in a page revision. Return false to stop further processing of the tag $reader:XMLReader object $pageInfo:Array of page information $revisionInfo:Array of revision information 'ImportHandleToplevelXMLTag':When parsing a top level XML tag. Return false to stop further processing of the tag $reader:XMLReader object 'ImportHandleUploadXMLTag':When parsing a XML tag in a file upload. Return false to stop further processing of the tag $reader:XMLReader object $revisionInfo:Array of information 'ImportLogInterwikiLink':Hook to change the interwiki link used in log entries and edit summaries for transwiki imports. & $fullInterwikiPrefix:Interwiki prefix, may contain colons. & $pageTitle:String that contains page title. 'ImportSources':Called when reading from the $wgImportSources configuration variable. Can be used to lazy-load the import sources list. & $importSources:The value of $wgImportSources. Modify as necessary. See the comment in DefaultSettings.php for the detail of how to structure this array. 'InfoAction':When building information to display on the action=info page. $context:IContextSource object & $pageInfo:Array of information 'InitializeArticleMaybeRedirect':MediaWiki check to see if title is a redirect. & $title:Title object for the current page & $request:WebRequest & $ignoreRedirect:boolean to skip redirect check & $target:Title/string of redirect target & $article:Article object 'InternalParseBeforeLinks':during Parser 's internalParse method before links but after nowiki/noinclude/includeonly/onlyinclude and other processings. & $parser:Parser object & $text:string containing partially parsed text & $stripState:Parser 's internal StripState object 'InternalParseBeforeSanitize':during Parser 's internalParse method just before the parser removes unwanted/dangerous HTML tags and after nowiki/noinclude/includeonly/onlyinclude and other processings. Ideal for syntax-extensions after template/parser function execution which respect nowiki and HTML-comments. & $parser:Parser object & $text:string containing partially parsed text & $stripState:Parser 's internal StripState object 'InterwikiLoadPrefix':When resolving if a given prefix is an interwiki or not. Return true without providing an interwiki to continue interwiki search. $prefix:interwiki prefix we are looking for. & $iwData:output array describing the interwiki with keys iw_url, iw_local, iw_trans and optionally iw_api and iw_wikiid. 'InvalidateEmailComplete':Called after a user 's email has been invalidated successfully. $user:user(object) whose email is being invalidated 'IRCLineURL':When constructing the URL to use in an IRC notification. Callee may modify $url and $query, URL will be constructed as $url . $query & $url:URL to index.php & $query:Query string $rc:RecentChange object that triggered url generation 'IsFileCacheable':Override the result of Article::isFileCacheable()(if true) & $article:article(object) being checked 'IsTrustedProxy':Override the result of IP::isTrustedProxy() & $ip:IP being check & $result:Change this value to override the result of IP::isTrustedProxy() 'IsUploadAllowedFromUrl':Override the result of UploadFromUrl::isAllowedUrl() $url:URL used to upload from & $allowed:Boolean indicating if uploading is allowed for given URL 'isValidEmailAddr':Override the result of Sanitizer::validateEmail(), for instance to return false if the domain name doesn 't match your organization. $addr:The e-mail address entered by the user & $result:Set this and return false to override the internal checks 'isValidPassword':Override the result of User::isValidPassword() $password:The password entered by the user & $result:Set this and return false to override the internal checks $user:User the password is being validated for 'Language::getMessagesFileName':$code:The language code or the language we 're looking for a messages file for & $file:The messages file path, you can override this to change the location. 'LanguageGetMagic':DEPRECATED! Use $magicWords in a file listed in $wgExtensionMessagesFiles instead. Use this to define synonyms of magic words depending of the language & $magicExtensions:associative array of magic words synonyms $lang:language code(string) 'LanguageGetNamespaces':Provide custom ordering for namespaces or remove namespaces. Do not use this hook to add namespaces. Use CanonicalNamespaces for that. & $namespaces:Array of namespaces indexed by their numbers 'LanguageGetSpecialPageAliases':DEPRECATED! Use $specialPageAliases in a file listed in $wgExtensionMessagesFiles instead. Use to define aliases of special pages names depending of the language & $specialPageAliases:associative array of magic words synonyms $lang:language code(string) 'LanguageGetTranslatedLanguageNames':Provide translated language names. & $names:array of language code=> language name $code:language of the preferred translations 'LanguageLinks':Manipulate a page 's language links. This is called in various places to allow extensions to define the effective language links for a page. $title:The page 's Title. & $links:Array with elements of the form "language:title" in the order that they will be output. & $linkFlags:Associative array mapping prefixed links to arrays of flags. Currently unused, but planned to provide support for marking individual language links in the UI, e.g. for featured articles. 'LanguageSelector':Hook to change the language selector available on a page. $out:The output page. $cssClassName:CSS class name of the language selector. 'LinkBegin':DEPRECATED! Use HtmlPageLinkRendererBegin instead. Used when generating internal and interwiki links in Linker::link(), before processing starts. Return false to skip default processing and return $ret. See documentation for Linker::link() for details on the expected meanings of parameters. $skin:the Skin object $target:the Title that the link is pointing to & $html:the contents that the< a > tag should have(raw HTML) $result
Definition: hooks.txt:1954
use
as see the revision history and available at free of to any person obtaining a copy of this software and associated documentation to deal in the Software without including without limitation the rights to use
Definition: MIT-LICENSE.txt:10
WikiExporter\$dumpUploadFileContents
bool $dumpUploadFileContents
Definition: WikiExporter.php:44
WikiExporter\__construct
__construct( $db, $history=WikiExporter::CURRENT, $buffer=WikiExporter::BUFFER, $text=WikiExporter::TEXT)
If using WikiExporter::STREAM to stream a large amount of data, provide a database connection which i...
Definition: WikiExporter.php:94
$res
$res
Definition: database.txt:21
$name
Allows to change the fields on the form that will be generated $name
Definition: hooks.txt:304
Wikimedia\Rdbms\ResultWrapper
Result wrapper for grabbing data queried from an IDatabase object.
Definition: ResultWrapper.php:24
WikiExporter\allLogs
allLogs()
Definition: WikiExporter.php:203
WikiExporter\dumpFrom
dumpFrom( $cond='', $orderRevs=false)
Definition: WikiExporter.php:259
php
injection txt This is an overview of how MediaWiki makes use of dependency injection The design described here grew from the discussion of RFC T384 The term dependency this means that anything an object needs to operate should be injected from the the object itself should only know narrow no concrete implementation of the logic it relies on The requirement to inject everything typically results in an architecture that based on two main types of and essentially stateless service objects that use other service objects to operate on the value objects As of the beginning MediaWiki is only starting to use the DI approach Much of the code still relies on global state or direct resulting in a highly cyclical dependency which acts as the top level factory for services in MediaWiki which can be used to gain access to default instances of various services MediaWikiServices however also allows new services to be defined and default services to be redefined Services are defined or redefined by providing a callback the instantiator that will return a new instance of the service When it will create an instance of MediaWikiServices and populate it with the services defined in the files listed by thereby bootstrapping the DI framework Per $wgServiceWiringFiles lists includes ServiceWiring php
Definition: injection.txt:35
WikiExporter\openStream
openStream()
Definition: WikiExporter.php:115
Wikimedia\Rdbms\IDatabase
Basic database interface for live and lazy-loaded relation database handles.
Definition: IDatabase.php:40
WikiExporter\STUB
const STUB
Definition: WikiExporter.php:59
WikiExporter\$text
int $text
Definition: WikiExporter.php:65
WikiExporter\$list_authors
bool $list_authors
Return distinct author list (when not returning full history)
Definition: WikiExporter.php:38
MWException
MediaWiki exception.
Definition: MWException.php:26
$title
namespace and then decline to actually register it file or subcat img or subcat $title
Definition: hooks.txt:934
WikiExporter\pagesByName
pagesByName( $names)
Definition: WikiExporter.php:197
WikiExporter\TEXT
const TEXT
Definition: WikiExporter.php:58
WikiExporter\$buffer
int $buffer
Definition: WikiExporter.php:62
WikiExporter\outputLogStream
outputLogStream( $resultset)
Definition: WikiExporter.php:482
WikiExporter\closeStream
closeStream()
Definition: WikiExporter.php:120
WikiExporter\allPages
allPages()
Dumps a series of page and revision records for all pages in the database, either including complete ...
Definition: WikiExporter.php:130
WikiExporter\$dumpUploads
bool $dumpUploads
Definition: WikiExporter.php:41
$output
this hook is for auditing only RecentChangesLinked and Watchlist RecentChangesLinked and Watchlist Do not use this to implement individual filters if they are compatible with the ChangesListFilter and ChangesListFilterGroup structure use sub classes of those in conjunction with the ChangesListSpecialPageStructuredFilters hook This hook can be used to implement filters that do not implement that or custom behavior that is not an individual filter e g Watchlist and Watchlist you will want to construct new ChangesListBooleanFilter or ChangesListStringOptionsFilter objects When constructing you specify which group they belong to You can reuse existing or create your you must register them with $special registerFilterGroup removed from all revisions and log entries to which it was applied This gives extensions a chance to take it off their books as the deletion has already been partly carried out by this point or something similar the user will be unable to create the tag set and then return false from the hook function Ensure you consume the ChangeTagAfterDelete hook to carry out custom deletion actions as context called by AbstractContent::getParserOutput May be used to override the normal model specific rendering of page content as context as context the output can only depend on parameters provided to this hook not on global state indicating whether full HTML should be generated If generation of HTML may be but other information should still be present in the ParserOutput object & $output
Definition: hooks.txt:1049
WikiExporter\STABLE
const STABLE
Definition: WikiExporter.php:51
DumpOutput
Definition: DumpOutput.php:29
WikiExporter
Definition: WikiExporter.php:36
WikiExporter\$author_list
string $author_list
Definition: WikiExporter.php:47
WikiExporter\pagesByRange
pagesByRange( $start, $end, $orderRevs)
Dumps a series of page and revision records for those pages in the database falling within the page_i...
Definition: WikiExporter.php:142
$e
div flags Integer display flags(NO_ACTION_LINK, NO_EXTRA_USER_LINKS) 'LogException' returning false will NOT prevent logging $e
Definition: hooks.txt:2122
WikiExporter\STREAM
const STREAM
Definition: WikiExporter.php:56
LogEventsList\getExcludeClause
static getExcludeClause( $db, $audience='public', User $user=null)
SQL clause to skip forbidden log types for this user.
Definition: LogEventsList.php:717
WikiExporter\do_list_authors
do_list_authors( $cond)
Generates the distinct list of authors of an article Not called by default (depends on $this->list_au...
Definition: WikiExporter.php:226
WikiExporter\FULL
const FULL
Definition: WikiExporter.php:49
WikiExporter\RANGE
const RANGE
Definition: WikiExporter.php:53
WikiExporter\setOutputSink
setOutputSink(&$sink)
Set the DumpOutput or DumpFilter object which will receive various row objects and XML output for fil...
Definition: WikiExporter.php:111
WikiExporter\LOGS
const LOGS
Definition: WikiExporter.php:52
history
presenting them properly to the user as errors is done by the caller return true use this to change the list i e etc next in line in page history
Definition: hooks.txt:1741
XmlDumpWriter
Definition: XmlDumpWriter.php:29
WikiExporter\logsByRange
logsByRange( $start, $end)
Definition: WikiExporter.php:211
as
This document is intended to provide useful advice for parties seeking to redistribute MediaWiki to end users It s targeted particularly at maintainers for Linux since it s been observed that distribution packages of MediaWiki often break We ve consistently had to recommend that users seeking support use official tarballs instead of their distribution s and this often solves whatever problem the user is having It would be nice if this could such as
Definition: distributors.txt:9
WikiExporter\pageByTitle
pageByTitle( $title)
Definition: WikiExporter.php:175
WikiExporter\outputPageStream
outputPageStream( $resultset)
Runs through a query result set dumping page and revision records.
Definition: WikiExporter.php:447
writer
An extension writer
Definition: hooks.txt:51
WikiExporter\pageByName
pageByName( $name)
Definition: WikiExporter.php:185
WikiExporter\$sink
DumpOutput $sink
Definition: WikiExporter.php:68
Hooks\run
static run( $event, array $args=[], $deprecatedVersion=null)
Call hook functions defined in Hooks::register and $wgHooks.
Definition: Hooks.php:131
WikiExporter\BUFFER
const BUFFER
Definition: WikiExporter.php:55