Link

Defines an object that holds information about a link.

Hierarchy

File

core/lib/Drupal/Core/Link.php, line 11

Namespace

Drupal\Core

Members

Name Modifiers Type Description
Link::$text protected property The text of the link.
Link::$url protected property The URL of the link.
Link::createFromRoute public static function Creates a Link object from a given route name and parameters.
Link::fromTextAndUrl public static function Creates a Link object from a given Url object.
Link::getText public function Returns the text of the link.
Link::getUrl public function Returns the URL of the link.
Link::setText public function Sets the new text of the link.
Link::setUrl public function Sets the URL of this link.
Link::toRenderable public function Returns a render array representation of the object. Overrides RenderableInterface::toRenderable
Link::toString public function Generates the HTML for this Link object.
Link::__construct public function Constructs a new Link object.
LinkGeneratorTrait::$linkGenerator protected property The link generator.
LinkGeneratorTrait::getLinkGenerator protected function Returns the link generator.
LinkGeneratorTrait::l Deprecated protected function Renders a link to a route given a route name and its parameters.
LinkGeneratorTrait::setLinkGenerator public function Sets the link generator service.
doc_Drupal
2016-10-29 09:23:13
Comments
Leave a Comment

Please login to continue.