Drivers
The Config Driver
Introduction
The Config driver provides access to API configuration located in the config directory:
Installation
Install the driver via composer by running:
composer require kipchak/driver-config
Initialise the Driver
Add the following line to your drivers/drivers.php file:
\Mamluk\Kipchak\Driver\Config\Config::iniitalise($container);
Configuration
This driver has no configuration.
Usage
use Kipchak\Driver\Config\Config;
$config = Config::get();
$apiConfig = $config->get('kipchak.api'); // loads the kipchak.api.php file
$dbConfig = $config->get('kipchak.doctrine.php'); // loads the kipchak.doctrine.php file
Configuration files are always PHP arrays and can have any level of nesting.
Git Repository
The source code for this driver is available on 1x.ax at https://1x.ax/mamluk/kipchak/drivers/config.