MediaWiki  REL1_23
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, calls the function given in mFunction.

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
 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
 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 442 of file SpecialRevisiondelete.php.

Returns:
String: HTML

Definition at line 456 of file SpecialRevisiondelete.php.

References SpecialPage\getOutput().

Default execute method Checks user permissions, calls the function given in mFunction.

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 578 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::failure ( status) [protected]

Report that the submit operation failed.

Definition at line 566 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 608 of file SpecialRevisiondelete.php.

Get the list object for this request.

Definition at line 328 of file SpecialRevisiondelete.php.

Get the condition used for fetching log snippets.

Returns:
array

Definition at line 256 of file SpecialRevisiondelete.php.

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

Do the write operations.

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

Parameters:
$bitfield
$reason
$title
Returns:
Status

Definition at line 602 of file SpecialRevisiondelete.php.

Show some useful links in the subtitle.

Definition at line 215 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 342 of file SpecialRevisiondelete.php.

UI entry point for form submission.

Exceptions:
PermissionsError
Returns:
bool

Definition at line 516 of file SpecialRevisiondelete.php.

Report that the submit operation succeeded.

Definition at line 554 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::tryShowFile ( archiveName) [protected]

Show a deleted file version requested by the visitor.

TODO Mostly copied from Special:Undelete. Refactor.

Definition at line 271 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]

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]

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: