LocalActionManager::getTitle

public LocalActionManager::getTitle(LocalActionInterface $local_action)

Gets the title for a local action.

Parameters

\Drupal\Core\Menu\LocalActionInterface $local_action: An object to get the title from.

Return value

string The title (already localized).

Throws

\BadMethodCallException If the plugin does not implement the getTitle() method.

Overrides LocalActionManagerInterface::getTitle

File

core/lib/Drupal/Core/Menu/LocalActionManager.php, line 151

Class

LocalActionManager
Provides the default local action manager using YML as primary definition.

Namespace

Drupal\Core\Menu

Code

public function getTitle(LocalActionInterface $local_action) {
  $controller = array($local_action, 'getTitle');
  $arguments = $this->controllerResolver->getArguments($this->requestStack->getCurrentRequest(), $controller);
  return call_user_func_array($controller, $arguments);
}
doc_Drupal
2016-10-29 09:23:44
Comments
Leave a Comment

Please login to continue.