/**
* Update the page record to point to a newly saved revision.
*
- * @param $dbw Database object
+ * @param $dbw DatabaseBase: object
* @param $revision Revision: For ID number, and text used to set
length and redirect status fields
* @param $lastRevision Integer: if given, will not overwrite the page field
* Every 100th edit, prune the recent changes table.
*
* @private
- * @param $text New text of the article
- * @param $summary Edit summary
- * @param $minoredit Minor edit
+ * @param $text String: New text of the article
+ * @param $summary String: Edit summary
+ * @param $minoredit Boolean: Minor edit
* @param $timestamp_of_pagechange Timestamp associated with the page change
- * @param $newid rev_id value of the new revision
- * @param $changed Whether or not the content actually changed
+ * @param $newid Integer: rev_id value of the new revision
+ * @param $changed Boolean: Whether or not the content actually changed
*/
public function editUpdates( $text, $summary, $minoredit, $timestamp_of_pagechange, $newid, $changed = true ) {
global $wgDeferredUpdateList, $wgMessageCache, $wgUser, $wgEnableParserCache;
* This will only return the very next target, useful for
* the redirect table and other checks that don't need full recursion
*
- * @param $text \type{\string} Text with possible redirect
- * @return \type{Title} The corresponding Title
+ * @param $text String: Text with possible redirect
+ * @return Title: The corresponding Title
*/
public static function newFromRedirect( $text ) {
return self::newFromRedirectInternal( $text );
/**
* Get the main part with underscores
*
- * @return \type{\string} Main part of the title, with underscores
+ * @return Stromg: Main part of the title, with underscores
*/
public function getDBkey() { return $this->mDbkeyform; }
/**
* Get the namespace index, i.e.\ one of the NS_xxxx constants.
*
- * @return \type{\int} Namespace index
+ * @return Integer: Namespace index
*/
public function getNamespace() { return $this->mNamespace; }
/**
* Get the namespace text
*
- * @return \type{\string} Namespace text
+ * @return String: Namespace text
*/
public function getNsText() {
global $wgContLang;
* In other words, is this a content page, for the purposes of calculating
* statistics, etc?
*
- * @return \type{\bool}
+ * @return Boolean
*/
public function isContentPage() {
return MWNamespace::isContent( $this->getNamespace() );
/**
* Check if user is allowed to access a feature / make an action
* @param $action \string action to be checked
- * @return \bool True if action is allowed, else false
+ * @return Boolean: True if action is allowed, else false
*/
function isAllowed( $action = '' ) {
if ( $action === '' )
/**
* Check whether to enable recent changes patrol features for this user
- * @return \bool True or false
+ * @return Boolean: True or false
*/
public function useRCPatrol() {
global $wgUseRCPatrol;
/**
* Get whether the user is blocked from using Special:Emailuser.
- * @return \bool True if blocked
+ * @return Boolean: True if blocked
*/
function isBlockedFromEmailuser() {
$this->getBlockedStatus();
/**
* Get whether the user is allowed to create an account.
- * @return \bool True if allowed
+ * @return Boolean: True if allowed
*/
function isAllowedToCreateAccount() {
return $this->isAllowed( 'createaccount' ) && !$this->isBlockedFromCreateAccount();
/**
* Get this user's personal page title.
*
- * @return \type{Title} User's personal page title
+ * @return Title: User's personal page title
*/
function getUserPage() {
return Title::makeTitle( NS_USER, $this->getName() );
/**
* Get this user's talk page title.
*
- * @return \type{Title} User's talk page title
+ * @return Title: User's talk page title
*/
function getTalkPage() {
$title = $this->getUserPage();
/**
* Get the maximum valid user ID.
- * @return \int User ID
+ * @return Integer: User ID
* @static
*/
function getMaxID() {
/**
* Determine whether the user is a newbie. Newbies are either
* anonymous IPs, or the most recently created accounts.
- * @return \bool True if the user is a newbie
+ * @return Boolean: True if the user is a newbie
*/
function isNewbie() {
return !$this->isAllowed( 'autoconfirmed' );
/**
* Check to see if the given clear-text password is one of the accepted passwords
- * @param $password \string user password.
- * @return \bool True if the given password is correct, otherwise False.
+ * @param $password String: user password.
+ * @return Boolean: True if the given password is correct, otherwise False.
*/
function checkPassword( $password ) {
global $wgAuth;
/**
* Check if the given clear-text password matches the temporary password
* sent by e-mail for password reset operations.
- * @return \bool True if matches, false otherwise
+ * @return Boolean: True if matches, false otherwise
*/
function checkTemporaryPassword( $plaintext ) {
global $wgNewPasswordExpiry;
*
* @param $val \string Input value to compare
* @param $salt \string Optional function-specific data for hashing
- * @return \bool Whether the token matches
+ * @return Boolean: Whether the token matches
*/
function matchEditToken( $val, $salt = '' ) {
$sessionToken = $this->editToken( $salt );
*
* @param $val \string Input value to compare
* @param $salt \string Optional function-specific data for hashing
- * @return \bool Whether the token matches
+ * @return Boolean: Whether the token matches
*/
function matchEditTokenNoSuffix( $val, $salt = '' ) {
$sessionToken = $this->editToken( $salt );
/**
* Is this user allowed to send e-mails within limits of current
* site configuration?
- * @return \bool True if allowed
+ * @return Boolean: True if allowed
*/
function canSendEmail() {
global $wgEnableEmail, $wgEnableUserEmail;
/**
* Is this user allowed to receive e-mails within limits of current
* site configuration?
- * @return \bool True if allowed
+ * @return Boolean: True if allowed
*/
function canReceiveEmail() {
return $this->isEmailConfirmed() && !$this->getOption( 'disablemail' );
* confirmed their address by returning a code or using a password
* sent to the address from the wiki.
*
- * @return \bool True if confirmed
+ * @return Boolean: True if confirmed
*/
function isEmailConfirmed() {
global $wgEmailAuthentication;
/**
* Check whether there is an outstanding request for e-mail confirmation.
- * @return \bool True if pending
+ * @return Boolean: True if pending
*/
function isEmailConfirmationPending() {
global $wgEmailAuthentication;
* @param $hash \string Password hash
* @param $password \string Plain-text password to compare
* @param $userId \string User ID for old-style password salt
- * @return \bool
+ * @return Boolean:
*/
static function comparePasswords( $hash, $password, $userId = false ) {
$type = substr( $hash, 0, 3 );