protected function EntityUrlGeneratorBase::getAlternateUrlsForDefaultLanguage in Simple XML sitemap 8.3
Same name and namespace in other branches
- 4.x src/Plugin/simple_sitemap/UrlGenerator/EntityUrlGeneratorBase.php \Drupal\simple_sitemap\Plugin\simple_sitemap\UrlGenerator\EntityUrlGeneratorBase::getAlternateUrlsForDefaultLanguage()
Parameters
\Drupal\Core\Url $url_object:
Return value
array
1 call to EntityUrlGeneratorBase::getAlternateUrlsForDefaultLanguage()
- EntityUrlGeneratorBase::getUrlVariants in src/
Plugin/ simple_sitemap/ UrlGenerator/ EntityUrlGeneratorBase.php
File
- src/
Plugin/ simple_sitemap/ UrlGenerator/ EntityUrlGeneratorBase.php, line 148
Class
- EntityUrlGeneratorBase
- Class EntityUrlGeneratorBase @package Drupal\simple_sitemap\Plugin\simple_sitemap\UrlGenerator
Namespace
Drupal\simple_sitemap\Plugin\simple_sitemap\UrlGeneratorCode
protected function getAlternateUrlsForDefaultLanguage(Url $url_object) {
$alternate_urls = [];
if ($url_object
->access($this->anonUser)) {
$alternate_urls[$this->defaultLanguageId] = $this
->replaceBaseUrlWithCustom($url_object
->setAbsolute()
->setOption('language', $this->languages[$this->defaultLanguageId])
->toString());
}
return $alternate_urls;
}