You are here

public function EntityAliasTypeBase::getLabel in View Mode Page 8.3

Same name and namespace in other branches
  1. 4.0.x src/Plugin/view_mode_page/AliasType/EntityAliasTypeBase.php \Drupal\view_mode_page\Plugin\view_mode_page\AliasType\EntityAliasTypeBase::getLabel()
  2. 3.2.x src/Plugin/view_mode_page/AliasType/EntityAliasTypeBase.php \Drupal\view_mode_page\Plugin\view_mode_page\AliasType\EntityAliasTypeBase::getLabel()

Get the label.

Return value

string The label.

Overrides AliasTypeInterface::getLabel

1 method overrides EntityAliasTypeBase::getLabel()
Broken::getLabel in src/Plugin/view_mode_page/AliasType/Broken.php
Get the label.

File

src/Plugin/view_mode_page/AliasType/EntityAliasTypeBase.php, line 85

Class

EntityAliasTypeBase
A view_mode_page alias type plugin for entities with canonical links.

Namespace

Drupal\view_mode_page\Plugin\view_mode_page\AliasType

Code

public function getLabel() {
  $definition = $this
    ->getPluginDefinition();

  // Cast the admin label to a string since it is an object.
  // @see \Drupal\Core\StringTranslation\TranslationWrapper
  return (string) $definition['label'];
}