Model for a menu that can be presented in a skin.
More...
Model for a menu that can be presented in a skin.
◆ __construct()
MediaWiki\Minerva\Menu\Group::__construct |
( |
| $id | ) |
|
- Parameters
-
string | $id | of the menu defaults to null (optional) |
◆ getEntries()
MediaWiki\Minerva\Menu\Group::getEntries |
( |
| ) |
|
Get all entries represented as plain old PHP arrays.
- Returns
- array
◆ getEntryByName()
MediaWiki\Minerva\Menu\Group::getEntryByName |
( |
string | $targetName | ) |
|
- Parameters
-
- Returns
- IMenuEntry
- Exceptions
-
◆ getId()
MediaWiki\Minerva\Menu\Group::getId |
( |
| ) |
|
Get the identifier for the group.
- Returns
- string
◆ hasEntries()
MediaWiki\Minerva\Menu\Group::hasEntries |
( |
| ) |
|
Return entries count.
- Returns
- bool
◆ insertEntry()
MediaWiki\Minerva\Menu\Group::insertEntry |
( |
IMenuEntry | $entry | ) |
|
Insert new menu entry.
- Parameters
-
- Exceptions
-
DomainException | When the entry already exists |
◆ prependEntry()
MediaWiki\Minerva\Menu\Group::prependEntry |
( |
IMenuEntry | $entry | ) |
|
Prepend new menu entry.
- Parameters
-
- Exceptions
-
DomainException | When the entry already exists |
◆ serialize()
MediaWiki\Minerva\Menu\Group::serialize |
( |
| ) |
|
Serialize the group for use in a template.
- Returns
- array{entries:array,id:string}
The documentation for this class was generated from the following file: