Skip to content
PHP Ecosystem
Explore

RequestRoutingViewFactory

API reference › Debug › panels › request › RequestRoutingViewFactory

final classyii\debug\panels\request\RequestRoutingViewFactory
Sourcesrc/panels/request/RequestRoutingViewFactory.php

Adapts Yii2 request data, the captured URL-rule trace, and the live URL manager configuration to the shared Request routing view.

MethodDescriptionDefined by
fromRequestData() staticBuilds the composed routing view without evaluating controller action maps.RequestRoutingViewFactory
public static function fromRequestData(array<array-key, mixed> $data, PHPForge\Debug\Panel\Router\RouterSnapshot|null $snapshot, PHPForge\Debug\Storage\ExceptionSnapshot|null $error, yii\debug\models\router\RouterRules|null $routerRules = null): PHPForge\Debug\Panel\Request\Routing\RequestRoutingView

Builds the composed routing view without evaluating controller action maps.

Parameters

ParameterTypeDescription
$dataarray<array-key, mixed>Captured Request panel data.
$snapshotPHPForge\Debug\Panel\Router\RouterSnapshot|nullCaptured Router panel trace, when available.
$errorPHPForge\Debug\Storage\ExceptionSnapshot|nullCaptured Router collector or hydration failure, when available.
$routerRulesyii\debug\models\router\RouterRules|nullInjected live URL-manager view model; primarily useful to avoid rescanning the manager when the caller already has it.

Returns

PHPForge\Debug\Panel\Request\Routing\RequestRoutingView: Composed view of the current route and the application route inventory.