Skip to content
PHP Ecosystem
Explore

PhpInfoTile

API reference › Debug Core › PhpInfo › PhpInfoTile

final readonly classPHPForge\Debug\PhpInfo\PhpInfoTile
Sourcesrc/PhpInfo/PhpInfoTile.php

Typed view-model for one tile in a phpinfo Overview section.

The $kind discriminator drives the renderer’s branch: enabled/disabled pill, comma-separated path or token list, single shortened path, or plain code text.

PropertyTypeDescriptionDefined by
$displayValue readonly constructorstringDisplay value already prepared for the rendering branch indicated by $kind.PhpInfoTile
$kind readonly constructorstringRendering kind. See the KIND_* constants.PhpInfoTile
$label readonly constructorstringTile label rendered in the <dt> cell (‘SAPI’, ‘Memory limit’, …).PhpInfoTile
$rawValue readonly constructorstringFull original value (used as the title tooltip when the display value was shortened).PhpInfoTile
$tokens readonly constructorlist<PhpInfoToken>Path tokens for KIND_PATH_LIST (already with basename() applied for display) or short tokens for KIND_TOKEN_LIST. Empty list for the other kinds. Default: [].PhpInfoTile
MethodDescriptionDefined by
__construct()Creates a typed tile for a phpinfo overview section.PhpInfoTile
ConstantValueDescriptionDefined by
KIND_PATH'path'Renders a single shortened path as <code>, with the full value as its hover title.PhpInfoTile
KIND_PATH_LIST'path-list'Renders every entry of $tokens as a <code> chip, each carrying its full path as a hover title.PhpInfoTile
KIND_PILL_MUTED'pill-muted'Renders a pill in its muted variant, used for an off or unavailable status.PhpInfoTile
KIND_PILL_SUCCESS'pill-success'Renders a pill in its success variant, used for an on or available status.PhpInfoTile
KIND_TEXT'text'Renders the display value as plain <code> text, without a hover title.PhpInfoTile
KIND_TOKEN_LIST'token-list'Renders every entry of $tokens as a <code> chip; unlike KIND_PATH_LIST, the tokens are not paths.PhpInfoTile
public function __construct(string $label, string $displayValue, string $rawValue, string $kind, array $tokens = [])

Creates a typed tile for a phpinfo overview section.

Parameters

ParameterTypeDescription
$labelstring
$displayValuestring
$rawValuestring
$kindstring
$tokensarray