public ConfigEntityDependency::__construct($name, $values = [])
Constructs the configuration entity dependency from the entity values.
string $name: The configuration entity's configuration object name.
array $values: (optional) The configuration entity's values.
public function __construct($name, $values = []) { $this->name = $name; if (isset($values['dependencies']) && isset($values['dependencies']['enforced'])) { // Merge the enforced dependencies into the list of dependencies. $enforced_dependencies = $values['dependencies']['enforced']; unset($values['dependencies']['enforced']); $this->dependencies = NestedArray::mergeDeep($values['dependencies'], $enforced_dependencies); } elseif (isset($values['dependencies'])) { $this->dependencies = $values['dependencies']; } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Config!Entity!ConfigEntityDependency.php/function/ConfigEntityDependency::__construct/8.1.x