MediaWiki REL1_39
MediaWiki\Content\Transform\ContentTransformer Class Reference

A service to transform content. More...

Public Member Functions

 __construct (IContentHandlerFactory $contentHandlerFactory)
 
 preloadTransform (Content $content, PageReference $page, ParserOptions $parserOptions, array $params=[])
 Returns a Content object with preload transformations applied (or $content if no transformations apply).
 
 preSaveTransform (Content $content, PageReference $page, UserIdentity $user, ParserOptions $parserOptions)
 Returns a Content object with pre-save transformations applied (or $content if no transformations apply).
 

Detailed Description

A service to transform content.

Since
1.37

Definition at line 15 of file ContentTransformer.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\Content\Transform\ContentTransformer::__construct ( IContentHandlerFactory $contentHandlerFactory)
Parameters
IContentHandlerFactory$contentHandlerFactory

Definition at line 22 of file ContentTransformer.php.

Member Function Documentation

◆ preloadTransform()

MediaWiki\Content\Transform\ContentTransformer::preloadTransform ( Content $content,
PageReference $page,
ParserOptions $parserOptions,
array $params = [] )

Returns a Content object with preload transformations applied (or $content if no transformations apply).

Parameters
Content$content
PageReference$page
ParserOptions$parserOptions
array$params
Returns
Content

Definition at line 60 of file ContentTransformer.php.

◆ preSaveTransform()

MediaWiki\Content\Transform\ContentTransformer::preSaveTransform ( Content $content,
PageReference $page,
UserIdentity $user,
ParserOptions $parserOptions )

Returns a Content object with pre-save transformations applied (or $content if no transformations apply).

Parameters
Content$content
PageReference$page
UserIdentity$user
ParserOptions$parserOptions
Returns
Content

Definition at line 37 of file ContentTransformer.php.


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