private function ResolveReferencesToAliasesPass::getDefinitionId in Service Container 7.2
Same name and namespace in other branches
- 7 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Compiler/ResolveReferencesToAliasesPass.php \Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass::getDefinitionId()
Resolves an alias into a definition id.
Parameters
string $id The definition or alias id to resolve:
Return value
string The definition id with aliases resolved
2 calls to ResolveReferencesToAliasesPass::getDefinitionId()
- ResolveReferencesToAliasesPass::process in modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Compiler/ ResolveReferencesToAliasesPass.php - Processes the ContainerBuilder to replace references to aliases with actual service references.
- ResolveReferencesToAliasesPass::processArguments in modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Compiler/ ResolveReferencesToAliasesPass.php - Processes the arguments to replace aliases.
File
- modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Compiler/ ResolveReferencesToAliasesPass.php, line 86
Class
- ResolveReferencesToAliasesPass
- Replaces all references to aliases with references to the actual service.
Namespace
Symfony\Component\DependencyInjection\CompilerCode
private function getDefinitionId($id) {
$seen = array();
while ($this->container
->hasAlias($id)) {
if (isset($seen[$id])) {
throw new ServiceCircularReferenceException($id, array_keys($seen));
}
$seen[$id] = true;
$id = (string) $this->container
->getAlias($id);
}
return $id;
}