ILIAS
trunk Revision v11.0_alpha-3011-gc6b235a2e85
◀ ilDoc Overview
LOMDictionary.php
Go to the documentation of this file.
1
<?php
2
19
declare(strict_types=1);
20
21
namespace
ILIAS\MetaData\Repository\Dictionary
;
22
23
use
ILIAS\MetaData\Elements\Base\BaseElementInterface
;
24
use
ILIAS\MetaData\Structure\Dictionaries\Dictionary
as BaseDictionary;
25
26
use
function
PHPUnit\Framework\throwException;
27
28
class
LOMDictionary
extends
BaseDictionary implements
DictionaryInterface
29
{
30
public
function
tagForElement
(
31
BaseElementInterface
$element
32
): ?
TagInterface
{
33
foreach (parent::
tagsForElement
($element) as $tag) {
34
if
(!($tag instanceof
TagInterface
)) {
35
throw
new \ilMDRepositoryException(
'Invalid dictionary'
);
36
}
37
return
$tag;
38
}
39
return
null
;
40
}
41
}
ILIAS\MetaData\Repository\Dictionary\LOMDictionary
Definition:
LOMDictionary.php:29
ILIAS\MetaData\Repository\Dictionary\LOMDictionary\tagForElement
tagForElement(BaseElementInterface $element)
Definition:
LOMDictionary.php:30
ILIAS\MetaData\Structure\Dictionaries\Dictionary
Definition:
Dictionary.php:33
ILIAS\MetaData\Structure\Dictionaries\Dictionary\tagsForElement
tagsForElement(BaseElementInterface $element)
If possible, takes into account the index of elements when finding tags (beginning with 0).
Definition:
Dictionary.php:59
ILIAS\MetaData\Elements\Base\BaseElementInterface
Definition:
BaseElementInterface.php:28
ILIAS\MetaData\Repository\Dictionary\DictionaryInterface
Definition:
DictionaryInterface.php:26
ILIAS\MetaData\Repository\Dictionary\TagInterface
Definition:
TagInterface.php:26
ILIAS\MetaData\Repository\Dictionary
Definition:
DictionaryInterface.php:21
components
ILIAS
MetaData
classes
Repository
Dictionary
LOMDictionary.php
Generated on Sat Oct 18 2025 23:03:26 for ILIAS by
1.9.4 (using
Doxyfile
)