ILIAS  trunk Revision v11.0_alpha-1744-gb0451eebef4
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
TopLegacyItem.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
27 
32 {
33  use ContentLanguage;
34 
35  protected ?Symbol $symbol = null;
36  protected string $title = "";
37  protected ?Content $content = null;
38 
42  public function __construct(IdentificationInterface $provider_identification)
43  {
44  parent::__construct($provider_identification);
45  $this->renderer = new TopLegacyItemRenderer();
46  }
47 
51  public function withSymbol(Symbol $symbol): hasSymbol
52  {
53  $clone = clone($this);
54  $clone->symbol = $symbol;
55 
56  return $clone;
57  }
58 
62  public function getSymbol(): Symbol
63  {
64  return $this->symbol;
65  }
66 
70  public function hasSymbol(): bool
71  {
72  return ($this->symbol instanceof Symbol);
73  }
74 
78  public function withTitle(string $title): hasTitle
79  {
80  $clone = clone($this);
81  $clone->title = $title;
82 
83  return $clone;
84  }
85 
89  public function getTitle(): string
90  {
91  return $this->title;
92  }
93 
94  public function withLegacyContent(Content $content): self
95  {
96  $clone = clone $this;
97  $clone->content = $content;
98 
99  return $clone;
100  }
101 
105  public function getLegacyContent(): Content
106  {
107  return $this->content;
108  }
109 
113  public function hasLegacyContent(): bool
114  {
115  return ($this->content instanceof Legacy);
116  }
117 }
This describes a symbol.
Definition: Symbol.php:29
renderer()
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
__construct(IdentificationInterface $provider_identification)
__construct(Container $dic, ilPlugin $plugin)