MediaWiki master
MediaWiki\Content\Renderer\ContentRenderer Class Reference

A service to render content. More...

Public Member Functions

 __construct (IContentHandlerFactory $contentHandlerFactory, GlobalIdGenerator $globalIdGenerator)
 
 getParserOutput (Content $content, PageReference $page, $revision=null, ?ParserOptions $parserOptions=null, $hints=[])
 Returns a ParserOutput object containing information derived from this content.
 

Detailed Description

A service to render content.

Since
1.38

Definition at line 17 of file ContentRenderer.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\Content\Renderer\ContentRenderer::__construct ( IContentHandlerFactory $contentHandlerFactory,
GlobalIdGenerator $globalIdGenerator )
Parameters
IContentHandlerFactory$contentHandlerFactory
GlobalIdGenerator$globalIdGenerator

Definition at line 27 of file ContentRenderer.php.

Member Function Documentation

◆ getParserOutput()

MediaWiki\Content\Renderer\ContentRenderer::getParserOutput ( Content $content,
PageReference $page,
$revision = null,
?ParserOptions $parserOptions = null,
$hints = [] )

Returns a ParserOutput object containing information derived from this content.

Parameters
Content$content
PageReference$page
RevisionRecord | null$revision
ParserOptions | null$parserOptions
bool|array{generate-html?:bool,previous-output?:?ParserOutput}$hints For back-compatibility, passing a bool is equivalent to setting the 'generate-html' hint.
Returns
ParserOutput
Note
Passing an integer as $rev was deprecated in MW 1.42

Definition at line 49 of file ContentRenderer.php.

References wfDeprecated().


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