ILIAS  release_8 Revision v8.24
class.ilAdvancedMDFieldDefinitionAddress.php
Go to the documentation of this file.
1<?php
2
3declare(strict_types=1);
4/* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
5
13{
14 public function getType(): int
15 {
16 return self::TYPE_ADDRESS;
17 }
18
19 public function getADTGroup(): ilADTDefinition
20 {
21 $def = ilADTFactory::getInstance()->getDefinitionInstanceByType("Group");
22
23 $street = ilADTFactory::getInstance()->getDefinitionInstanceByType("Text");
24 $def->addElement("street", $street);
25
26 $city = ilADTFactory::getInstance()->getDefinitionInstanceByType("Text");
27 $def->addElement("city", $city);
28
29 $loc = ilADTFactory::getInstance()->getDefinitionInstanceByType("Location");
30 $def->addElement("location", $loc);
31
32 return $def;
33 }
34
35 public function getTitles(): array
36 {
37 global $lng;
38
39 return array(
40 "street" => $lng->txt("street")
41 ,
42 "city" => $lng->txt("city")
43 ,
44 "location" => $lng->txt("location")
45 );
46 }
47}
ADT definition base class.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...