12        return hash(
"sha256", self::class);
 
   17        return "The database is updated.";
 
   30            new \ilDatabaseInitializedObjective()
 
   36        $db = $environment->
getResource(Setup\Environment::RESOURCE_DATABASE);
 
   37        $io = $environment->getResource(Setup\Environment::RESOURCE_ADMIN_INTERACTION);
 
   38        $ini = $environment->getResource(Setup\Environment::RESOURCE_ILIAS_INI);
 
   39        $client_ini = $environment->getResource(Setup\Environment::RESOURCE_CLIENT_INI);
 
   40        $client_id = $environment->getResource(Setup\Environment::RESOURCE_CLIENT_ID);
 
   51        $GLOBALS[
"DIC"][
"ilLog"] = 
new class($io) {
 
   56            public function write()
 
   59            public function info()
 
   62            public function warning($msg)
 
   64                $this->io->inform($msg);
 
   66            public function error($msg)
 
   69                    "Problem in DB-Update: $msg" 
   74        $GLOBALS[
"DIC"][
"ilLoggerFactory"] = 
new class() {
 
   75            public function getRootLogger()
 
   78                    public function write()
 
   84        $GLOBALS[
"ilCtrlStructureReader"] = 
new class() {
 
   85            public function getStructure()
 
   88            public function setIniFile()
 
   92        if (!defined(
"CLIENT_DATA_DIR")) {
 
   93            define(
"CLIENT_DATA_DIR", 
$ini->readVariable(
"clients", 
"datadir") . 
"/" . 
$client_id);
 
   95        if (!defined(
"CLIENT_WEB_DIR")) {
 
   96            define(
"CLIENT_WEB_DIR", dirname(__DIR__, 4) . 
"/data/" . 
$client_id);
 
   98        if (!defined(
"ILIAS_ABSOLUTE_PATH")) {
 
   99            define(
"ILIAS_ABSOLUTE_PATH", dirname(__FILE__, 5));
 
  101        if (!defined(
"ILIAS_LOG_ENABLED")) {
 
  102            define(
"ILIAS_LOG_ENABLED", 
false);
 
  104        if (!defined(
"ROOT_FOLDER_ID")) {
 
  105            define(
"ROOT_FOLDER_ID", $client_ini->readVariable(
"system", 
"ROOT_FOLDER_ID"));
 
  107        if (!defined(
"ROLE_FOLDER_ID")) {
 
  108            define(
"ROLE_FOLDER_ID", $client_ini->readVariable(
"system", 
"ROLE_FOLDER_ID"));
 
  110        if (!defined(
"SYSTEM_FOLDER_ID")) {
 
  111            define(
"SYSTEM_FOLDER_ID", $client_ini->readVariable(
"system", 
"SYSTEM_FOLDER_ID"));
 
  114        $db_update = 
new class($db, $client_ini) extends 
ilDBUpdate {
 
  115            public function loadXMLInfo()
 
  121        $db_update->applyHotfix();
 
  122        $db_update->applyCustomUpdates();
 
if(!defined('PATH_SEPARATOR')) $GLOBALS['_PEAR_default_error_mode']
An exception for terminatinating execution or to throw for unit testing.
Customizing of pimple-DIC for ILIAS.
Read the client id of the installation from the data directory.
Signals that some goal won't be achievable by actions of the system ever.
error($a_errmsg)
set error message @access public
applyUpdate($a_break=0)
Apply update.
achieve(Setup\Environment $environment)
getPreconditions(Setup\Environment $environment)
isApplicable(Setup\Environment $environment)
@inheritDoc
An environment holds resources to be used in the setup process.
getResource(string $id)
Consumers of this method should check if the result is what they expect, e.g.
An objective is a desired state of the system that is supposed to be created by the setup.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...