com\setasign\SetaSite\Page
PagePathAndLanguageNegotiator
File: /SetaSite/src/Page/PagePathAndLanguageNegotiator.php
Class hierarchy
Summary
Properties
Methods
__construct()
public PagePathAndLanguageNegotiator::__construct (
\com\setasign\SetaFramework\Bootstrap\RequestPathPrefix $requestPathPrefix,
PageSettings $pageSettings,
\com\setasign\SetaFramework\Http\HttpFactoryInterface $httpFactory
)PageSettings $pageSettings,
\com\setasign\SetaFramework\Http\HttpFactoryInterface $httpFactory
Parameters
- $requestPathPrefix : \com\setasign\SetaFramework\Bootstrap\RequestPathPrefix
- $pageSettings : PageSettings
- $httpFactory : \com\setasign\SetaFramework\Http\HttpFactoryInterface
extractLanguageFromPath()
Removes the requestPathPrefix and the language identifier from path
Parameters
- $path : string
Return Values
With the entries [$path, $language]
handle()
public PagePathAndLanguageNegotiator::handle (
\com\setasign\SetaFramework\Request\ServerRequest $request
): arrayHandle the page language and page path.
Parameters
- $request : \com\setasign\SetaFramework\Request\ServerRequest
Return Values
With the entries [$path, $language]
Exceptions
negotiateLanguage()
protected PagePathAndLanguageNegotiator::negotiateLanguage (
string $path,
?string $language,
\com\setasign\SetaFramework\Request\ServerRequest $request
): string?string $language,
\com\setasign\SetaFramework\Request\ServerRequest $request
Parameters
- $path : string
- $language : ?string
- $request : \com\setasign\SetaFramework\Request\ServerRequest
