MediaWiki master
MediaWiki\OutputTransform\Stages\HandleTOCMarkers Class Reference

Inject table of contents (or empty string if there's no sections) More...

Inherits MediaWiki\OutputTransform\ContentTextTransformStage.

Collaboration diagram for MediaWiki\OutputTransform\Stages\HandleTOCMarkers:

Public Member Functions

 __construct (ServiceOptions $options, LoggerInterface $logger, TidyDriverBase $tidy)
 shouldRun (ParserOutput $po, ?ParserOptions $popts, array $options=[])
 Decides whether or not the stage should be run.
- Public Member Functions inherited from MediaWiki\OutputTransform\ContentTextTransformStage
 transform (ParserOutput $po, ?ParserOptions $popts, array &$options)
 Transforms the input ParserOutput into the returned ParserOutput.
- Public Member Functions inherited from MediaWiki\OutputTransform\OutputTransformStage
 __construct (ServiceOptions $options, LoggerInterface $logger)

Protected Member Functions

 transformText (string $text, ParserOutput $po, ?ParserOptions $popts, array &$options)

Additional Inherited Members

- Public Attributes inherited from MediaWiki\OutputTransform\OutputTransformStage
- Protected Attributes inherited from MediaWiki\OutputTransform\OutputTransformStage
LoggerInterface $logger
ServiceOptions $options

Detailed Description

Inject table of contents (or empty string if there's no sections)

Access: internal

Definition at line 24 of file HandleTOCMarkers.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\OutputTransform\Stages\HandleTOCMarkers::__construct ( ServiceOptions $options,
LoggerInterface $logger,
TidyDriverBase $tidy )

Member Function Documentation

◆ shouldRun()

MediaWiki\OutputTransform\Stages\HandleTOCMarkers::shouldRun ( ParserOutput $po,
?ParserOptions $popts,
array $options = [] )

Decides whether or not the stage should be run.

Stability: unstable
ParserOptions | null$popts

Reimplemented from MediaWiki\OutputTransform\OutputTransformStage.

Definition at line 35 of file HandleTOCMarkers.php.

◆ transformText()

MediaWiki\OutputTransform\Stages\HandleTOCMarkers::transformText ( string $text,
ParserOutput $po,
?ParserOptions $popts,
array & $options )

Reimplemented from MediaWiki\OutputTransform\ContentTextTransformStage.

Definition at line 39 of file HandleTOCMarkers.php.

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