You are here

public function LinkManager::__construct in JSON:API 8

Instantiates a LinkManager object.

Parameters

\Symfony\Component\Routing\Matcher\RequestMatcherInterface|null $_router: Unused. Kept for backwards compatibility.

\Drupal\Core\Routing\UrlGeneratorInterface $url_generator: The Url generator.

File

src/LinkManager/LinkManager.php, line 37

Class

LinkManager
Class to generate links and queries for entities.

Namespace

Drupal\jsonapi\LinkManager

Code

public function __construct(RequestMatcherInterface $_router = NULL, UrlGeneratorInterface $url_generator) {
  $this->urlGenerator = $url_generator;
}