19 declare(strict_types=1);
53 ?
int $current_db_version,
58 string $responsible_mail,
59 bool $supports_learning_progress,
60 bool $supports_export,
61 bool $supports_cli_setup
63 if ($current_version ===
null && $current_db_version !==
null) {
64 throw new \InvalidArgumentException(
65 "If there is no current version for the plugin, we also should not " .
94 return $this->pluginslot->getComponent();
114 return implode(
'/', [
125 return "il" . $this->
getName() .
"Plugin";
130 return "il" . $this->
getName() .
"ConfigGUI";
197 return $this->current_version !==
null;
205 return $this->
isInstalled() && !$this->current_version->equals($this->available_version);
214 return $this->current_version->isGreaterThan($this->available_version);
224 $this->actual_ilias_version->isGreaterThanOrEquals($this->minimum_ilias_version)
225 && $this->actual_ilias_version->isSmallerThanOrEquals($this->maximum_ilias_version);
257 throw new \LogicException(
258 "Plugin is active, so no reason for inactivity." 263 return "cmps_needs_matching_ilias_version";
267 return "cmps_must_installed";
271 return "cmps_needs_upgrade";
275 return "cmps_needs_update";
279 return "cmps_not_activated";
282 throw new \LogicException(
283 "Unknown reason for inactivity of the plugin." Version $minimum_ilias_version
bool $supports_learning_progress
ilPluginSlotInfo $pluginslot
Simple value class for basic information about a pluginslot.
isActive()
Is this plugin active right now?
Version $available_version
isInstalled()
"Installed" tells if the plugin has some installed version.
isActivationPossible()
Can this plugin be activated right now.
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
isCompliantToILIAS()
"ILIAS Version compliance" tells if the plugin can be operated with the given ILIAS version...
isUpdateRequired()
"Update required" tells if the plugin needs an update.
isVersionToOld()
"Version to old" tells if the plugin code has a version that is below the version that was updated la...
Version $maximum_ilias_version
Simple value class for information about a plugin.
getReasonForInactivity()
Which is the reason for the inactivity?
isActivated()
"activated" tells if the administrator of the installation wants the plugin to be effective...
A version number that consists of three numbers (major, minor, patch).
supportsLearningProgress()
Version $actual_ilias_version
Simple value class for basic information about a component.
__construct(Version $actual_ilias_version, ilPluginSlotInfo $pluginslot, string $id, string $name, string $type, bool $activated, ?Version $current_version, ?int $current_db_version, Version $available_version, Version $minimum_ilias_version, Version $maximum_ilias_version, string $responsible, string $responsible_mail, bool $supports_learning_progress, bool $supports_export, bool $supports_cli_setup)