* - If there are multiple exact or range blocks at the same level, the one chosen
* is random
*
+ * @param array $blocks Array of blocks
* @param array $ipChain List of IPs (strings). This is used to determine how "close"
* a block is to the server, and if a block matches exactly, or is in a range.
* The order is furthest from the server to nearest e.g., (Browser, proxy1, proxy2,
* local-squid, ...)
- * @param array $block Array of blocks
* @return Block|null The "best" block from the list
*/
public static function chooseBlock( array $blocks, array $ipChain ) {
/**
* Parsing RC_* constants to human-readable test
* @since 1.24
- * @param int $rc_type
+ * @param int $rcType
* @return string $type
*/
public static function parseFromRCType( $rcType ) {
* Sanitize and filter the custom headers from a $params array.
* We only allow certain Content- and X-Content- headers.
*
- * @param array $headers
+ * @param array $params
* @return array Sanitized value of 'headers' field in $params
*/
protected function sanitizeHdrs( array $params ) {
* @note Use getWidth()/getHeight() instead of this method unless you have a
* a good reason. This method skips all caches.
*
- * @param string $fileName The path to the file (e.g. From getLocalPathRef() )
+ * @param string $filePath The path to the file (e.g. From getLocalPathRef() )
* @return array The width, followed by height, with optionally more things after
*/
function getImageSize( $filePath ) {
* @param string $tableName The table name
* @param string $oldIndexName The old index name
* @param string $newIndexName The new index name
+ * @param string $sqlPath The path to the SQL change path
* @param bool $skipBothIndexExistWarning Whether to warn if both the old
* and the new indexes exist. [facultative; by default, false]
- * @param string $sqlPath The path to the SQL change path
*/
public function renameExtensionIndex( $tableName, $oldIndexName, $newIndexName,
$sqlPath, $skipBothIndexExistWarning = false
/**
* Try to see if a given fulltext catalog exists
* We assume we already have the appropriate database selected
- * @param string $schemaName Catalog name to check
+ * @param string $catalogName Catalog name to check
* @return bool
*/
private function catalogExists( $catalogName ) {
/** Add misc metadata. Warning: atm if the metadata category
* doesn't have a priority, it will be silently discarded.
*
- * @param array $meta Array of metadata values
+ * @param array $metaArray Array of metadata values
* @param string $type Type. defaults to other. if two things have the same type they're merged
*/
function addMetadata( $metaArray, $type = 'other' ) {
*
* @param File $file The image object, or false if there isn't one.
* Warning, FSFile::getPropsFromPath might pass an (object)array() instead (!)
- * @param string $path The filename
+ * @param string $filename The filename
* @return string
*/
public function getMetadata( $file, $filename ) {
}
/**
- * @param string $key
* @param mixed $casToken
+ * @param string $key
* @param mixed $value
* @param int $exptime
* @return bool
* Store a value in the WinCache object cache
*
* @param string $key Cache key
- * @param mixed $valueObject Value to store
+ * @param mixed $value Value to store
* @param int $expire Expiration time
* @return bool
*/
* @param Content $content Content submitted
* @param User $user The relevant user
* @param string $comment Comment submitted
- * @param string $serialisation_format Format for storing the content in the database
* @param bool $minor Whereas it's a minor modification
+ * @param string $serialisation_format Format for storing the content in the database
*/
public function doQuickEditContent( Content $content, User $user, $comment = '', $minor = false,
$serialisation_format = null
/**
* @param Page $page
+ * @param ParserOptions $parserOptions ParserOptions to use for the parse
* @param int $revid ID of the revision being parsed.
* @param bool $useParserCache Whether to use the parser cache.
- * @param ParserOptions $parserOptions ParserOptions to use for the parse
* operation.
* @param Content|string $content Content to parse or null to load it; may
* also be given as a wikitext string, for BC.
* Suggest a target for the revision deletion
* @since 1.22
* @param string $typeName
- * @param Title|null $title User-supplied target
+ * @param Title|null $target User-supplied target
* @param array $ids
* @return Title|null
*/
/**
* Divide the element name passed by the xml parser to the callback into URI and prifix.
- * @param string $name
+ * @param string $element
* @return array Containing the namespace URI and prefix
*/
private static function splitXmlNamespace( $element ) {
* and the SKM (source key material) is the "data".
*
* @param string $hash The hashing function to use (e.g., sha256)
- * @param string $ikm The input keying material
* @param string $salt The salt to add to the ikm, to get the prk
+ * @param string $ikm The input keying material
* @return string Binary string (pseudorandm key) used as input to HKDFExpand
*/
private static function HKDFExtract( $hash, $salt, $ikm ) {
}
/**
- * @param array $time (UIDGenerator::millitime(), clock sequence)
+ * @param array $info (UIDGenerator::millitime(), clock sequence)
* @return string 88 bits
*/
protected function getTimestampedID88( array $info ) {
/**
* Returns true if a language code is an IETF tag known to MediaWiki.
*
- * @param string $code
+ * @param string $tag
*
* @since 1.21
* @return bool
* Checks that convertPlural was given an array and pads it to requested
* amount of forms by copying the last one.
*
- * @param int $count How many forms should there be at least
* @param array $forms Array of forms given to convertPlural
+ * @param int $count How many forms should there be at least
* @return array Padded array of forms or an exception if not an array
*/
protected function preConvertPlural( /* Array */ $forms, $count ) {
/**
* @todo Do this for real
- * @param int $ns
- * @param string $name
+ * @param int $key
+ * @param string $prefix
* @param bool $fix
* @param string $suffix
* @return bool
/**
* @dataProvider providerGetDisplayWidthHeight
- * @param array $dimensions Array [maxWidth, maxHeight, width, height]
+ * @param array $dim Array [maxWidth, maxHeight, width, height]
* @param array $expected Array [width, height] The width and height we expect to display at
*/
function testGetDisplayWidthHeight( $dim, $expected ) {
* @param array $params Api parameters
* @param int $expectedCount Max number of iterations
* @param string $id Unit test id
- * @param bool $useContinue True to use smart continue
+ * @param bool $continue True to use smart continue
* @return Merged results data array
*/
protected function checkC( $expected, $params, $expectedCount, $id, $continue = true ) {
* @param string $titlePart
* @param int $namespace
* @param string $expected
- * @param string $description
+ * @param string $expectException
* @dataProvider provideTestTitlePartToKey
*/
function testTitlePartToKey( $titlePart, $namespace, $expected, $expectException ) {
/**
* @param string $filename
* @param int $expectedWidth Width
- * @param int $expectedHeigh Height
+ * @param int $expectedHeight Height
* @dataProvider provideGetImageSize
* @covers XCFHandler::getImageSize
*/
*
* @param Page $page Page to add the revision to
* @param string $text Revisions text
- * @param string $text Revisions summare
+ * @param string $summary Revisions summare
*
* @throws MWException
*/
* Asserts that the xml reader is at the final closing tag of an xml file and
* closes the reader.
*
- * @param string $tag (optional) the name of the final tag
+ * @param string $name (optional) the name of the final tag
* (e.g.: "mediawiki" for </mediawiki>)
*/
protected function assertDumpEnd( $name = "mediawiki" ) {
* @param string $text_sha1 The base36 SHA-1 of the revision's text
* @param string|bool $text (optional) The revision's string, or false to check for a
* revision stub
+ * @param int|bool $parentid (optional) id of the parent revision
* @param string $model The expected content model id (default: CONTENT_MODEL_WIKITEXT)
* @param string $format The expected format model id (default: CONTENT_FORMAT_WIKITEXT)
- * @param int|bool $parentid (optional) id of the parent revision
*/
protected function assertRevision( $id, $summary, $text_id, $text_bytes,
$text_sha1, $text = false, $parentid = false,
*
* @param WikiPage $page The page to add the revision to
* @param string $text The revisions text
- * @param string $text The revisions summare
+ * @param string $summary The revisions summare
*
* @throws MWException
*/
* Throw an exception if it is not set, referencing current section
* and adding the current file name and line number
*
- * @param string|array $token Expected token(s) that should have been
+ * @param string|array $tokens Expected token(s) that should have been
* mentioned before closing this section
* @param bool $fatal True iff an exception should be thrown if
* the section is not found.
/**
* Similar to ParserTest object but does not run anything
* Use unleash() to really execute the hook function
- * @param string $fnHook
+ * @param string $hook
*/
public function requireTransparentHook( $hook ) {
$this->transparentHooks[] = $hook;
* file handler.
*
* @param File $file File object for file in question
- * @param array $param Array of parameters so far
+ * @param array $params Array of parameters so far
* @return array Parameters array with more parameters
*/
function wfExtractThumbParams( $file, $params ) {