ILIAS
trunk Revision v11.0_alpha-3011-gc6b235a2e85
◀ ilDoc Overview
TopParentItem.php
Go to the documentation of this file.
1
<?php
2
19
declare(strict_types=1);
20
21
namespace
ILIAS\GlobalScreen\Scope\MetaBar\Factory
;
22
23
use
ILIAS\GlobalScreen\Identification\IdentificationInterface
;
24
use
ILIAS\GlobalScreen\Scope\MetaBar\Collector\Renderer\TopParentItemRenderer
;
25
use
ILIAS\UI\Component\Symbol\Symbol
;
26
30
class
TopParentItem
extends
AbstractBaseItem
implements
isItem
,
hasSymbol
,
hasTitle
,
isParent
,
hasContentLanguage
31
{
32
use
ContentLanguage
;
33
37
protected
array
$children
= [];
38
protected
?
Symbol
$symbol
=
null
;
39
protected
string
$title
=
""
;
40
44
public
function
__construct
(
IdentificationInterface
$provider_identification)
45
{
46
parent::__construct
($provider_identification);
47
$this->
renderer
=
new
TopParentItemRenderer
();
48
}
49
53
public
function
withSymbol
(
Symbol
$symbol
):
hasSymbol
54
{
55
$clone = clone($this);
56
$clone->symbol =
$symbol
;
57
58
return
$clone;
59
}
60
64
public
function
getSymbol
():
Symbol
65
{
66
return
$this->symbol
;
67
}
68
72
public
function
hasSymbol
(): bool
73
{
74
return
($this->
symbol
instanceof
Symbol
);
75
}
76
80
public
function
withTitle
(
string
$title
):
hasTitle
81
{
82
$clone = clone($this);
83
$clone->title =
$title
;
84
85
return
$clone;
86
}
87
91
public
function
getTitle
(): string
92
{
93
return
$this->title
;
94
}
95
99
public
function
getChildren
(): array
100
{
101
return
$this->children
;
102
}
103
107
public
function
withChildren
(array
$children
):
isParent
108
{
109
$clone = clone($this);
110
$clone->children =
$children
;
111
112
return
$clone;
113
}
114
118
public
function
appendChild
(
isChild
$child):
isParent
119
{
120
$this->children[] = $child;
121
122
return
$this;
123
}
124
128
public
function
hasChildren
(): bool
129
{
130
return
$this->children !== [];
131
}
132
}
renderer
renderer()
Definition:
UITestHelper.php:69
ILIAS\GlobalScreen\Scope\MetaBar\Collector\Renderer\TopParentItemRenderer
Class TopParentItemRenderer.
Definition:
TopParentItemRenderer.php:31
ILIAS\GlobalScreen\Scope\MetaBar\Factory\AbstractBaseItem
Definition:
AbstractBaseItem.php:36
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem
Definition:
TopParentItem.php:31
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\withChildren
withChildren(array $children)
@inheritDoc
Definition:
TopParentItem.php:107
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\$title
string $title
Definition:
TopParentItem.php:39
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\getTitle
getTitle()
@inheritDoc
Definition:
TopParentItem.php:91
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\hasChildren
hasChildren()
@inheritDoc
Definition:
TopParentItem.php:128
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\$children
array $children
Definition:
TopParentItem.php:37
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\withSymbol
withSymbol(Symbol $symbol)
@inheritDoc
Definition:
TopParentItem.php:53
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\$symbol
Symbol $symbol
Definition:
TopParentItem.php:38
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\appendChild
appendChild(isChild $child)
@inheritDoc
Definition:
TopParentItem.php:118
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\__construct
__construct(IdentificationInterface $provider_identification)
@inheritDoc
Definition:
TopParentItem.php:44
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\hasSymbol
hasSymbol()
@inheritDoc
Definition:
TopParentItem.php:72
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\getChildren
getChildren()
@inheritDoc
Definition:
TopParentItem.php:99
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\withTitle
withTitle(string $title)
@inheritDoc
Definition:
TopParentItem.php:80
ILIAS\GlobalScreen\Scope\MetaBar\Factory\TopParentItem\getSymbol
getSymbol()
@inheritDoc
Definition:
TopParentItem.php:64
ILIAS\GlobalScreen\Identification\IdentificationInterface
Interface IdentificationInterface.
Definition:
IdentificationInterface.php:30
ILIAS\GlobalScreen\Scope\MetaBar\Factory\hasContentLanguage
Definition:
hasContentLanguage.php:26
ILIAS\GlobalScreen\Scope\MetaBar\Factory\hasSymbol
Definition:
hasSymbol.php:31
ILIAS\GlobalScreen\Scope\MetaBar\Factory\hasTitle
Interface hasTitle.
Definition:
hasTitle.php:28
ILIAS\GlobalScreen\Scope\MetaBar\Factory\isChild
Interface isChild.
Definition:
isChild.php:30
ILIAS\GlobalScreen\Scope\MetaBar\Factory\isItem
Definition:
isItem.php:30
ILIAS\GlobalScreen\Scope\MetaBar\Factory\isParent
Interface isParent.
Definition:
isParent.php:28
ILIAS\UI\Component\Symbol\Symbol
This describes a symbol.
Definition:
Symbol.php:30
ILIAS\GlobalScreen\Provider\__construct
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
Definition:
PluginProviderHelper.php:38
ILIAS\GlobalScreen\Scope\MetaBar\Factory
Definition:
AbstractBaseItem.php:21
ILIAS\GlobalScreen\Scope\MetaBar\Factory\ContentLanguage
trait ContentLanguage
Definition:
ContentLanguage.php:26
ILIAS\Repository\symbol
symbol()
Definition:
trait.GlobalDICGUIServices.php:216
components
ILIAS
GlobalScreen
src
Scope
MetaBar
Factory
TopParentItem.php
Generated on Sat Oct 18 2025 23:03:07 for ILIAS by
1.9.4 (using
Doxyfile
)