MediaWiki REL1_33
|
Public Member Functions | |
caseSetting () | |
closePage () | |
Closes a "<page>" section on the output stream. | |
closeStream () | |
Closes the output stream with the closing root element. | |
dbname () | |
generator () | |
homelink () | |
namespaces () | |
openPage ( $row) | |
Opens a "<page>" section on the output stream, with data from the given database row. | |
openStream () | |
Opens the XML output stream's root "<mediawiki>" element. | |
siteInfo () | |
sitename () | |
writeContributor ( $id, $text, $indent=" ") | |
writeLogItem ( $row) | |
Dumps a "<logitem>" section on the output stream, with data filled in from the given database row. | |
writeRevision ( $row) | |
Dumps a "<revision>" section on the output stream, with data filled in from the given database row. | |
writeTimestamp ( $timestamp, $indent=" ") | |
writeUpload ( $file, $dumpContents=false) | |
writeUploads ( $row, $dumpContents=false) | |
Warning! This data is potentially inconsistent. | |
Static Public Member Functions | |
static | canonicalTitle (Title $title) |
Return prefixed text form of title, but using the content language's canonical namespace. | |
Static Public Attributes | |
static string[] | $supportedSchemas |
the schema versions supported for output @final | |
Private Member Functions | |
getBlobStore () | |
getRevisionStore () | |
Private Attributes | |
Title null | $currentTitle = null |
Title of the currently processed page. | |
Definition at line 32 of file XmlDumpWriter.php.
|
static |
Return prefixed text form of title, but using the content language's canonical namespace.
This skips any special-casing such as gendered user namespaces – which while useful, are not yet listed in the XML "<siteinfo>" data so are unsafe in export.
Title | $title |
Definition at line 528 of file XmlDumpWriter.php.
XmlDumpWriter::caseSetting | ( | ) |
Definition at line 132 of file XmlDumpWriter.php.
References $wgCapitalLinks.
Referenced by siteInfo().
XmlDumpWriter::closePage | ( | ) |
Closes a "<page>" section on the output stream.
Definition at line 209 of file XmlDumpWriter.php.
XmlDumpWriter::closeStream | ( | ) |
Closes the output stream with the closing root element.
Call when finished dumping things.
Definition at line 165 of file XmlDumpWriter.php.
XmlDumpWriter::dbname | ( | ) |
Definition at line 109 of file XmlDumpWriter.php.
References $wgDBname.
Referenced by siteInfo().
XmlDumpWriter::generator | ( | ) |
Definition at line 117 of file XmlDumpWriter.php.
References $wgVersion.
Referenced by siteInfo().
|
private |
Definition at line 229 of file XmlDumpWriter.php.
Referenced by writeRevision().
|
private |
Definition at line 222 of file XmlDumpWriter.php.
Referenced by writeRevision().
XmlDumpWriter::homelink | ( | ) |
XmlDumpWriter::namespaces | ( | ) |
XmlDumpWriter::openPage | ( | $row | ) |
Opens a "<page>" section on the output stream, with data from the given database row.
object | $row |
Definition at line 176 of file XmlDumpWriter.php.
References $out, and(), and Title\isValidRedirectTarget().
XmlDumpWriter::openStream | ( | ) |
Opens the XML output stream's root "<mediawiki>" element.
This does not include an xml directive, so is safe to include as a subelement in a larger XML stream. Namespace and XML Schema references are included.
Output will be encoded in UTF-8.
Definition at line 58 of file XmlDumpWriter.php.
References siteInfo().
XmlDumpWriter::siteInfo | ( | ) |
Definition at line 85 of file XmlDumpWriter.php.
References caseSetting(), dbname(), generator(), homelink(), namespaces, and sitename().
Referenced by openStream().
XmlDumpWriter::sitename | ( | ) |
Definition at line 101 of file XmlDumpWriter.php.
References $wgSitename.
Referenced by siteInfo().
XmlDumpWriter::writeContributor | ( | $id, | |
$text, | |||
$indent = " " ) |
int | $id | |
string | $text | |
string | $indent | Default to six spaces |
Definition at line 442 of file XmlDumpWriter.php.
Referenced by writeLogItem(), writeRevision(), and writeUpload().
XmlDumpWriter::writeLogItem | ( | $row | ) |
Dumps a "<logitem>" section on the output stream, with data filled in from the given database row.
object | $row |
Definition at line 387 of file XmlDumpWriter.php.
References $out, and(), LogPage\DELETED_ACTION, LogPage\DELETED_COMMENT, LogPage\DELETED_USER, writeContributor(), and writeTimestamp().
XmlDumpWriter::writeRevision | ( | $row | ) |
Dumps a "<revision>" section on the output stream, with data filled in from the given database row.
object | $row |
Definition at line 241 of file XmlDumpWriter.php.
References $content, $out, $rev, and(), Revision\DELETED_COMMENT, Revision\DELETED_TEXT, Revision\DELETED_USER, getBlobStore(), getRevisionStore(), Revision\getRevisionText(), wfLogWarning(), writeContributor(), and writeTimestamp().
XmlDumpWriter::writeTimestamp | ( | $timestamp, | |
$indent = " " ) |
string | $timestamp | |
string | $indent | Default to six spaces |
Definition at line 431 of file XmlDumpWriter.php.
References wfTimestamp().
Referenced by writeLogItem(), writeRevision(), and writeUpload().
XmlDumpWriter::writeUpload | ( | $file, | |
$dumpContents = false ) |
File | $file | |
bool | $dumpContents |
Definition at line 480 of file XmlDumpWriter.php.
References and(), File\DELETED_COMMENT, writeContributor(), and writeTimestamp().
Referenced by writeUploads().
XmlDumpWriter::writeUploads | ( | $row, | |
$dumpContents = false ) |
Warning! This data is potentially inconsistent.
:(
object | $row | |
bool | $dumpContents |
Definition at line 460 of file XmlDumpWriter.php.
References $out, and(), NS_FILE, wfLocalFile(), and writeUpload().
Title of the currently processed page.
Definition at line 46 of file XmlDumpWriter.php.
|
static |
the schema versions supported for output @final
Definition at line 37 of file XmlDumpWriter.php.
Referenced by MediaWiki\Tests\Maintenance\BackupDumperPageTest\schemaVersionProvider().