1 | <?php |
||
35 | class Definition |
||
36 | { |
||
37 | /** |
||
38 | * The human readable activity name |
||
39 | * @var LanguageMap|null |
||
40 | */ |
||
41 | private $name; |
||
42 | |||
43 | /** |
||
44 | * The human readable activity description |
||
45 | * @var LanguageMap|null |
||
46 | */ |
||
47 | private $description; |
||
48 | |||
49 | /** |
||
50 | * @var IRI|null The type of the {@link Activity} |
||
51 | */ |
||
52 | private $type; |
||
53 | |||
54 | /** |
||
55 | * An IRL where human-readable information describing the {@link Activity} can be found. |
||
56 | * |
||
57 | * @var IRL|null |
||
58 | */ |
||
59 | private $moreInfo; |
||
60 | |||
61 | /** |
||
62 | * Extensions associated with the {@link Activity}. |
||
63 | * |
||
64 | * @var Extensions|null |
||
65 | */ |
||
66 | private $extensions; |
||
67 | |||
68 | /** |
||
69 | * @param LanguageMap|null $name |
||
70 | * @param LanguageMap|null $description |
||
71 | * @param IRI|null $type |
||
72 | * @param IRL|null $moreInfo |
||
73 | * @param Extensions|null $extensions |
||
74 | */ |
||
75 | public function __construct(LanguageMap $name = null, LanguageMap $description = null, IRI $type = null, IRL $moreInfo = null, Extensions $extensions = null) |
||
83 | |||
84 | public function withName(LanguageMap $name = null) |
||
91 | |||
92 | public function withDescription(LanguageMap $description = null) |
||
99 | |||
100 | /** |
||
101 | * @param IRI|null $type |
||
102 | * |
||
103 | * @return static |
||
104 | */ |
||
105 | public function withType(IRI $type = null) |
||
112 | |||
113 | /** |
||
114 | * @param IRL|null $moreInfo |
||
115 | * |
||
116 | * @return static |
||
117 | */ |
||
118 | public function withMoreInfo(IRL $moreInfo = null) |
||
125 | |||
126 | public function withExtensions(Extensions $extensions) |
||
133 | |||
134 | /** |
||
135 | * Returns the human readable names. |
||
136 | * |
||
137 | * @return LanguageMap|null The name language map |
||
138 | */ |
||
139 | public function getName() |
||
143 | |||
144 | /** |
||
145 | * Returns the human readable descriptions. |
||
146 | * |
||
147 | * @return LanguageMap|null The description language map |
||
148 | */ |
||
149 | public function getDescription() |
||
153 | |||
154 | /** |
||
155 | * Returns the {@link Activity} type. |
||
156 | * |
||
157 | * @return IRI|null The type |
||
158 | */ |
||
159 | public function getType() |
||
163 | |||
164 | /** |
||
165 | * Returns an IRL where human-readable information about the activity can be found. |
||
166 | * |
||
167 | * @return IRL|null |
||
168 | */ |
||
169 | public function getMoreInfo() |
||
173 | |||
174 | public function getExtensions() |
||
178 | |||
179 | /** |
||
180 | * Checks if another definition is equal. |
||
181 | * |
||
182 | * Two definitions are equal if and only if all of their properties are equal. |
||
183 | * |
||
184 | * @param Definition $definition The definition to compare with |
||
185 | * |
||
186 | * @return bool True if the definitions are equal, false otherwise |
||
187 | */ |
||
188 | public function equals(Definition $definition) |
||
260 | } |
||
261 |