Elgg
Version 2.3
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
engine
classes
Elgg
Menu
UnpreparedMenu.php
Go to the documentation of this file.
1
<?php
2
namespace
Elgg\Menu
;
3
4
use
ElggMenuItem
;
5
11
class
UnpreparedMenu
{
12
16
private
$items;
17
21
private
$params;
22
33
public
function
__construct
(array $params, array $items) {
34
$this->params = $params;
35
$this->items = $items;
36
}
37
47
public
function
setSortBy
($sort_by =
'text'
) {
48
$this->params[
'sort_by'
] = $sort_by;
49
}
50
59
public
function
getSortBy
() {
60
return
elgg_extract
(
'sort_by'
, $this->params,
'text'
);
61
}
62
68
public
function
getName
() {
69
return
$this->params[
'name'
];
70
}
71
77
public
function
getItems
() {
78
return
$this->items;
79
}
80
86
public
function
getParams
() {
87
return
$this->params;
88
}
89
}
Elgg\Menu\UnpreparedMenu\getSortBy
getSortBy()
Get the designated (or default) sort strategy.
Definition:
UnpreparedMenu.php:59
Elgg\Menu\UnpreparedMenu\__construct
__construct(array $params, array $items)
Constructor.
Definition:
UnpreparedMenu.php:33
ElggMenuItem
Elgg\Menu
Definition:
Menu.php:2
Elgg\Menu\UnpreparedMenu\getParams
getParams()
Get the menu parameters.
Definition:
UnpreparedMenu.php:86
Elgg\Menu\UnpreparedMenu\setSortBy
setSortBy($sort_by= 'text')
Set how this menu should be sorted.
Definition:
UnpreparedMenu.php:47
Elgg\Menu\UnpreparedMenu
Linear set of menu items collected from configuration and the "register" hook.
Definition:
UnpreparedMenu.php:11
Elgg\Menu\UnpreparedMenu\getName
getName()
Get the menu name.
Definition:
UnpreparedMenu.php:68
elgg_extract
elgg_extract($key, $array, $default=null, $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition:
elgglib.php:1375
Elgg\Menu\UnpreparedMenu\getItems
getItems()
Get the menu items.
Definition:
UnpreparedMenu.php:77
use
http free of to any person obtaining a copy of this software and associated documentation to deal in the Software without including without limitation the rights to use
Definition:
MIT-LICENSE.txt:5
Generated on Sat Dec 21 2024 00:01:03 for Elgg by
1.8.11