Jet\Debug_Profiler_Run
This class represents the application runtime. It aggregates all runtime information and blocks. In fact, it is the output from Profiler.
Method Overview
Method | Meaning |
---|---|
public __construct() | The constructor has no parameters, but performs the overall initialization. It collects the necessary information, and if XHProf is available, it activates it and creates the root run block. |
public getId(): string | Each run has its own unique ID. This is a hash including the URL of the request, time, and random numbers. |
public getXHPData(): mixed | If XHProf is enabled, this method can be used to retrieve its run information. |
public getDateAndTime(): string | The date and time from which the run information comes (profiler initialization time). Format YYYY-MM-DD HH:MM:SS |
public getRequestURL(): string | Returns the URL of the request being processed. |
public getRootDir(): string | Returns the application root directory. |
public getBlocks( ): Debug_Profiler_Run_Block[] |
Returns the run blocks. |
public getBlock( string $id ): Debug_Profiler_Run_Block|null |
Returns a specific run block. |
public getSqlQueries( ): Debug_Profiler_Run_SQLQueryData[] |
Returns information about all executed SQL queries. |
public blockStart( string $label ): Debug_Profiler_Run_Block |
Creates a new run block and returns an instance of it. Called by the Jet\Debug_Profiler facade. Never directly. |
public blockEnd( string $label ): void |
Ends the current run block. Called by the Jet\Debug_Profiler facade. Never directly. |
protected appendBlock( Debug_Profiler_Run_Block
$block ): void |
Internal class method used for block starts and ends. |
public runEnd(): void | Ends a run. Everything is closed and logged. This class does not perform any saving. Saving runtime information is a task for the _profiler microapplication. This method is only used to collect hints. |
public function SQLQueryStart( string $query, array $query_params ): void |
Called when an SQL query is started. Called by the Jet\Debug_Profiler facade. Never directly. |
public function SqlQueryDone( int $rows_count ): void |
Called when the SQL query completes. Called by the Jet\Debug_Profiler facade. Never directly. |
public message( string $text ): void |
Inserts a debug message into the current run block. Called by the Jet\Debug_Profiler facade. Never directly. |
public __sleep(): array | Specified for serialization and thus storage. In practice, internal properties (intended only for profiler runs) whose names begin with __ are not stored. |
public static getBacktrace( int $shift = 0 ): array |
A useful static method that returns the backtrace as used by the run block, debug message, and SQL query information. It is public, but not intended to be used in the application (friendly classes in PHP would be useful ...). |