19 declare(strict_types=1);
    43         return hash(
"sha256", self::class . $this->plugin_name);
    51         return "Update plugin $this->plugin_name.";
    69             new \ilIniFilesLoadedObjective(),
    70             new \ilDatabaseInitializedObjective(),
    71             new \ilComponentPluginAdminInitObjective(),
    72             new \ilComponentRepositoryExistsObjective(),
    73             new \ilComponentFactoryExistsObjective()
    82         $component_repository = $environment->
getResource(Setup\Environment::RESOURCE_COMPONENT_REPOSITORY);
    83         $component_factory = $environment->getResource(Setup\Environment::RESOURCE_COMPONENT_FACTORY);
    84         $info = $component_repository->getPluginByName($this->plugin_name);
    86         if (!$info->supportsCLISetup()) {
    87             throw new \RuntimeException(
    88                 "Plugin $this->plugin_name does not support command line setup."    92         if (!$info->isUpdateRequired()) {
    93             throw new \RuntimeException(
    94                 "Plugin $this->plugin_name is already updated."    98         [$ORIG_DIC, $ORIG_ilDB] = $this->
initEnvironment($environment, $component_repository, $component_factory);
    99         $plugin = $component_factory->getPlugin($info->getId());
   112         $component_repository = $environment->getResource(Setup\Environment::RESOURCE_COMPONENT_REPOSITORY);
   113         $plugin = $component_repository->getPluginByName($this->plugin_name);
   115         return $plugin->isUpdateRequired();
   123         $db = $environment->getResource(Setup\Environment::RESOURCE_DATABASE);
   124         $plugin_admin = $environment->getResource(Setup\Environment::RESOURCE_PLUGIN_ADMIN);
   125         $ini = $environment->getResource(Setup\Environment::RESOURCE_ILIAS_INI);
   126         $client_ini = $environment->getResource(Setup\Environment::RESOURCE_CLIENT_INI);
   135         $GLOBALS[
"DIC"] = 
new DI\Container();
   136         $GLOBALS[
"DIC"][
"component.repository"] = $component_repository;
   137         $GLOBALS[
"DIC"][
"component.factory"] = $component_factory;
   141         $GLOBALS[
"DIC"][
"ilClientIniFile"] = $client_ini;
   148             public static function getRootLogger(): 
ilLogger   152             public static function getLogger(
string $a_component_id): 
ilLogger   160         $GLOBALS[
"DIC"][
"ilPluginAdmin"] = $plugin_admin;
   172             public function raise($a_component, $a_event, $a_parameter = 
""): 
void   189             public array $prefs = [];
   193                 $this->prefs[
"language"] = 
"en";
   197         if (!defined(
'DEBUG')) {
   198             define(
'DEBUG', 
false);
   201         if (!defined(
'SYSTEM_ROLE_ID')) {
   202             define(
'SYSTEM_ROLE_ID', 
'2');
   205         if (!defined(
"ILIAS_ABSOLUTE_PATH")) {
   206             define(
"ILIAS_ABSOLUTE_PATH", dirname(__FILE__, 5));
   209         if (!defined(
"CLIENT_ID")) {
   210             define(
'CLIENT_ID', $client_ini->readVariable(
'client', 
'name'));
   213         if (!defined(
"ILIAS_WEB_DIR")) {
   214             define(
'ILIAS_WEB_DIR', dirname(__DIR__, 4) . 
"/data/");
   222         return [$ORIG_DIC, $ORIG_ilDB];
 
Readable part of repository interface to ilComponentDataDB. 
 
initEnvironment(Setup\Environment $environment, \ilComponentRepository $component_repository, \ilComponentFactory $component_factory)
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
parses the objects.xml it handles the xml-description of all ilias objects 
 
Read the client id of the installation from the data directory. 
 
__construct(string $plugin_name)
 
getResource(string $id)
Consumers of this method should check if the result is what they expect, e.g. 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
getPreconditions(Setup\Environment $environment)
 
An environment holds resources to be used in the setup process. 
 
Class ilRbacAdmin Core functions for role based access control. 
 
isApplicable(Setup\Environment $environment)
 
achieve(Setup\Environment $environment)