public function Link::setLinkGenerator in Drupal 8
Same name and namespace in other branches
- 9 core/lib/Drupal/Core/Link.php \Drupal\Core\Link::setLinkGenerator()
- 10 core/lib/Drupal/Core/Link.php \Drupal\Core\Link::setLinkGenerator()
Sets the link generator service.
Parameters
\Drupal\Core\Utility\LinkGeneratorInterface $generator: The link generator service.
Return value
$this
File
- core/
lib/ Drupal/ Core/ Link.php, line 173
Class
- Link
- Defines an object that holds information about a link.
Namespace
Drupal\CoreCode
public function setLinkGenerator(LinkGeneratorInterface $generator) {
$this->linkGenerator = $generator;
return $this;
}