ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilLoggingErrorSettings Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Collaboration diagram for ilLoggingErrorSettings:

Public Member Functions

 setMail (string $mail)
 
 folder ()
 
 mail ()
 
 update ()
 writes mail recipient into client.ini.php More...
 

Static Public Member Functions

static getInstance ()
 

Protected Member Functions

 __construct ()
 
 setFolder (string $folder)
 
 read ()
 reads the values from ilias.ini.php More...
 

Protected Attributes

string $folder = ''
 
string $mail = ''
 
ilIniFile $ilias_ini = null
 
ilIniFile $gClientIniFile = null
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Settings for the error protcoll system

Author
Stefan Hecken stefa.nosp@m.n.he.nosp@m.cken@.nosp@m.conc.nosp@m.epts-.nosp@m.and-.nosp@m.train.nosp@m.ing..nosp@m.de

Definition at line 24 of file class.ilLoggingErrorSettings.php.

Constructor & Destructor Documentation

◆ __construct()

ilLoggingErrorSettings::__construct ( )
protected

Definition at line 31 of file class.ilLoggingErrorSettings.php.

References $DIC, and read().

32  {
33  global $DIC;
34 
35  if ($DIC->offsetExists('ilIliasIniFile')) {
36  $this->ilias_ini = $DIC->iliasIni();
37  } elseif ($DIC->offsetExists('ini')) {
38  $this->ilias_ini = $DIC['ini'];
39  }
40  if ($DIC->offsetExists('ilClientIniFile')) {
41  $this->gClientIniFile = $DIC->clientIni();
42  }
43  $this->read();
44  }
read()
reads the values from ilias.ini.php
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

Member Function Documentation

◆ folder()

ilLoggingErrorSettings::folder ( )

Definition at line 61 of file class.ilLoggingErrorSettings.php.

References $folder.

Referenced by setFolder().

61  : string
62  {
63  return $this->folder;
64  }
+ Here is the caller graph for this function:

◆ getInstance()

static ilLoggingErrorSettings::getInstance ( )
static

Definition at line 46 of file class.ilLoggingErrorSettings.php.

Referenced by ilLoggerCronCleanErrorFiles\__construct(), ilErrorHandling\defaultHandler(), and ilObjLoggingSettingsGUI\initErrorSettings().

47  {
48  return new ilLoggingErrorSettings();
49  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the caller graph for this function:

◆ mail()

ilLoggingErrorSettings::mail ( )

Definition at line 66 of file class.ilLoggingErrorSettings.php.

References $mail.

Referenced by setMail(), and update().

66  : string
67  {
68  return $this->mail;
69  }
+ Here is the caller graph for this function:

◆ read()

ilLoggingErrorSettings::read ( )
protected

reads the values from ilias.ini.php

Definition at line 74 of file class.ilLoggingErrorSettings.php.

References setFolder(), and setMail().

Referenced by __construct().

74  : void
75  {
76  if ($this->ilias_ini instanceof ilIniFile) {
77  $this->setFolder((string) $this->ilias_ini->readVariable("log", "error_path"));
78  }
79  if ($this->gClientIniFile instanceof \ilIniFile) {
80  $this->setMail((string) $this->gClientIniFile->readVariable("log", "error_recipient"));
81  }
82  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setFolder()

ilLoggingErrorSettings::setFolder ( string  $folder)
protected

Definition at line 51 of file class.ilLoggingErrorSettings.php.

References $folder, and folder().

Referenced by read().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setMail()

ilLoggingErrorSettings::setMail ( string  $mail)

Definition at line 56 of file class.ilLoggingErrorSettings.php.

References $mail, and mail().

Referenced by read().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ update()

ilLoggingErrorSettings::update ( )

writes mail recipient into client.ini.php

Definition at line 87 of file class.ilLoggingErrorSettings.php.

References mail().

87  : void
88  {
89  if ($this->gClientIniFile instanceof \ilIniFile) {
90  $this->gClientIniFile->addGroup("log");
91  $this->gClientIniFile->setVariable("log", "error_recipient", trim($this->mail()));
92  $this->gClientIniFile->write();
93  }
94  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:

Field Documentation

◆ $folder

string ilLoggingErrorSettings::$folder = ''
protected

Definition at line 26 of file class.ilLoggingErrorSettings.php.

Referenced by folder(), and setFolder().

◆ $gClientIniFile

ilIniFile ilLoggingErrorSettings::$gClientIniFile = null
protected

Definition at line 29 of file class.ilLoggingErrorSettings.php.

◆ $ilias_ini

ilIniFile ilLoggingErrorSettings::$ilias_ini = null
protected

Definition at line 28 of file class.ilLoggingErrorSettings.php.

◆ $mail

string ilLoggingErrorSettings::$mail = ''
protected

Definition at line 27 of file class.ilLoggingErrorSettings.php.

Referenced by mail(), and setMail().


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