19declare(strict_types=1);
40 $language_identification =
"{$identification->serialize()}|$language_key";
41 $mt = ilMMItemTranslationStorage::find($language_identification);
44 $mt->setId($language_identification);
76 $key =
"{$identification->serialize()}|$lng";
80 if (($item = self::find($key)) !==
null) {
81 return $item->getTranslation();
94 $key =
"{$identification->serialize()}|$lng";
96 return self::find($key) instanceof
self;
104 static $default_language;
106 if (!isset($default_language)) {
107 $default_language =
$DIC->language()->getDefaultLanguage() ?:
"en";
110 return $default_language;
120 protected ?
string $id =
null;
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilMMItemTranslationStorage.
string $connector_container_name
static hasDefaultTranslation(IdentificationInterface $identification)
string $translation
@con_has_field true @con_fieldtype text @con_length 4000
setLanguageKey(string $language_key)
string $id
@con_is_primary true @con_is_unique true @con_has_field true @con_fieldtype text @con_length 64
string $identification
@con_has_field true @con_fieldtype text @con_length 256
static storeDefaultTranslation(IdentificationInterface $identification, string $translation)
setIdentification(string $identification)
setTranslation(string $translation)
static storeTranslation(IdentificationInterface $identification, string $language_key, string $translation)
static getDefaultLanguage()
string $language_key
@con_has_field true @con_fieldtype text @con_length 8
Interface IdentificationInterface.