ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
TopLinkItem.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
26
31{
34
35 protected ?Symbol $symbol = null;
36 protected string $title = "";
37 protected string $action = "";
38
42 public function __construct(IdentificationInterface $provider_identification)
43 {
44 parent::__construct($provider_identification);
45 $this->renderer = new TopLinkItemRenderer();
46 }
47
48 public function withAction(string $action): self
49 {
50 $clone = clone($this);
51 $clone->action = $action;
52
53 return $clone;
54 }
55
59 public function getAction(): string
60 {
61 return $this->action;
62 }
63
68 {
69 $clone = clone($this);
70 $clone->symbol = $symbol;
71
72 return $clone;
73 }
74
78 public function getSymbol(): Symbol
79 {
80 return $this->symbol;
81 }
82
86 public function hasSymbol(): bool
87 {
88 return ($this->symbol instanceof Symbol);
89 }
90
94 public function withTitle(string $title): hasTitle
95 {
96 $clone = clone($this);
97 $clone->title = $title;
98
99 return $clone;
100 }
101
105 public function getTitle(): string
106 {
107 return $this->title;
108 }
109}
renderer()
__construct(IdentificationInterface $provider_identification)
@inheritDoc
Definition: TopLinkItem.php:42
This describes a symbol.
Definition: Symbol.php:30
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc