The Settings service allows you to obtain standard or custom framework settings from the files within the /config/ directory.
Methods of using Settings in controllers (and all classes inherited from Hleb\Base\Container) exemplified by retrieving the designated timezone from the /config/common.php file:
Example of accessing Settings within application code:
The Settings object can also be obtained through dependency injection via the interface Hleb\Reference\Interface\Setting.
Settings are divided into four groups: 'common', 'main', 'database', and 'system'. They correspond to the configuration files within the /config/ directory. If a different file is being used, such as 'main-local.php' instead of 'main.php', the setting must still be retrieved using the name 'main'.
The service methods - common(), main(), database(), and system() allow for retrieving parameters from the respective settings. For example: