‪TYPO3CMS  10.4
TYPO3\CMS\Core\Site\Entity\SiteInterface Interface Reference
Inheritance diagram for TYPO3\CMS\Core\Site\Entity\SiteInterface:
TYPO3\CMS\Core\Site\Entity\NullSite TYPO3\CMS\Core\Site\Entity\Site

Public Member Functions

int getRootPageId ()
 
string getIdentifier ()
 
UriInterface getBase ()
 
SiteLanguage[] getLanguages ()
 
SiteLanguage getLanguageById (int $languageId)
 
SiteLanguage getDefaultLanguage ()
 
SiteLanguage[] getAvailableLanguages (BackendUserAuthentication $user, bool $includeAllLanguagesFlag=false, int $pageId=null)
 
PageErrorHandlerInterface getErrorHandler (int $statusCode)
 

Detailed Description

Definition at line 25 of file SiteInterface.php.

Member Function Documentation

◆ getAvailableLanguages()

SiteLanguage [] TYPO3\CMS\Core\Site\Entity\SiteInterface::getAvailableLanguages ( BackendUserAuthentication  $user,
bool  $includeAllLanguagesFlag = false,
int  $pageId = null 
)

Fetch the available languages for a specific backend user, used in various places in Backend and Frontend when a Backend User is authenticated.

Parameters
BackendUserAuthentication$user‪the authenticated backend user to check access rights
bool$includeAllLanguagesFlag‪whether "-1" should be included in the values or not.
int$pageId‪usually used for resolving additional information from PageTS, only used for pseudo-sites. uid of the default language row!
Returns
SiteLanguage[]

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

◆ getBase()

UriInterface TYPO3\CMS\Core\Site\Entity\SiteInterface::getBase ( )

Returns the base URL

Returns
‪UriInterface

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

◆ getDefaultLanguage()

SiteLanguage TYPO3\CMS\Core\Site\Entity\SiteInterface::getDefaultLanguage ( )

◆ getErrorHandler()

PageErrorHandlerInterface TYPO3\CMS\Core\Site\Entity\SiteInterface::getErrorHandler ( int  $statusCode)

Returns a ready-to-use error handler, to be used within the ErrorController

Parameters
int$statusCode
Returns
‪PageErrorHandlerInterface
Exceptions
PageErrorHandlerNotConfiguredException

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

◆ getIdentifier()

string TYPO3\CMS\Core\Site\Entity\SiteInterface::getIdentifier ( )

◆ getLanguageById()

SiteLanguage TYPO3\CMS\Core\Site\Entity\SiteInterface::getLanguageById ( int  $languageId)

Returns a language of this site, given by the sys_language_uid

Parameters
int$languageId
Returns
SiteLanguage
Exceptions

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaSlug\getPrefixForSite().

◆ getLanguages()

SiteLanguage [] TYPO3\CMS\Core\Site\Entity\SiteInterface::getLanguages ( )

Returns all available languages of this site visible in the frontend

Returns
SiteLanguage[]

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

◆ getRootPageId()

int TYPO3\CMS\Core\Site\Entity\SiteInterface::getRootPageId ( )

Returns the root page ID of this site

Returns
‪int

Implemented in TYPO3\CMS\Core\Site\Entity\Site, and TYPO3\CMS\Core\Site\Entity\NullSite.

Referenced by TYPO3\CMS\Redirects\Service\RedirectService\bootFrontendController().