ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
LOMDictionary.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
25
26class LOMDictionary extends BaseDictionary implements DictionaryInterface
27{
28 public function tagForElement(
30 ): ?TagInterface {
31 foreach (parent::tagsForElement($element) as $tag) {
32 if (!($tag instanceof TagInterface)) {
33 throw new \ilMDRepositoryException('Invalid dictionary');
34 }
35 return $tag;
36 }
37 return null;
38 }
39}
tagForElement(BaseElementInterface $element)
tagsForElement(BaseElementInterface $element)
If possible, takes into account the index of elements when finding tags (beginning with 0).
Definition: Dictionary.php:59