PHP Class Nette\DI\Config\Loader

Inheritance: use trait Nette\SmartObject
显示文件 Open project: nette/di Class Usage Examples

Public Methods

Method Description
addAdapter ( $extension, $adapter ) : self Registers adapter for given file extension.
getDependencies ( ) : array Returns configuration files.
load ( $file, $section = NULL ) : array Reads configuration from file.
save ( $data, $file ) : void Save configuration to file.

Private Methods

Method Description
getAdapter ( $file ) : Nette\DI\Config\IAdapter
getSection ( array $data, $key, $file )

Method Details

addAdapter() public method

Registers adapter for given file extension.
public addAdapter ( $extension, $adapter ) : self
return self

getDependencies() public method

Returns configuration files.
public getDependencies ( ) : array
return array

load() public method

Reads configuration from file.
public load ( $file, $section = NULL ) : array
return array

save() public method

Save configuration to file.
public save ( $data, $file ) : void
return void