NavigationPageTree
extends SigmaPageTree
in package
NavigationPageTree
Tags
Table of Contents
Constants
- styleNameActive = "active"
- styleNameNormal = "inactive"
Properties
- $branchNodeIds : mixed
- $bytes : mixed
- $considerLogin : mixed
- $considerSeoEnabledOnly : bool
- Consider seo enabled pages alone
- $currentPage : mixed
- $currentPageOnRootNode : mixed
- $currentPagePath : mixed
- $depth : mixed
- $em : mixed
- $lang : mixed
- $license : mixed
- $nodeRepo : mixed
- $output : mixed
- $pageIdsAtCurrentPath : mixed
- $pageRepo : mixed
- $rootNode : mixed
- $skipInactive : mixed
- $skipInvisible : mixed
- $startLevel : mixed
- $startPath : mixed
- $template : Sigma
- $topLevelBlockName : mixed
- $virtualLanguageDirectory : mixed
- $virtualPagesAdded : mixed
Methods
- __construct() : mixed
- isPagePathActive() : bool
- Tells wheter $pathToPage is in the active branch
- postRenderLevel() : mixed
- preRenderLevel() : mixed
- render() : string
- returns the string representation of the tree.
- setTemplate() : mixed
- setVirtualLanguageDirectory() : mixed
- getFirstLevel() : int
- Get the first level index which should be shown
- getFullNavigation() : bool
- getLastLevel() : int
- Get the last level index which should be shown
- getMetaImageOfPage() : string
- Get the path of the set meta image of $page. If $page does not have a meta image set, then the path to the default meta image set by the basic configuration is returned instead.
- init() : mixed
- Called on construction. Override if you do not want to override the ctor.
- postRender() : mixed
- postRenderElement() : mixed
- preRender() : mixed
- preRenderElement() : mixed
- realPreRender() : mixed
- renderElement() : string
- Override this to do your representation of the tree.
- renderFooter() : mixed
- renderHeader() : mixed
- isNodeInsideCurrentBranch() : mixed
- isParentNodeInsideCurrentBranch() : mixed
Constants
styleNameActive
public
mixed
styleNameActive
= "active"
styleNameNormal
public
mixed
styleNameNormal
= "inactive"
Properties
$branchNodeIds
protected
mixed
$branchNodeIds
= array()
$bytes
protected
mixed
$bytes
$considerLogin
protected
mixed
$considerLogin
= true
$considerSeoEnabledOnly
Consider seo enabled pages alone
protected
bool
$considerSeoEnabledOnly
$currentPage
protected
mixed
$currentPage
= null
$currentPageOnRootNode
protected
mixed
$currentPageOnRootNode
= false
$currentPagePath
protected
mixed
$currentPagePath
= null
$depth
protected
mixed
$depth
= null
$em
protected
mixed
$em
= null
$lang
protected
mixed
$lang
= null
$license
protected
mixed
$license
= null
$nodeRepo
protected
mixed
$nodeRepo
$output
protected
mixed
$output
= ''
$pageIdsAtCurrentPath
protected
mixed
$pageIdsAtCurrentPath
= array()
$pageRepo
protected
mixed
$pageRepo
= null
$rootNode
protected
mixed
$rootNode
= null
$skipInactive
protected
mixed
$skipInactive
$skipInvisible
protected
mixed
$skipInvisible
= true
$startLevel
protected
mixed
$startLevel
$startPath
protected
mixed
$startPath
$template
protected
Sigma
$template
= null
$topLevelBlockName
protected
mixed
$topLevelBlockName
= null
$virtualLanguageDirectory
protected
mixed
$virtualLanguageDirectory
$virtualPagesAdded
protected
static mixed
$virtualPagesAdded
= false
Methods
__construct()
public
__construct(mixed $entityManager, mixed $license[, mixed $maxDepth = 0 ][, mixed $activeNode = null ][, mixed $lang = null ][, mixed $currentPage = null ]) : mixed
Parameters
- $entityManager : mixed
-
the doctrine em
- $license : mixed
-
License used to check if a module is allowed in frontend
- $maxDepth : mixed = 0
-
maximum depth to fetch, 0 means everything
- $activeNode : mixed = null
- $lang : mixed = null
-
the language
- $currentPage : mixed = null
-
if set, renderElement() will receive a correctly set $current flag.
isPagePathActive()
Tells wheter $pathToPage is in the active branch
public
isPagePathActive(string $pathToPage) : bool
Parameters
- $pathToPage : string
Return values
bool —True if active, false otherwise
postRenderLevel()
public
postRenderLevel(mixed $level, mixed $lang, mixed $parentNode) : mixed
Parameters
- $level : mixed
- $lang : mixed
- $parentNode : mixed
preRenderLevel()
public
preRenderLevel(mixed $level, mixed $lang, mixed $parentNode) : mixed
Parameters
- $level : mixed
- $lang : mixed
- $parentNode : mixed
render()
returns the string representation of the tree.
public
render() : string
Return values
stringsetTemplate()
public
setTemplate(mixed $template) : mixed
Parameters
- $template : mixed
-
the PEAR Sigma template.
setVirtualLanguageDirectory()
public
setVirtualLanguageDirectory(mixed $dir) : mixed
Parameters
- $dir : mixed
getFirstLevel()
Get the first level index which should be shown
protected
getFirstLevel() : int
Return values
int —the first level
getFullNavigation()
protected
getFullNavigation(int $level) : bool
Parameters
- $level : int
Return values
boolgetLastLevel()
Get the last level index which should be shown
protected
getLastLevel() : int
Return values
int —the last level
getMetaImageOfPage()
Get the path of the set meta image of $page. If $page does not have a meta image set, then the path to the default meta image set by the basic configuration is returned instead.
protected
getMetaImageOfPage(Page $page) : string
Parameters
- $page : Page
Return values
string —Path to meta image
init()
Called on construction. Override if you do not want to override the ctor.
protected
init() : mixed
postRender()
protected
postRender(mixed $lang) : mixed
Parameters
- $lang : mixed
postRenderElement()
protected
postRenderElement(mixed $level, mixed $hasChilds, mixed $lang, mixed $page) : mixed
Parameters
- $level : mixed
- $hasChilds : mixed
- $lang : mixed
- $page : mixed
preRender()
protected
preRender(mixed $lang) : mixed
Parameters
- $lang : mixed
preRenderElement()
protected
preRenderElement(mixed $level, mixed $hasChilds, mixed $lang, mixed $page) : mixed
Parameters
- $level : mixed
- $hasChilds : mixed
- $lang : mixed
- $page : mixed
realPreRender()
protected
realPreRender(mixed $lang) : mixed
Parameters
- $lang : mixed
renderElement()
Override this to do your representation of the tree.
protected
renderElement(mixed $title, mixed $level, mixed $hasChilds, mixed $lang, mixed $path, mixed $current, mixed $page) : string
Parameters
- $title : mixed
- $level : mixed
-
0-based level of the element
- $hasChilds : mixed
-
are there children of this element? if yes, they will be processed in the subsequent calls.
- $lang : mixed
-
language id
- $path : mixed
-
path to this element, e.g. '/CatA/CatB'
- $current : mixed
-
if a $currentPage has been specified, this will be set to true if either a parent element of the current element or the current element itself is rendered.
- $page : mixed
Tags
Return values
string —your string representation of the element.
renderFooter()
protected
renderFooter(mixed $lang) : mixed
Parameters
- $lang : mixed
renderHeader()
protected
renderHeader(mixed $lang) : mixed
Parameters
- $lang : mixed
isNodeInsideCurrentBranch()
private
isNodeInsideCurrentBranch(mixed $node) : mixed
Parameters
- $node : mixed
isParentNodeInsideCurrentBranch()
private
isParentNodeInsideCurrentBranch(mixed $node) : mixed
Parameters
- $node : mixed