function InfoHookDecorator::__construct
Constructs an InfoHookDecorator object.
Parameters
\Drupal\Component\Plugin\Discovery\DiscoveryInterface $decorated: The object implementing DiscoveryInterface that is being decorated.
string $hook: The name of the info hook to be invoked by this discovery instance.
File
-
core/
lib/ Drupal/ Core/ Plugin/ Discovery/ InfoHookDecorator.php, line 37
Class
- InfoHookDecorator
- Allows info hook implementations to enhance discovered plugin definitions.
Namespace
Drupal\Core\Plugin\DiscoveryCode
public function __construct(DiscoveryInterface $decorated, $hook) {
$this->decorated = $decorated;
$this->hook = $hook;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.