eZ\Bundle\EzPublishCoreBundle\DependencyInjection\Configuration\SiteAccessAware\DynamicSettingParserInterface::parseDynamicSetting PHP Method

parseDynamicSetting() public method

Returned hash will contain the following entries:. - "param": the parameter name (e.g. "my_param"). - "namespace": the namespace. Will be null if none was specified (considered default). - "scope": the scope. Will be null if none was specified (considered default).
public parseDynamicSetting ( string $setting ) : array
$setting string
return array
    public function parseDynamicSetting($setting);

Usage Example

 /**
  * Adds dynamic settings notation support: $<paramName>[;<namespace>[;<scope>]]$.
  *
  * {@inheritdoc}
  */
 protected function parseInput($input, array $options = array())
 {
     if ($this->dynamicSettingParser->isDynamicSetting($input)) {
         $parsedSettings = $this->dynamicSettingParser->parseDynamicSetting($input);
         $input = $this->configResolver->getParameter($parsedSettings['param'], $parsedSettings['namespace'], $parsedSettings['scope']);
         if (is_array($input)) {
             $collection = $this->createAssetCollection(array(), $options);
             foreach ($input as $file) {
                 $collection->add(parent::parseInput($file, $options));
             }
             return $collection;
         }
     }
     return parent::parseInput($input, $options);
 }
All Usage Examples Of eZ\Bundle\EzPublishCoreBundle\DependencyInjection\Configuration\SiteAccessAware\DynamicSettingParserInterface::parseDynamicSetting
DynamicSettingParserInterface