ILIAS  trunk Revision v13.0_alpha-62-g3b72d83f2e5
CollectSettingsObjective.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
21namespace ILIAS\User\Settings;
22
26
28{
29 public function __construct(
30 private readonly array $contributions
31 ) {
32 }
33
34 public function getArtifactName(): string
35 {
36 return 'user_settings';
37 }
38
39 public function build(): Artifact
40 {
41 return new ArrayArtifact(
42 array_reduce(
43 $this->contributions,
44 static fn(array $c, UserSettings $settings): array => array_merge($c, $settings->getSettingConfigurations()),
45 []
46 )
47 );
48 }
49}
$settings
Definition: index.php:44
An array as an artifact.
This is an objective to build some artifact.
getArtifactName()
Get the filename where the builder wants to put its artifact.
__construct(private readonly array $contributions)
An artifact is some file that is build on demand per installation and is not shipped with the ILIAS s...
Definition: Artifact.php:28
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...