com\setasign\SetaSite\Page

PagePathAndLanguageNegotiator

File: /SetaSite/src/Page/PagePathAndLanguageNegotiator.php

Class hierarchy

Summary

Properties


Methods

extractLanguageFromPath()

protected PagePathAndLanguageNegotiator::extractLanguageFromPath (
string $path
): array

Removes the requestPathPrefix and the language identifier from path

Parameters
$path: string
 
Return Values

With the entries [$path, $language]

handle()

Handle the page language and page path.

Parameters
$request: \com\setasign\SetaFramework\Request\ServerRequest
 
Return Values

With the entries [$path, $language]

Exceptions

Throws \com\setasign\SetaSite\Block\ForceResponseException

negotiateLanguage()

protected PagePathAndLanguageNegotiator::negotiateLanguage (
string $path,
?string $language,
\com\setasign\SetaFramework\Request\ServerRequest $request
): string
Parameters
$path: string
 
$language: ?string
 
$request: \com\setasign\SetaFramework\Request\ServerRequest
 
Exceptions

Throws \com\setasign\SetaSite\Block\ForceResponseException