*/
private $mPrinter;
- private $mModuleMgr, $mResult, $mErrorFormatter, $mContinuationManager;
+ private $mModuleMgr, $mResult, $mErrorFormatter;
+ /** @var ApiContinuationManager|null */
+ private $mContinuationManager;
private $mAction;
private $mEnableWrite;
private $mInternalMode, $mSquidMaxage;
*
* @since 1.21
*
- * @return null
+ * @return Title|null
*
* @see Content::getRedirectTarget
*/
/**
* Frees resources associated with the LOB descriptor
- * @param ResultWrapper|resource $res
+ * @param ResultWrapper|ORAResult $res
*/
function freeResult( $res ) {
if ( $res instanceof ResultWrapper ) {
}
/**
- * @param ResultWrapper|stdClass $res
+ * @param ResultWrapper|ORAResult $res
* @return mixed
*/
function fetchObject( $res ) {
return $res->fetchObject();
}
+ /**
+ * @param ResultWrapper|ORAResult $res
+ * @return mixed
+ */
function fetchRow( $res ) {
if ( $res instanceof ResultWrapper ) {
$res = $res->result;
return $res->fetchRow();
}
+ /**
+ * @param ResultWrapper|ORAResult $res
+ * @return int
+ */
function numRows( $res ) {
if ( $res instanceof ResultWrapper ) {
$res = $res->result;
return $res->numRows();
}
+ /**
+ * @param ResultWrapper|ORAResult $res
+ * @return int
+ */
function numFields( $res ) {
if ( $res instanceof ResultWrapper ) {
$res = $res->result;
return (bool)$exists;
}
+ /**
+ * @var string $table
+ * @var string $field
+ * @return PostgresField|null
+ */
function fieldInfo( $table, $field ) {
return PostgresField::fromText( $this, $table, $field );
}
public function findFileFromKey( $sha1, $options = [] ) {
$time = isset( $options['time'] ) ? $options['time'] : false;
# First try to find a matching current version of a file...
- if ( $this->fileFactoryKey ) {
- $img = call_user_func( $this->fileFactoryKey, $sha1, $this, $time );
- } else {
+ if ( !$this->fileFactoryKey ) {
return false; // find-by-sha1 not supported
}
+ $img = call_user_func( $this->fileFactoryKey, $sha1, $this, $time );
if ( $img && $img->exists() ) {
return $img;
}
*
* @param Title $title
*
- * @return bool If the specified title is not a redirect, or if it is a circular redirect
+ * @return Title|bool The final Title after following all redirects, or false if
+ * the page is not a redirect or the redirect loops.
*/
public static function getFinalDestination( $title ) {
$dbw = wfGetDB( DB_MASTER );
/**
* Build and output the actual changes list.
*
- * @param array $rows Database rows
+ * @param ResultWrapper $rows Database rows
* @param FormOptions $opts
*/
abstract public function outputChangesList( $rows, $opts );
* @ingroup SpecialPage
*/
class SpecialRandomInCategory extends FormSpecialPage {
+ /** @var string[] */
protected $extra = []; // Extra SQL statements
+ /** @var Title|false */
protected $category = false; // Title object of category
+ /** @var int */
protected $maxOffset = 30; // Max amount to fudge randomness by.
+ /** @var int|null */
private $maxTimestamp = null;
+ /** @var int|null */
private $minTimestamp = null;
public function __construct( $name = 'RandomInCategory' ) {
/**
* Build and output the actual changes list.
*
- * @param array $rows Database rows
+ * @param ResultWrapper $rows Database rows
* @param FormOptions $opts
*/
public function outputChangesList( $rows, $opts ) {
*/
protected $spawnErr = false;
+ /**
+ * @var bool|XmlDumpWriter
+ */
protected $xmlwriterobj = false;
protected $timeExceeded = false;
public $entryPoints = [ 'testSrvus', 'testPst', 'testPreprocess' ];
public $verbose = false;
+ /**
+ * @var bool|PPFuzzTest
+ */
private static $currentTest = false;
function execute() {