MediaWiki REL1_34
UnsupportedSlotDiffRenderer Class Reference

Produces a warning message about not being able to render a slot diff. More...

Inheritance diagram for UnsupportedSlotDiffRenderer:
Collaboration diagram for UnsupportedSlotDiffRenderer:

Public Member Functions

 __construct (MessageLocalizer $localizer)
 UnsupportedSlotDiffRenderer constructor.
 
 getDiff (Content $oldContent=null, Content $newContent=null)
 Get a diff between two content objects.One of them might be null (meaning a slot was created or removed), but both cannot be. $newContent (or if it's null then $oldContent) must have the same content model that was used to obtain this diff renderer.

Parameters
Content | null$oldContent
Content | null$newContent
Returns
string HTML, one or more

 
- Public Member Functions inherited from SlotDiffRenderer
 addModules (OutputPage $output)
 Add modules needed for correct styling/behavior of the diff.
 
 getExtraCacheKeys ()
 Return any extra keys to split the diff cache by.
 

Private Attributes

MessageLocalizer $localizer
 

Additional Inherited Members

- Protected Member Functions inherited from SlotDiffRenderer
 normalizeContents (Content &$oldContent=null, Content &$newContent=null, $allowedClasses=null)
 Helper method to normalize the input of getDiff().
 

Detailed Description

Produces a warning message about not being able to render a slot diff.

Since
1.34

Definition at line 31 of file UnsupportedSlotDiffRenderer.php.

Constructor & Destructor Documentation

◆ __construct()

UnsupportedSlotDiffRenderer::__construct ( MessageLocalizer  $localizer)

UnsupportedSlotDiffRenderer constructor.

Parameters
MessageLocalizer$localizer

Definition at line 43 of file UnsupportedSlotDiffRenderer.php.

References $localizer.

Member Function Documentation

◆ getDiff()

UnsupportedSlotDiffRenderer::getDiff ( Content  $oldContent = null,
Content  $newContent = null 
)

Get a diff between two content objects.One of them might be null (meaning a slot was created or removed), but both cannot be. $newContent (or if it's null then $oldContent) must have the same content model that was used to obtain this diff renderer.

Parameters
Content | null$oldContent
Content | null$newContent
Returns
string HTML, one or more

Reimplemented from SlotDiffRenderer.

Definition at line 48 of file UnsupportedSlotDiffRenderer.php.

References SlotDiffRenderer\normalizeContents().

Member Data Documentation

◆ $localizer

MessageLocalizer UnsupportedSlotDiffRenderer::$localizer
private

Definition at line 36 of file UnsupportedSlotDiffRenderer.php.

Referenced by __construct().


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