MediaWiki  REL1_22
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.

Static Public Member Functions

static extractBitfield ($bitPars, $oldfield)
 Put together a rev_deleted bitfield.

Public Attributes

 $archiveName
 Archive name, for reviewing deleted files.
 $checks
 Array of checkbox specs (message, name, deletion bits)
 $ids
 Target ID list.
 $list
 The RevDel_List object, storing the list of items to be deleted/undeleted.
 $submitClicked
 True if the submit button was clicked, and the form was posted.
 $targetObj
 Title object for target parameter.
 $token
 Edit token for securing image views against XSS.
 $typeLabels
 UI Labels about the current type.
 $typeName
 Deletion type, may be revision, archive, oldimage, filearchive, logging.

Static Public Attributes

static $UILabels
 UI labels for each type.

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.

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

References SpecialPage\getOutput(), and SpecialPage\getUser().

Referenced by showForm().

static SpecialRevisionDelete::extractBitfield ( bitPars,
oldfield 
) [static]

Put together a rev_deleted bitfield.

Deprecated:
since 1.22, use RevisionDeleter::extractBitfield instead
Parameters:
array$bitParsextractBitParams() params
int$oldfieldcurrent bitfield
Returns:
array

Definition at line 564 of file SpecialRevisiondelete.php.

Referenced by buildCheckBoxes().

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

Returns:
array

Definition at line 541 of file SpecialRevisiondelete.php.

References $name, array(), as, Revision\DELETED_RESTRICTED, SpecialPage\getRequest(), and list.

Referenced by buildCheckBoxes(), and submit().

SpecialRevisionDelete::failure ( status) [protected]

Report that the submit operation failed.

Definition at line 530 of file SpecialRevisiondelete.php.

References SpecialPage\getOutput(), SpecialPage\msg(), and showForm().

Referenced by submit().

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

Get the list object for this request.

Definition at line 301 of file SpecialRevisiondelete.php.

References RevisionDeleter\createList(), SpecialPage\getContext(), and list.

Referenced by buildCheckBoxes(), getLogQueryCond(), save(), and showForm().

Get the condition used for fetching log snippets.

Returns:
array

Definition at line 232 of file SpecialRevisiondelete.php.

References array(), getList(), and RevisionDeleter\getRelationType().

Referenced by execute().

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

Do the write operations.

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

Parameters:
$bitfield
$reason
$title
Returns:

Definition at line 575 of file SpecialRevisiondelete.php.

References array(), and getList().

Referenced by submit().

Report that the submit operation succeeded.

Definition at line 520 of file SpecialRevisiondelete.php.

References SpecialPage\getOutput(), list, SpecialPage\msg(), and showForm().

Referenced by submit().


Member Data Documentation

SpecialRevisionDelete::$archiveName

Archive name, for reviewing deleted files.

Definition at line 38 of file SpecialRevisiondelete.php.

Referenced by tryShowFile().

SpecialRevisionDelete::$checks

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

Definition at line 50 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$ids

Target ID list.

Definition at line 35 of file SpecialRevisiondelete.php.

Referenced by execute().

SpecialRevisionDelete::$list

The RevDel_List object, storing the list of items to be deleted/undeleted.

Definition at line 56 of file SpecialRevisiondelete.php.

Referenced by buildCheckBoxes(), and showForm().

SpecialRevisionDelete::$submitClicked

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

Definition at line 32 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$targetObj

Title object for target parameter.

Definition at line 44 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$token

Edit token for securing image views against XSS.

Definition at line 41 of file SpecialRevisiondelete.php.

Referenced by submit().

SpecialRevisionDelete::$typeLabels

UI Labels about the current type.

Definition at line 53 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$typeName

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

Definition at line 47 of file SpecialRevisiondelete.php.

SpecialRevisionDelete::$UILabels [static]
Initial value:
 array(
        'revision' => array(
            'check-label'   => 'revdelete-hide-text',
            'success'       => 'revdelete-success',
            'failure'       => 'revdelete-failure',
        ),
        'archive' => array(
            'check-label'   => 'revdelete-hide-text',
            'success'       => 'revdelete-success',
            'failure'       => 'revdelete-failure',
        ),
        'oldimage' => array(
            'check-label'   => 'revdelete-hide-image',
            'success'       => 'revdelete-success',
            'failure'       => 'revdelete-failure',
        ),
        'filearchive' => array(
            'check-label'   => 'revdelete-hide-image',
            'success'       => 'revdelete-success',
            'failure'       => 'revdelete-failure',
        ),
        'logging' => array(
            'check-label'   => 'revdelete-hide-name',
            'success'       => 'logdelete-success',
            'failure'       => 'logdelete-failure',
        ),
    )

UI labels for each type.

Definition at line 61 of file SpecialRevisiondelete.php.


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