Property | Type | Description | |
---|---|---|---|
$action | string | The action which should be executed when clicking on this NavigationItem. | |
$children | array | Contains the children of this item, which are other NavigationItems. | |
$disabled | boolean | Defines if item is disabled. | |
$displayOption | string | Describes how the navigation item should be shown in husky. | |
$hasSettings | boolean | Defines if this menu item has settings. | |
$headerIcon | string | The icon of the header are of the NavigationItem. | |
$headerTitle | string | The title of the head area of the NavigationItem. | |
$icon | string | The icon of the navigationItem. | |
$id | string | The id of the NavigationItem. | |
$name | string | The name being displayed in the navigation. | |
$position | integer | The current position of the iterator. |
Method | Description | |
---|---|---|
__construct ( string $name, |
||
addChild ( |
Adds a child to the navigation item. | |
copyChildless ( ) : |
Returns a copy of this navigation item without its children. | |
current ( ) : mixed | Return the current element. | |
equalsChildless ( |
Compares this item with another one, but doesn't check the children. | |
find ( |
Searches for the equivalent of a specific NavigationItem. | |
findChildren ( |
Searches for a specific NavigationItem in the children of this NavigationItem. | |
getAction ( ) : string | Returns the action of the NavigationItem. | |
getChildren ( ) : array | Returns all children from this navigation item. | |
getDisabled ( ) : boolean | ||
getEvent ( ) : string | ||
getEventArguments ( ) : string | ||
getHasSettings ( ) : boolean | ||
getHeaderIcon ( ) : string | Returns the icon of the header. | |
getHeaderTitle ( ) : string | Returns the title of the header. | |
getIcon ( ) : string | Returns the action of the NavigationItem. | |
getId ( ) : string | Returns the id of the NavigationItem. | |
getName ( ) : string | Returns the name being displayed in the navigation. | |
getPosition ( ) : integer | ||
hasChildren ( ) : boolean | Checks if the NavigationItem has some children. | |
key ( ) : mixed | Return the key of the current element. | |
merge ( |
Merges this navigation item with the other parameter and returns a new NavigationItem. | |
next ( ) | Move forward to next element. | |
rewind ( ) | Rewind the Iterator to the first element. | |
setAction ( string $action ) | Sets the action of the NavigationItem. | |
setDisabled ( boolean $disabled ) | ||
setEvent ( string $event ) | ||
setEventArguments ( $eventArguments ) | ||
setHasSettings ( boolean $hasSettings ) | ||
setHeaderIcon ( string $headerIcon ) | Sets the icon of the header. | |
setHeaderTitle ( string $headerTitle ) | Sets the title of the header. | |
setIcon ( string $icon ) | Set the icon of the NavigaitonItem. | |
setId ( string $id ) | Sets the id of the NavigationItem. | |
setName ( string $name ) | Sets the name being displayed in the navigation. | |
setPosition ( integer $position ) | ||
toArray ( ) : array | Returns the content of the NavigationItem as array. | |
valid ( ) : boolean | Checks if current position is valid. |
Method | Description | |
---|---|---|
copyWithName ( ) : |
Create a new instance of current navigation item class. |
public __construct ( string $name, |
||
$name | string | The name of the item |
$parent | The parent of the item |
public addChild ( |
||
$child |
public copyChildless ( ) : |
||
return |
protected copyWithName ( ) : |
||
return |
public equalsChildless ( |
||
$other | The other NavigationItem of the comparison | |
return | boolean | True if the NavigationItems are equal, otherwise false |
public find ( |
||
$navigationItem | The NavigationItem to look for | |
return | The item if it is found, otherwise false |
public findChildren ( |
||
$navigationItem | The navigationItem we look for | |
return | Null if the NavigationItem is not found, otherwise the found NavigationItem |
public getChildren ( ) : array | ||
return | array |
public getHeaderIcon ( ) : string | ||
return | string |
public getHeaderTitle ( ) : string | ||
return | string | The title of the header |
public hasChildren ( ) : boolean | ||
return | boolean | True if the item has children, otherwise false |
public merge ( |
||
$other | The navigation item this one should be merged with | |
return |
public setHeaderIcon ( string $headerIcon ) | ||
$headerIcon | string |
public setHeaderTitle ( string $headerTitle ) | ||
$headerTitle | string | The title of the header |
protected string $action | ||
return | string |
protected array $children | ||
return | array |
protected string $displayOption | ||
return | string |
protected bool $hasSettings | ||
return | boolean |
protected string $headerIcon | ||
return | string |
protected string $headerTitle | ||
return | string |
protected string $name | ||
return | string |
protected int $position | ||
return | integer |