MediaWiki REL1_39
ProfilerOutputText Class Reference

Adds profiler output to the HTTP response. More...

Inheritance diagram for ProfilerOutputText:
Collaboration diagram for ProfilerOutputText:

Public Member Functions

 __construct (Profiler $collector, array $params)
 
 log (array $stats)
 Log MediaWiki-style profiling data.
 
 logsToOutput ()
 May the log() try to write to standard output?
 
- Public Member Functions inherited from ProfilerOutput
 canUse ()
 Can this output type be used?
 

Additional Inherited Members

- Protected Attributes inherited from ProfilerOutput
Profiler $collector
 
LoggerInterface $logger
 
array $params
 Configuration of $wgProfiler.
 

Detailed Description

Adds profiler output to the HTTP response.

The least sophisticated profiler output class possible, view source! :)

Since
1.25

Definition at line 29 of file ProfilerOutputText.php.

Constructor & Destructor Documentation

◆ __construct()

ProfilerOutputText::__construct ( Profiler $collector,
array $params )
Parameters
Profiler$collectorThe actual profiler
array$paramsConfiguration array, passed down from $wgProfiler

Reimplemented from ProfilerOutput.

Definition at line 36 of file ProfilerOutputText.php.

References ProfilerOutput\$collector, and ProfilerOutput\$params.

Member Function Documentation

◆ log()

ProfilerOutputText::log ( array $stats)

Log MediaWiki-style profiling data.

For classes that enable logsToOutput(), this must not be called unless Profiler::setAllowOutput is enabled.

Parameters
array$statsResult of Profiler::getFunctionStats()

Reimplemented from ProfilerOutput.

Definition at line 46 of file ProfilerOutputText.php.

References print, and wfIsCLI().

◆ logsToOutput()

ProfilerOutputText::logsToOutput ( )

May the log() try to write to standard output?

Returns
bool
Since
1.33

Reimplemented from ProfilerOutput.

Definition at line 42 of file ProfilerOutputText.php.


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