MediaWiki master
DumpOutput.php
Go to the documentation of this file.
1<?php
12namespace MediaWiki\Export;
13
18
22 public function writeOpenStream( $string ) {
23 $this->write( $string );
24 }
25
29 public function writeCloseStream( $string ) {
30 $this->write( $string );
31 }
32
37 public function writeOpenPage( $page, $string ) {
38 $this->write( $string );
39 }
40
44 public function writeClosePage( $string ) {
45 $this->write( $string );
46 }
47
52 public function writeRevision( $rev, $string ) {
53 $this->write( $string );
54 }
55
60 public function writeLogItem( $rev, $string ) {
61 $this->write( $string );
62 }
63
68 public function write( $string ) {
69 print $string;
70 }
71
79 public function closeRenameAndReopen( $newname ) {
80 }
81
90 public function closeAndRename( $newname, $open = false ) {
91 }
92
98 public function getFilenames() {
99 return null;
100 }
101}
102
104class_alias( DumpOutput::class, 'DumpOutput' );
write( $string)
Override to write to a different stream type.
writeLogItem( $rev, $string)
writeRevision( $rev, $string)
writeOpenPage( $page, $string)
getFilenames()
Returns the name of the file or files which are being written to, if there are any.
closeAndRename( $newname, $open=false)
Close the old file, and move it to a specified name.
closeRenameAndReopen( $newname)
Close the old file, move it to a specified name, and reopen new file with the old name.