function Drupal::linkGenerator
Same name in other branches
- 8.9.x core/lib/Drupal.php \Drupal::linkGenerator()
- 10 core/lib/Drupal.php \Drupal::linkGenerator()
- 11.x core/lib/Drupal.php \Drupal::linkGenerator()
Returns the link generator service.
Return value
\Drupal\Core\Utility\LinkGeneratorInterface
2 calls to Drupal::linkGenerator()
- DrupalTest::testLinkGenerator in core/
tests/ Drupal/ Tests/ Core/ DrupalTest.php - Tests the linkGenerator() method.
- FieldPluginBase::linkGenerator in core/
modules/ views/ src/ Plugin/ views/ field/ FieldPluginBase.php - Gets the link generator.
File
-
core/
lib/ Drupal.php, line 592
Class
- Drupal
- Static Service Container wrapper.
Code
public static function linkGenerator() {
return static::getContainer()->get('link_generator');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.