SitemapPageAlternativeLanguage
class SitemapPageAlternativeLanguage extends SitemapElement (View source)
Constants
DEFAULT_NAMESPACE |
The default sitemap namespace. |
MULTILINGUAL_NAMESPACE |
The namespace required for the multilingual alternatives. |
MULTILINGUAL_NAMESPACE_NAME |
The alias of the namespace required for the multilingual alternatives. |
Properties
protected Section | $section | The multilingual section associated to this alternative page. |
|
protected Page | $page | The alternative page in the alternative language. |
|
protected UrlInterface | $url | The URL of the alternative page. |
|
protected bool | $skip | Should this alternative be skipped? |
|
protected string | $overriddenHrefLang | The overridden hreflang value. |
Methods
Returns the XML representation of this element.
Returns a SimpleXMLElement instance representing this element.
Get the multilingual section associated to this alternative page.
Get the URL of the alternative page.
Should this alternative be skipped?
Should this alternative be skipped?
Get the overridden hreflang value.
Set the overridden hreflang value.
Get the final value of the href lang.
Details
string[]|null
toXmlLines(string $indenter = ' ')
Returns the XML representation of this element.
SimpleXMLElement|null
toXmlElement(SimpleXMLElement $parentElement = null)
Returns a SimpleXMLElement instance representing this element.
protected string
getXmlMetaHeader()
Get the XML meta-header.
__construct(Section $section, Page $page, UrlInterface $url)
No description
Section
getSection()
Get the multilingual section associated to this alternative page.
Page
getPage()
Get the alternative page in the alternative language.
UrlInterface
getUrl()
Get the URL of the alternative page.
$this
setUrl(UrlInterface $url)
Set the URL of the alternative page.
bool
isSkip()
Should this alternative be skipped?
$this
setSkip(bool $skip)
Should this alternative be skipped?
string
getOverriddenHrefLang()
Get the overridden hreflang value.
$this
setOverriddenHrefLang(string $overriddenHrefLang)
Set the overridden hreflang value.
protected string
getFinalHrefLang()
Get the final value of the href lang.