ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
class.ilADTLocalizedTextDefinition.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
26 {
30  private array $active_languages = [];
31  private string $default_language = '';
32  private ?int $max_length = null;
33 
34  public function getMaxLength(): ?int
35  {
36  return $this->max_length;
37  }
38 
39  public function setMaxLength(?int $max_length): void
40  {
41  $this->max_length = $max_length;
42  }
43 
47  public function getActiveLanguages(): array
48  {
50  }
51 
52  public function setActiveLanguages(array $active): void
53  {
54  $this->active_languages = $active;
55  }
56 
60  public function isComparableTo(ilADT $a_adt): bool
61  {
62  return $a_adt instanceof ilADTLocalizedText;
63  }
64 
68  public function getDefaultLanguage(): string
69  {
71  }
72 
76  public function setDefaultLanguage(string $default_language): void
77  {
78  $this->default_language = $default_language;
79  }
80 
84  public function supportsTranslations(): bool
85  {
86  return strlen($this->getDefaultLanguage()) > 0;
87  }
88 }
ADT base class.
Definition: class.ilADT.php:11
Class ilADTLocalizedText.
ADT definition base class.