function AttributeBase::setDependencies

Sets the dependencies for this attribute class.

Parameters

array{"class"?: list<class-string>, "interface"?: list<class-string>, "trait"?: list<class-string>, "provider"?: list<string>}|null $dependencies: The list of dependencies, keyed by type. If the type is 'class', 'trait', or 'interface', the values for the type are class names. If the type is 'provider', the values for the type are provider names.

Overrides AttributeInterface::setDependencies

File

core/lib/Drupal/Component/Plugin/Attribute/AttributeBase.php, line 86

Class

AttributeBase
Provides a base class for classed attributes.

Namespace

Drupal\Component\Plugin\Attribute

Code

public function setDependencies(?array $dependencies) : void {
  $this->dependencies = $dependencies;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.