MediaWiki  REL1_24
SpecialRevisionDelete Class Reference

Special page allowing users with the appropriate permissions to view and hide revisions. More...

Inheritance diagram for SpecialRevisionDelete:
Collaboration diagram for SpecialRevisionDelete:

List of all members.

Public Member Functions

 __construct ()
 execute ($par)
 Default execute method Checks user permissions.

Protected Member Functions

 addUsageText ()
 Show some introductory text.
 buildCheckBoxes ()
 extractBitParams ()
 Put together an array that contains -1, 0, or the *_deleted const for each bit.
 failure ($status)
 Report that the submit operation failed.
 getGroupName ()
 Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.
 getList ()
 Get the list object for this request.
 getLogQueryCond ()
 Get the condition used for fetching log snippets.
 save ($bitfield, $reason, $title)
 Do the write operations.
 showConvenienceLinks ()
 Show some useful links in the subtitle.
 showForm ()
 Show a list of items that we will operate on, and show a form with checkboxes which will allow the user to choose new visibility settings.
 submit ()
 UI entry point for form submission.
 success ()
 Report that the submit operation succeeded.
 tryShowFile ($archiveName)
 Show a deleted file version requested by the visitor.

Protected Attributes

bool $wasSaved = false
 Was the DB modified in this request *.

Private Attributes

string $archiveName
 Archive name, for reviewing deleted files *.
array $checks
 Array of checkbox specs (message, name, deletion bits) *.
array $ids
 Target ID list *.
bool $mIsAllowed
 Whether user is allowed to perform the action *.
string $otherReason
 *
 $revDelList
bool $submitClicked
 True if the submit button was clicked, and the form was posted *.
Title $targetObj
 Title object for target parameter *.
string $token
 Edit token for securing image views against XSS *.
array $typeLabels
 UI Labels about the current type *.
string $typeName
 Deletion type, may be revision, archive, oldimage, filearchive, logging.

Static Private Attributes

static $UILabels
 UI labels for each type.

Detailed Description

Special page allowing users with the appropriate permissions to view and hide revisions.

Log items can also be hidden.

Definition at line 30 of file SpecialRevisiondelete.php.


Constructor & Destructor Documentation


Member Function Documentation

Show some introductory text.

Todo:
FIXME: Wikimedia-specific policy text

Definition at line 467 of file SpecialRevisiondelete.php.

Returns:
string HTML

Definition at line 486 of file SpecialRevisiondelete.php.

Default execute method Checks user permissions.

This must be overridden by subclasses; it will be made abstract in a future version

Parameters:
string | null$subPage

Reimplemented from SpecialPage.

Definition at line 101 of file SpecialRevisiondelete.php.

Put together an array that contains -1, 0, or the *_deleted const for each bit.

Returns:
array

Definition at line 628 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::failure ( status) [protected]

Report that the submit operation failed.

Parameters:
Status$status

Definition at line 616 of file SpecialRevisiondelete.php.

Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.

Returns:
string
Since:
1.21

Reimplemented from SpecialPage.

Definition at line 658 of file SpecialRevisiondelete.php.

Get the list object for this request.

Returns:
RevDelList

Definition at line 346 of file SpecialRevisiondelete.php.

Get the condition used for fetching log snippets.

Returns:
array

Definition at line 270 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::save ( bitfield,
reason,
title 
) [protected]

Do the write operations.

Simple wrapper for RevDel*List::setVisibility().

Parameters:
int$bitfield
string$reason
Title$title
Returns:
Status

Definition at line 652 of file SpecialRevisiondelete.php.

Show some useful links in the subtitle.

Definition at line 229 of file SpecialRevisiondelete.php.

Show a list of items that we will operate on, and show a form with checkboxes which will allow the user to choose new visibility settings.

Definition at line 360 of file SpecialRevisiondelete.php.

UI entry point for form submission.

Exceptions:
PermissionsError
Returns:
bool

Definition at line 558 of file SpecialRevisiondelete.php.

Report that the submit operation succeeded.

Definition at line 600 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::tryShowFile ( archiveName) [protected]

Show a deleted file version requested by the visitor.

Todo:
Mostly copied from Special:Undelete. Refactor.
Parameters:
string$archiveName

Definition at line 286 of file SpecialRevisiondelete.php.


Member Data Documentation

string SpecialRevisionDelete::$archiveName [private]

Archive name, for reviewing deleted files *.

Definition at line 37 of file SpecialRevisiondelete.php.

array SpecialRevisionDelete::$checks [private]

Array of checkbox specs (message, name, deletion bits) *.

Definition at line 45 of file SpecialRevisiondelete.php.

array SpecialRevisionDelete::$ids [private]

Target ID list *.

Definition at line 35 of file SpecialRevisiondelete.php.

bool SpecialRevisionDelete::$mIsAllowed [private]

Whether user is allowed to perform the action *.

Definition at line 52 of file SpecialRevisiondelete.php.

string SpecialRevisionDelete::$otherReason [private]

*

Definition at line 54 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$revDelList [private]

Definition at line 50 of file SpecialRevisiondelete.php.

bool SpecialRevisionDelete::$submitClicked [private]

True if the submit button was clicked, and the form was posted *.

Definition at line 33 of file SpecialRevisiondelete.php.

Title SpecialRevisionDelete::$targetObj [private]

Title object for target parameter *.

Definition at line 41 of file SpecialRevisiondelete.php.

string SpecialRevisionDelete::$token [private]

Edit token for securing image views against XSS *.

Definition at line 39 of file SpecialRevisiondelete.php.

array SpecialRevisionDelete::$typeLabels [private]

UI Labels about the current type *.

Definition at line 47 of file SpecialRevisiondelete.php.

string SpecialRevisionDelete::$typeName [private]

Deletion type, may be revision, archive, oldimage, filearchive, logging.

*

Definition at line 43 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$UILabels [static, private]

UI labels for each type.

Definition at line 59 of file SpecialRevisiondelete.php.

bool SpecialRevisionDelete::$wasSaved = false [protected]

Was the DB modified in this request *.

Definition at line 31 of file SpecialRevisiondelete.php.


The documentation for this class was generated from the following file: