19 declare(strict_types=1);
28 $pw = $this->config->getPassword();
29 return hash(
"sha256", implode(
"-", [
31 $this->config->getHost(),
32 $this->config->getPort(),
33 $this->config->getUser(),
34 $pw !==
null ? $pw->toString() :
"" 40 return "The database server is connectable with the supplied configuration.";
56 $db->initFromIniFile($this->config->toMockIniFile());
58 $connect = $db->connect();
59 }
catch (PDOException
$e) {
62 if ($e->getCode() !== 1049) {
70 "Database cannot be reached. Please check the credentials." getPreconditions(Environment $environment)
Objectives might depend on other objectives.
getHash()
Get a hash for this objective.
achieve(Environment $environment)
Objectives can be achieved.
static getWrapper(string $a_type)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
Signals that some goal won't be achievable by actions of the system ever.
getLabel()
Get a label that describes this objective.
isApplicable(Environment $environment)
An environment holds resources to be used in the setup process.
isNotable()
Get to know if this is an interesting objective for a human.