You are here

interface AliasRepositoryInterface in Drupal 8

Same name in this branch
  1. 8 core/modules/path_alias/src/AliasRepositoryInterface.php \Drupal\path_alias\AliasRepositoryInterface
  2. 8 core/lib/Drupal/Core/Path/AliasRepositoryInterface.php \Drupal\Core\Path\AliasRepositoryInterface
Same name and namespace in other branches
  1. 9 core/modules/path_alias/src/AliasRepositoryInterface.php \Drupal\path_alias\AliasRepositoryInterface

Provides an interface for path alias lookup operations.

The path alias repository service is only used internally in order to optimize alias lookup queries needed in the critical path of each request. However, it is not marked as an internal service because alternative storage backends still need to override it if they provide a different storage class for the PathAlias entity type.

Whenever you need to determine whether an alias exists for a system path, or whether a system path has an alias, the 'path_alias.manager' service should be used instead.

Hierarchy

Expanded class hierarchy of AliasRepositoryInterface

All classes that implement AliasRepositoryInterface

2 files declare their use of AliasRepositoryInterface
AliasManagerTest.php in core/modules/path_alias/tests/src/Unit/AliasManagerTest.php
DeprecatedClassesTest.php in core/modules/path_alias/tests/src/Unit/DeprecatedClassesTest.php

File

core/modules/path_alias/src/AliasRepositoryInterface.php, line 20

Namespace

Drupal\path_alias
View source
interface AliasRepositoryInterface extends CoreAliasRepositoryInterface {

}

Members

Namesort descending Modifiers Type Description Overrides
AliasRepositoryInterface::lookupByAlias public function Searches a path alias for a given alias. 1
AliasRepositoryInterface::lookupBySystemPath public function Searches a path alias for a given Drupal system path. 1
AliasRepositoryInterface::pathHasMatchingAlias public function Check if any alias exists starting with $initial_substring. 1
AliasRepositoryInterface::preloadPathAlias public function Pre-loads path alias information for a given list of system paths. 1