public function Link::getRouteName in Colossal Menu 8
Same name and namespace in other branches
- 2.x src/Entity/Link.php \Drupal\colossal_menu\Entity\Link::getRouteName()
Returns the route name, if available.
Return value
string The name of the route this menu link links to.
Overrides MenuLinkInterface::getRouteName
File
- src/
Entity/ Link.php, line 404
Class
- Link
- Defines the Link entity.
Namespace
Drupal\colossal_menu\EntityCode
public function getRouteName() {
if ($this
->getUrlObject()
->isRouted()) {
return $this
->getUrlObject()
->getRouteName();
}
return '';
}