ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
EntryDTO.php
Go to the documentation of this file.
1<?php
2
20
21class EntryDTO implements Entry
22{
23 public function __construct(
24 private string $id,
25 private string $title,
26 private bool $active,
27 private int $position,
28 private string $parent,
29 private string $action,
30 private bool $external = true,
31 private bool $core = false
32 ) {
33 }
34
35 public function getId(): string
36 {
37 return $this->id;
38 }
39
40 public function withId(string $id): self
41 {
42 $clone = clone $this;
43 $clone->id = $id;
44 return $clone;
45 }
46
47 public function getTitle(): string
48 {
49 return $this->title;
50 }
51
52 public function withTitle(string $title): self
53 {
54 $clone = clone $this;
55 $clone->title = $title;
56 return $clone;
57 }
58
59 public function withActive(bool $active): self
60 {
61 $clone = clone $this;
62 $clone->active = $active;
63 return $clone;
64 }
65
66 public function isActive(): bool
67 {
68 return $this->active;
69 }
70
71 public function withPosition(int $position): self
72 {
73 $clone = clone $this;
74 $clone->position = $position;
75 return $clone;
76 }
77
78 public function getPosition(): int
79 {
80 return $this->position;
81 }
82
83 public function isCore(): bool
84 {
85 return $this->core;
86 }
87
88 public function getParent(): string
89 {
90 return $this->parent;
91 }
92
93 public function withParent(string $parent): self
94 {
95 $clone = clone $this;
96 $clone->parent = $parent;
97 return $clone;
98 }
99
100 public function getAction(): string
101 {
102 return $this->action;
103 }
104
105 public function withAction(string $action): Entry
106 {
107 $clone = clone $this;
108 $clone->action = $action;
109 return $clone;
110 }
111
112 public function isExternal(): bool
113 {
114 return $this->external;
115 }
116
117 public function withExternal(bool $external): Entry
118 {
119 $clone = clone $this;
120 $clone->external = $external;
121 return $clone;
122 }
123
124}
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
__construct(private string $id, private string $title, private bool $active, private int $position, private string $parent, private string $action, private bool $external=true, private bool $core=false)
Definition: EntryDTO.php:23
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...