MediaWiki  1.28.0
RevisionItem Class Reference

Item class for a live revision table row. More...

Inheritance diagram for RevisionItem:
Collaboration diagram for RevisionItem:

Public Member Functions

 __construct ($list, $row)
 
 canView ()
 
 canViewContent ()
 
 getAuthorIdField ()
 
 getAuthorNameField ()
 
 getHTML ()
 
 getIdField ()
 
 getTimestampField ()
 
 isDeleted ()
 
- Public Member Functions inherited from RevisionItemBase
 __construct ($list, $row)
 
 canView ()
 Returns true if the current user can view the item. More...
 
 canViewContent ()
 Returns true if the current user can view the item text/file. More...
 
 formatDate ()
 Get the date, formatted in user's language. More...
 
 formatTime ()
 Get the time, formatted in user's language. More...
 
 getAuthorId ()
 Get the author user ID. More...
 
 getAuthorIdField ()
 Get the DB field name storing user ids. More...
 
 getAuthorName ()
 Get the author user name. More...
 
 getAuthorNameField ()
 Get the DB field name storing user names. More...
 
 getHTML ()
 Get the HTML of the list item. More...
 
 getId ()
 Get the ID, as it would appear in the ids URL parameter. More...
 
 getIdField ()
 Get the DB field name associated with the ID list. More...
 
 getTimestamp ()
 Get the timestamp in MW 14-char form. More...
 
 getTimestampField ()
 Get the DB field name storing timestamps. More...
 

Protected Member Functions

 getDiffLink ()
 Get the HTML link to the diff. More...
 
 getRevisionLink ()
 Get the HTML link to the revision text. More...
 

Protected Attributes

RequestContext $context
 
Revision $revision
 
- Protected Attributes inherited from RevisionItemBase
RevisionListBase $list
 The parent. More...
 
 $row
 The database result row. More...
 

Detailed Description

Item class for a live revision table row.

Definition at line 307 of file RevisionList.php.

Constructor & Destructor Documentation

RevisionItem::__construct (   $list,
  $row 
)

Member Function Documentation

RevisionItem::canView ( )

Definition at line 336 of file RevisionList.php.

References Revision\DELETED_RESTRICTED, and revision.

RevisionItem::canViewContent ( )

Definition at line 340 of file RevisionList.php.

References Revision\DELETED_TEXT, and revision.

Referenced by getDiffLink(), and getRevisionLink().

RevisionItem::getAuthorIdField ( )

Definition at line 328 of file RevisionList.php.

RevisionItem::getAuthorNameField ( )

Definition at line 332 of file RevisionList.php.

RevisionItem::getDiffLink ( )
protected

Get the HTML link to the diff.

Todo:
Essentially a copy of RevDelRevisionItem::getDiffLink. That class should inherit from this one, and implement an appropriate interface instead of extending RevDelItem
Returns
string

Definition at line 380 of file RevisionList.php.

References canViewContent(), isDeleted(), Linker\linkKnown(), list, and revision.

Referenced by ChangeTagsRevisionItem\getHTML(), and getHTML().

RevisionItem::getHTML ( )
Todo:
Essentially a copy of RevDelRevisionItem::getHTML. That class should inherit from this one, and implement an appropriate interface instead of extending RevDelItem
Returns
string

Definition at line 403 of file RevisionList.php.

References $comment, getDiffLink(), getRevisionLink(), isDeleted(), Linker\revComment(), revision, and Linker\revUserLink().

RevisionItem::getIdField ( )

Definition at line 320 of file RevisionList.php.

RevisionItem::getRevisionLink ( )
protected

Get the HTML link to the revision text.

Todo:
Essentially a copy of RevDelRevisionItem::getRevisionLink. That class should inherit from this one, and implement an appropriate interface instead of extending RevDelItem
Returns
string

Definition at line 355 of file RevisionList.php.

References canViewContent(), ParserOutput\getTimestamp(), isDeleted(), Linker\linkKnown(), list, and revision.

Referenced by ChangeTagsRevisionItem\getHTML(), and getHTML().

RevisionItem::getTimestampField ( )

Definition at line 324 of file RevisionList.php.

RevisionItem::isDeleted ( )

Member Data Documentation

RequestContext RevisionItem::$context
protected

Definition at line 312 of file RevisionList.php.

Revision RevisionItem::$revision
protected

Definition at line 309 of file RevisionList.php.


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