1 | <?php |
||
10 | class MenuBuilder |
||
11 | { |
||
12 | /** |
||
13 | * @var EventDispatcherInterface |
||
14 | */ |
||
15 | private $eventDispatcher; |
||
16 | |||
17 | /** |
||
18 | * @var FactoryInterface |
||
19 | */ |
||
20 | private $factory; |
||
21 | |||
22 | /** |
||
23 | * @param EventDispatcherInterface $eventDispatcher |
||
24 | */ |
||
25 | 9 | public function setEventDispatcher($eventDispatcher) |
|
29 | |||
30 | /** |
||
31 | * @return EventDispatcherInterface |
||
32 | */ |
||
33 | 1 | public function getEventDispatcher() |
|
37 | |||
38 | /** |
||
39 | * @param FactoryInterface $factory |
||
40 | */ |
||
41 | 9 | public function setFactory($factory) |
|
45 | |||
46 | /** |
||
47 | * @return \Knp\Menu\FactoryInterface |
||
48 | */ |
||
49 | 9 | public function getFactory() |
|
53 | |||
54 | /** |
||
55 | * @return ItemInterface |
||
56 | */ |
||
57 | 8 | public function createMainMenu() |
|
74 | |||
75 | /** |
||
76 | * Reorderd the items in the menu based on the extra data |
||
77 | * |
||
78 | * @param ItemInterface $menu |
||
79 | */ |
||
80 | 8 | protected function reorderMenuItems(ItemInterface $menu) |
|
135 | } |
||
136 |