ILIAS  trunk Revision v11.0_alpha-1831-g8615d53dadb
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings Class Reference
+ Collaboration diagram for ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings:

Public Member Functions

 __construct (private bool $logging_enabled=false, private bool $ip_logging_enabled=true)
 
 toForm (UIFactory $ui_factory, Refinery $refinery, \ilLanguage $lng)
 
 isLoggingEnabled ()
 
 withLoggingEnabled (bool $logging_enabled)
 
 isIPLoggingEnabled ()
 
 withIPLoggingEnabled (bool $ip_logging_enabled)
 

Detailed Description

Definition at line 26 of file TestLoggingSettings.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::__construct ( private bool  $logging_enabled = false,
private bool  $ip_logging_enabled = true 
)

Definition at line 28 of file TestLoggingSettings.php.

31  {
32  }

Member Function Documentation

◆ isIPLoggingEnabled()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::isIPLoggingEnabled ( )

Definition at line 74 of file TestLoggingSettings.php.

Referenced by ILIAS\Test\Settings\GlobalSettings\Repository\storeLoggingSettings(), and ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings\toForm().

74  : bool
75  {
76  return $this->ip_logging_enabled;
77  }
+ Here is the caller graph for this function:

◆ isLoggingEnabled()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::isLoggingEnabled ( )

Definition at line 62 of file TestLoggingSettings.php.

Referenced by ILIAS\Test\Settings\GlobalSettings\Repository\storeLoggingSettings(), and ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings\toForm().

62  : bool
63  {
64  return $this->logging_enabled;
65  }
+ Here is the caller graph for this function:

◆ toForm()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::toForm ( UIFactory  $ui_factory,
Refinery  $refinery,
\ilLanguage  $lng 
)
Returns
array<ILIAS>

Definition at line 38 of file TestLoggingSettings.php.

References ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings\isIPLoggingEnabled(), ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings\isLoggingEnabled(), ilLanguage\txt(), ILIAS\UI\Implementation\Component\Input\ViewControl\withAdditionalTransformation(), and ILIAS\UI\Implementation\Component\Input\withValue().

42  : array {
43  $trafo = $refinery->custom()->transformation(
44  static fn($vs): self => new self($vs['activation'], $vs['ip_logging'])
45  );
46  return [
47  'logging' => $ui_factory->input()->field()->section(
48  [
49  'activation' => $ui_factory->input()->field()->checkbox(
50  $lng->txt('activate_logging')
51  )->withValue($this->isLoggingEnabled()),
52  'ip_logging' => $ui_factory->input()->field()->checkbox(
53  $lng->txt('log_ip')
54  )->withByline($lng->txt('log_ip_info'))
55  ->withValue($this->isIPLoggingEnabled())
56  ],
57  $lng->txt('logging_settings')
59  ];
60  }
withValue($value)
Get an input like this with another value displayed on the client side.
Definition: Group.php:61
global $lng
Definition: privfeed.php:31
+ Here is the call graph for this function:

◆ withIPLoggingEnabled()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::withIPLoggingEnabled ( bool  $ip_logging_enabled)

Definition at line 79 of file TestLoggingSettings.php.

79  : self
80  {
81  $clone = clone $this;
82  $clone->ip_logging_enabled = $ip_logging_enabled;
83  return $clone;
84  }

◆ withLoggingEnabled()

ILIAS\Test\Settings\GlobalSettings\TestLoggingSettings::withLoggingEnabled ( bool  $logging_enabled)

Definition at line 67 of file TestLoggingSettings.php.

67  : self
68  {
69  $clone = clone $this;
70  $clone->logging_enabled = $logging_enabled;
71  return $clone;
72  }

The documentation for this class was generated from the following file: