PHP Class N98\Magento\Application\ConfigurationLoader

The configuration which is global (not Magento project specific) is loaded during construction. As soon as the Magento folder is known, loadStageTwo should be called. The toArray method only works if the Magento folder specific configuration is already loaded. Class ConfigurationLoader
Afficher le fichier Open project: netz98/n98-magerun

Protected Properties

Свойство Type Description
$_configArray array
$_customConfigFilename string
$_distConfig array Cache
$_initialConfig array Config passed in the constructor
$_isPharMode boolean
$_output Symfony\Component\Console\Output\OutputInterface
$_pluginConfig array Cache
$_projectConfig array Cache
$_systemConfig array Cache
$_userConfig array Cache

Méthodes publiques

Méthode Description
__construct ( array $config, boolean $isPharMode, Symfony\Component\Console\Output\OutputInterface $output ) Load config If $magentoRootFolder is null, only non-project config is loaded
getConfigurationLoaderDir ( ) : string
getPartialConfig ( boolean $loadExternalConfig = true ) : array
getVendorDir ( ) : string
loadPluginConfig ( array $config, string $magentoRootFolder ) : array Load config from all installed bundles
loadProjectConfig ( string $magentoRootFolder, string $magerunStopFileFolder, array $config ) : array MAGENTO_ROOT/app/etc/n98-magerun.yaml
loadStageTwo ( string $magentoRootFolder, boolean $loadExternalConfig = true, string $magerunStopFileFolder = '' )
loadSystemConfig ( array $config ) : array Check if there is a global config file in /etc folder
loadUserConfig ( array $config, string $magentoRootFolder = null ) : array Check if there is a user config file. ~/.n98-magerun.yaml
toArray ( ) : array

Méthodes protégées

Méthode Description
loadDistConfig ( array $initConfig ) : array
registerPluginConfigFile ( string $magentoRootFolder, Symfony\Component\Finder\SplFileInfo $file ) Loads a plugin config file and merges it to plugin config

Private Methods

Méthode Description
log ( string $message )
logDebug ( string $message )

Method Details

__construct() public méthode

Load config If $magentoRootFolder is null, only non-project config is loaded
public __construct ( array $config, boolean $isPharMode, Symfony\Component\Console\Output\OutputInterface $output )
$config array
$isPharMode boolean
$output Symfony\Component\Console\Output\OutputInterface

getConfigurationLoaderDir() public méthode

public getConfigurationLoaderDir ( ) : string
Résultat string

getPartialConfig() public méthode

public getPartialConfig ( boolean $loadExternalConfig = true ) : array
$loadExternalConfig boolean
Résultat array

getVendorDir() public méthode

public getVendorDir ( ) : string
Résultat string

loadDistConfig() protected méthode

protected loadDistConfig ( array $initConfig ) : array
$initConfig array
Résultat array

loadPluginConfig() public méthode

Load config from all installed bundles
public loadPluginConfig ( array $config, string $magentoRootFolder ) : array
$config array
$magentoRootFolder string
Résultat array

loadProjectConfig() public méthode

MAGENTO_ROOT/app/etc/n98-magerun.yaml
public loadProjectConfig ( string $magentoRootFolder, string $magerunStopFileFolder, array $config ) : array
$magentoRootFolder string
$magerunStopFileFolder string
$config array
Résultat array

loadStageTwo() public méthode

public loadStageTwo ( string $magentoRootFolder, boolean $loadExternalConfig = true, string $magerunStopFileFolder = '' )
$magentoRootFolder string
$loadExternalConfig boolean
$magerunStopFileFolder string

loadSystemConfig() public méthode

Check if there is a global config file in /etc folder
public loadSystemConfig ( array $config ) : array
$config array
Résultat array

loadUserConfig() public méthode

Check if there is a user config file. ~/.n98-magerun.yaml
public loadUserConfig ( array $config, string $magentoRootFolder = null ) : array
$config array
$magentoRootFolder string [optional]
Résultat array

registerPluginConfigFile() protected méthode

Loads a plugin config file and merges it to plugin config
protected registerPluginConfigFile ( string $magentoRootFolder, Symfony\Component\Finder\SplFileInfo $file )
$magentoRootFolder string
$file Symfony\Component\Finder\SplFileInfo

toArray() public méthode

public toArray ( ) : array
Résultat array

Property Details

$_configArray protected_oe property

protected array $_configArray
Résultat array

$_customConfigFilename protected_oe property

protected string $_customConfigFilename
Résultat string

$_distConfig protected_oe property

Cache
protected array $_distConfig
Résultat array

$_initialConfig protected_oe property

Config passed in the constructor
protected array $_initialConfig
Résultat array

$_isPharMode protected_oe property

protected bool $_isPharMode
Résultat boolean

$_output protected_oe property

protected OutputInterface,Symfony\Component\Console\Output $_output
Résultat Symfony\Component\Console\Output\OutputInterface

$_pluginConfig protected_oe property

Cache
protected array $_pluginConfig
Résultat array

$_projectConfig protected_oe property

Cache
protected array $_projectConfig
Résultat array

$_systemConfig protected_oe property

Cache
protected array $_systemConfig
Résultat array

$_userConfig protected_oe property

Cache
protected array $_userConfig
Résultat array