ConfigDataFactory
API reference › Yii3 Debug › ConfigDataFactory
Creates the live Yii and PHP configuration shown by the Configuration page.
Application metadata the application does not declare falls back to the runtime: the Composer root package supplies
the name and version, APP_ENV the environment, and APP_DEBUG the debug mode.
Methods
Section titled “Methods”| Method | Description | Defined by |
|---|---|---|
__construct() | Creates the configuration-data factory with optional application metadata. | ConfigDataFactory |
create() | Builds the Configuration panel payload from the live application and PHP runtime. | ConfigDataFactory |
Method details
Section titled “Method details”__construct()
Section titled “__construct() ”public function __construct(array<string, mixed> $application = [])Creates the configuration-data factory with optional application metadata.
Parameters
| Parameter | Type | Description |
|---|---|---|
$application | array<string, | Optional application metadata. |
create()
Section titled “create() ”public function create(): array<string, mixed>Builds the Configuration panel payload from the live application and PHP runtime.
Returns
array<string, mixed>: Payload accepted by the shared Configuration presenter.