PHP Class FluidTYPO3\Vhs\Service\PageService

Wrapper service for \TYPO3\CMS\Frontend\Page\PageRepository including static caches for menus, rootlines, pages and page overlays to be implemented in viewhelpers by replacing calls to \TYPO3\CMS\Frontend\Page\PageRepository::getMenu() and the like.
Inheritance: implements TYPO3\CMS\Core\SingletonInterface
Datei anzeigen Open project: fluidtypo3/vhs Class Usage Examples

Protected Properties

Property Type Description
$backendPageRepository TYPO3\CMS\Frontend\Page\PageRepository
$cachedMenus array
$cachedPages array
$cachedRootlines array

Public Methods

Method Description
getItemLink ( array $page, boolean $forceAbsoluteUrl = false ) : string
getMenu ( integer $pageUid, array $excludePages = [], boolean $includeNotInMenu = false, boolean $includeMenuSeparator = false, boolean $disableGroupAccessCheck = false ) : array
getPage ( integer $pageUid, boolean $disableGroupAccessCheck = false ) : array
getRootLine ( integer $pageUid = null, boolean $reverse = false, boolean $disableGroupAccessCheck = false ) : array
getShortcutTargetPage ( array $page ) : null | array Determines the target page record for the provided page record if it is configured as a shortcut in any of the possible modes.
hidePageForLanguageUid ( array | integer $page = null, integer $languageUid, boolean $normalWhenNoLanguage = true ) : boolean
isAccessGranted ( array $page ) : boolean
isAccessProtected ( array $page ) : boolean
isActive ( integer $pageUid, boolean $showAccessProtected = false ) : boolean
isCurrent ( integer $pageUid ) : boolean
shouldUseShortcutTarget ( array $arguments ) : boolean
shouldUseShortcutUid ( array $arguments ) : boolean

Protected Methods

Method Description
getPageConstraints ( array $excludePages = [], boolean $includeNotInMenu = false, boolean $includeMenuSeparator = false ) : string
getPageRepository ( ) : TYPO3\CMS\Frontend\Page\PageRepository
getPageRepositoryForBackendContext ( ) : TYPO3\CMS\Frontend\Page\PageRepository

Method Details

getMenu() public method

public getMenu ( integer $pageUid, array $excludePages = [], boolean $includeNotInMenu = false, boolean $includeMenuSeparator = false, boolean $disableGroupAccessCheck = false ) : array
$pageUid integer
$excludePages array
$includeNotInMenu boolean
$includeMenuSeparator boolean
$disableGroupAccessCheck boolean
return array

getPage() public method

public getPage ( integer $pageUid, boolean $disableGroupAccessCheck = false ) : array
$pageUid integer
$disableGroupAccessCheck boolean
return array

getPageConstraints() protected method

protected getPageConstraints ( array $excludePages = [], boolean $includeNotInMenu = false, boolean $includeMenuSeparator = false ) : string
$excludePages array
$includeNotInMenu boolean
$includeMenuSeparator boolean
return string

getPageRepository() protected method

protected getPageRepository ( ) : TYPO3\CMS\Frontend\Page\PageRepository
return TYPO3\CMS\Frontend\Page\PageRepository

getPageRepositoryForBackendContext() protected method

protected getPageRepositoryForBackendContext ( ) : TYPO3\CMS\Frontend\Page\PageRepository
return TYPO3\CMS\Frontend\Page\PageRepository

getRootLine() public method

public getRootLine ( integer $pageUid = null, boolean $reverse = false, boolean $disableGroupAccessCheck = false ) : array
$pageUid integer
$reverse boolean
$disableGroupAccessCheck boolean
return array

getShortcutTargetPage() public method

Returns NULL otherwise.
public getShortcutTargetPage ( array $page ) : null | array
$page array
return null | array

hidePageForLanguageUid() public method

public hidePageForLanguageUid ( array | integer $page = null, integer $languageUid, boolean $normalWhenNoLanguage = true ) : boolean
$page array | integer
$languageUid integer
$normalWhenNoLanguage boolean
return boolean

isAccessGranted() public method

public isAccessGranted ( array $page ) : boolean
$page array
return boolean

isAccessProtected() public method

public isAccessProtected ( array $page ) : boolean
$page array
return boolean

isActive() public method

public isActive ( integer $pageUid, boolean $showAccessProtected = false ) : boolean
$pageUid integer
$showAccessProtected boolean
return boolean

isCurrent() public method

public isCurrent ( integer $pageUid ) : boolean
$pageUid integer
return boolean

shouldUseShortcutTarget() public method

public shouldUseShortcutTarget ( array $arguments ) : boolean
$arguments array
return boolean

shouldUseShortcutUid() public method

public shouldUseShortcutUid ( array $arguments ) : boolean
$arguments array
return boolean

Property Details

$backendPageRepository protected_oe static_oe property

protected static PageRepository,TYPO3\CMS\Frontend\Page $backendPageRepository
return TYPO3\CMS\Frontend\Page\PageRepository

$cachedMenus protected_oe static_oe property

protected static array $cachedMenus
return array

$cachedPages protected_oe static_oe property

protected static array $cachedPages
return array

$cachedRootlines protected_oe static_oe property

protected static array $cachedRootlines
return array