return '';
}
- # --------------
-
- /** Left in for debugging */
- private function dumpElement() {
- static $lookup = null;
- if ( !$lookup ) {
- $xmlReaderConstants = array(
- "NONE",
- "ELEMENT",
- "ATTRIBUTE",
- "TEXT",
- "CDATA",
- "ENTITY_REF",
- "ENTITY",
- "PI",
- "COMMENT",
- "DOC",
- "DOC_TYPE",
- "DOC_FRAGMENT",
- "NOTATION",
- "WHITESPACE",
- "SIGNIFICANT_WHITESPACE",
- "END_ELEMENT",
- "END_ENTITY",
- "XML_DECLARATION",
- );
- $lookup = array();
-
- foreach ( $xmlReaderConstants as $name ) {
- $lookup[constant( "XmlReader::$name" )] = $name;
- }
- }
-
- print var_dump(
- $lookup[$this->reader->nodeType],
- $this->reader->name,
- $this->reader->value
- ) . "\n\n";
- }
-
/**
* Primary entry point
* @throws MWException
* @return bool
*/
public function doImport() {
-
// Calls to reader->read need to be wrapped in calls to
// libxml_disable_entity_loader() to avoid local file
// inclusion attacks (bug 46932).
/** This is a horrible hack used to keep source compatibility */
class UploadSourceAdapter {
/** @var array */
- private static $sourceRegistrations = array();
+ public static $sourceRegistrations = array();
/** @var string */
private $mSource;
*/
class WikiRevision {
/** @todo Unused? */
- private $importer = null;
+ public $importer = null;
/** @var Title */
public $title = null;
/** @var int */
- private $id = 0;
+ public $id = 0;
/** @var string */
public $timestamp = "20010115000000";
public $user_text = "";
/** @var string */
- protected $model = null;
+ public $model = null;
/** @var string */
- protected $format = null;
+ public $format = null;
/** @var string */
public $text = "";
protected $size;
/** @var Content */
- protected $content = null;
+ public $content = null;
/** @var ContentHandler */
protected $contentHandler = null;
public $comment = "";
/** @var bool */
- protected $minor = false;
+ public $minor = false;
/** @var string */
- protected $type = "";
+ public $type = "";
/** @var string */
- protected $action = "";
+ public $action = "";
/** @var string */
- protected $params = "";
+ public $params = "";
/** @var string */
- protected $fileSrc = '';
+ public $fileSrc = '';
/** @var bool|string */
- protected $sha1base36 = false;
+ public $sha1base36 = false;
/**
* @var bool
* @todo Unused?
*/
- private $isTemp = false;
+ public $isTemp = false;
/** @var string */
- protected $archiveName = '';
+ public $archiveName = '';
protected $filename;
protected $src;
/** @todo Unused? */
- private $fileIsTemp;
+ public $fileIsTemp;
/** @var bool */
private $mNoUpdates = false;
return true;
}
- /**
- * @return mixed
- */
function importLogItem() {
$dbw = wfGetDB( DB_MASTER );
# @todo FIXME: This will not record autoblocks
wfDebug( __METHOD__ . ": Successful\n" );
return true;
} else {
- wfDebug( __METHOD__ . ': failed: ' . $status->getXml() . "\n" );
+ wfDebug( __METHOD__ . ': failed: ' . $status->getHTML() . "\n" );
return false;
}
}