◆ __construct()
ilChatroomSetupAgent::__construct |
( |
Refinery\Factory |
$refinery | ) |
|
◆ getArrayToConfigTransformation()
ilChatroomSetupAgent::getArrayToConfigTransformation |
( |
| ) |
|
Definition at line 79 of file class.ilChatroomSetupAgent.php.
References $data, and ILIAS\Repository\refinery().
79 : Refinery\Transformation
81 $levels = self::$LOG_LEVELS;
82 $intervals = self::$INTERVALS;
84 return $this->
refinery->custom()->transformation(
static function (
$data) use (
89 return new Setup\NullConfig();
93 if (isset(
$data[
'https']) && is_array(
$data[
'https']) &&
$data[
'https'] !== []) {
97 $deletion_interval =
false;
99 isset(
$data[
'deletion_interval']) &&
100 is_array(
$data[
'deletion_interval']) &&
$data[
'deletion_interval'] !== []
102 $deletion_interval =
true;
105 $ilias_proxy =
false;
106 if (isset(
$data[
'ilias_proxy']) && is_array(
$data[
'ilias_proxy']) &&
$data[
'ilias_proxy'] !== []) {
110 $client_proxy =
false;
111 if (isset(
$data[
'client_proxy']) && is_array(
$data[
'client_proxy']) &&
$data[
'client_proxy'] !== []) {
112 $client_proxy =
true;
115 if (isset(
$data[
'address']) && !is_string(
$data[
'address'])) {
117 '%s is not a valid value for address (must be a string). Please check your config file.',
123 isset(
$data[
'port']) && (
124 !is_numeric(
$data[
'port']) ||
125 ((
int)
$data[
'port'] < self::PORT_MIN || (
int)
$data[
'port'] > self::PORT_MAX)
129 '%s is not a valid value for port (must be between %s and %s). Please check your config file.',
136 if (isset(
$data[
'sub_directory']) && !is_string(
$data[
'sub_directory'])) {
138 '%s is not a valid value for sub_directory (must be a string). Please check your config file.',
139 $data[
'sub_directory'],
143 if (isset(
$data[
'log']) && !is_string(
$data[
'log'])) {
145 '%s is not a valid value for log (must be a string). Please check your config file.',
150 if (isset(
$data[
'error_log']) && !is_string(
$data[
'error_log'])) {
152 '%s is not a valid value for error_log (must be a string). Please check your config file.',
159 !in_array((
string) (
$data[
'log_level'] ??
''), $levels,
true)
162 '%s is not a valid value for log_level (must be one of: %s). Please check your config file.',
163 $data[
'log_level'] ??
'',
164 implode(
', ', $levels)
168 if ($deletion_interval) {
169 if (!in_array(
$data[
'deletion_interval'][
'deletion_unit'] ?? null, $intervals,
true)) {
171 '%s is not a valid value for deletion_unit (must be one of: %s). Please check your config file.',
172 $data[
'deletion_interval'][
'deletion_unit'] ??
'',
173 implode(
', ', $intervals)
177 !isset(
$data[
'deletion_interval'][
'deletion_value']) ||
178 !is_numeric(
$data[
'deletion_interval'][
'deletion_value'])
181 '%s is not a valid value for deletion_value. Please check your config file.',
182 $data[
'deletion_interval'][
'deletion_value'] ??
'' 186 !isset(
$data[
'deletion_interval'][
'deletion_time']) ||
187 !is_string(
$data[
'deletion_interval'][
'deletion_time']) ||
188 !preg_match(
'/([01][0-9]|[2][0-3]):[0-5][0-9]/',
$data[
'deletion_interval'][
'deletion_time'])
191 '%s is not a valid value for deletion_time. Please check your config file.',
192 $data[
'deletion_interval'][
'deletion_time'] ??
'' 198 $data[
'address'] ??
'',
199 (
int) (
$data[
'port'] ?? 0),
200 $data[
'sub_directory'] ??
'',
202 $data[
'https'][
'cert'] ??
'',
203 $data[
'https'][
'key'] ??
'',
204 $data[
'https'][
'dhparam'] ??
'',
206 $data[
'log_level'] ??
'',
207 $data[
'error_log'] ??
'',
209 $data[
'ilias_proxy'][
'ilias_url'] ??
'',
211 $data[
'client_proxy'][
'client_url'] ??
'',
213 $data[
'deletion_interval'][
'deletion_unit'] ??
'',
214 (
int) (
$data[
'deletion_interval'][
'deletion_value'] ?? 0),
215 $data[
'deletion_interval'][
'deletion_time'] ??
''
A configuration for the setup.
◆ getBuildArtifactObjective()
ilChatroomSetupAgent::getBuildArtifactObjective |
( |
| ) |
|
◆ getConfigInput()
ilChatroomSetupAgent::getConfigInput |
( |
Setup\Config |
$config = null | ) |
|
◆ getInstallObjective()
ilChatroomSetupAgent::getInstallObjective |
( |
Setup\Config |
$config = null | ) |
|
Definition at line 223 of file class.ilChatroomSetupAgent.php.
References $config.
228 return new Setup\Objective\NullObjective();
Store information about https is enabled.
A configuration with no content.
◆ getMigrations()
ilChatroomSetupAgent::getMigrations |
( |
| ) |
|
◆ getStatusObjective()
ilChatroomSetupAgent::getStatusObjective |
( |
Setup\Metrics\Storage |
$storage | ) |
|
◆ getUpdateObjective()
ilChatroomSetupAgent::getUpdateObjective |
( |
Setup\Config |
$config = null | ) |
|
Definition at line 237 of file class.ilChatroomSetupAgent.php.
References $config.
242 return new Setup\Objective\NullObjective();
Store information about https is enabled.
A configuration with no content.
◆ hasConfig()
ilChatroomSetupAgent::hasConfig |
( |
| ) |
|
◆ $INTERVALS
array ilChatroomSetupAgent::$INTERVALS |
|
static |
◆ $LOG_LEVELS
array ilChatroomSetupAgent::$LOG_LEVELS |
|
static |
Initial value:= [
'emerg',
'alert',
'crit',
'error',
'warning',
'notice',
'info',
'debug',
'silly'
]
Definition at line 33 of file class.ilChatroomSetupAgent.php.
◆ $refinery
Refinery Factory ilChatroomSetupAgent::$refinery |
|
protected |
◆ PORT_MAX
const ilChatroomSetupAgent::PORT_MAX = 65535 |
|
private |
◆ PORT_MIN
const ilChatroomSetupAgent::PORT_MIN = 1 |
|
private |
The documentation for this class was generated from the following file: