MediaWiki  master
ProtectionForm Class Reference

Handles the page protection UI and backend. More...

Collaboration diagram for ProtectionForm:

Public Member Functions

 __construct (Article $article)
 
 execute ()
 Main entry point for action=protect and action=unprotect. More...
 

Protected Attributes

bool $disabled
 
array $disabledAttrib
 
array $mApplicableTypes = []
 Types (i.e. More...
 
Article $mArticle
 
bool $mCascade = false
 True if the restrictions are cascading, from request or existing protection. More...
 
array $mExistingExpiry = []
 Map of action to the expiry time of the existing protection. More...
 
array $mExpiry = []
 Map of action to "other" expiry time. More...
 
array $mExpirySelection = []
 Map of action to value selected in expiry drop-down list. More...
 
PermissionStatus $mPermStatus
 Permissions errors for the protect action. More...
 
string $mReason = ''
 The custom/additional protection reason. More...
 
string $mReasonSelection = ''
 The reason selected from the list, blank for other/additional. More...
 
array $mRestrictions = []
 A map of action to restriction level, from request or default. More...
 
Title $mTitle
 

Detailed Description

Handles the page protection UI and backend.

Definition at line 37 of file ProtectionForm.php.

Constructor & Destructor Documentation

◆ __construct()

ProtectionForm::__construct ( Article  $article)

Definition at line 112 of file ProtectionForm.php.

References Article\getContext(), and Article\getTitle().

Member Function Documentation

◆ execute()

ProtectionForm::execute ( )

Main entry point for action=protect and action=unprotect.

Definition at line 240 of file ProtectionForm.php.

Member Data Documentation

◆ $disabled

bool ProtectionForm::$disabled
protected

Definition at line 75 of file ProtectionForm.php.

◆ $disabledAttrib

array ProtectionForm::$disabledAttrib
protected

Definition at line 78 of file ProtectionForm.php.

◆ $mApplicableTypes

array ProtectionForm::$mApplicableTypes = []
protected

Types (i.e.

actions) for which levels can be selected

Definition at line 63 of file ProtectionForm.php.

◆ $mArticle

Article ProtectionForm::$mArticle
protected

Definition at line 69 of file ProtectionForm.php.

◆ $mCascade

bool ProtectionForm::$mCascade = false
protected

True if the restrictions are cascading, from request or existing protection.

Definition at line 48 of file ProtectionForm.php.

◆ $mExistingExpiry

array ProtectionForm::$mExistingExpiry = []
protected

Map of action to the expiry time of the existing protection.

Definition at line 66 of file ProtectionForm.php.

◆ $mExpiry

array ProtectionForm::$mExpiry = []
protected

Map of action to "other" expiry time.

Used in preference to mExpirySelection.

Definition at line 51 of file ProtectionForm.php.

◆ $mExpirySelection

array ProtectionForm::$mExpirySelection = []
protected

Map of action to value selected in expiry drop-down list.

Will be set to 'othertime' whenever mExpiry is set.

Definition at line 57 of file ProtectionForm.php.

◆ $mPermStatus

PermissionStatus ProtectionForm::$mPermStatus
protected

Permissions errors for the protect action.

Definition at line 60 of file ProtectionForm.php.

◆ $mReason

string ProtectionForm::$mReason = ''
protected

The custom/additional protection reason.

Definition at line 42 of file ProtectionForm.php.

◆ $mReasonSelection

string ProtectionForm::$mReasonSelection = ''
protected

The reason selected from the list, blank for other/additional.

Definition at line 45 of file ProtectionForm.php.

◆ $mRestrictions

array ProtectionForm::$mRestrictions = []
protected

A map of action to restriction level, from request or default.

Definition at line 39 of file ProtectionForm.php.

◆ $mTitle

Title ProtectionForm::$mTitle
protected

Definition at line 72 of file ProtectionForm.php.


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