ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilMDSettings Class Reference
+ Collaboration diagram for ilMDSettings:

Public Member Functions

 isCopyrightSelectionActive ()
 is copyright selection active More...
 
 activateCopyrightSelection ($a_status)
 enable copyright selection More...
 
 setDelimiter ($a_val)
 Set delimiter (used in quick editing screen) More...
 
 getDelimiter ()
 Get delimiter. More...
 
 save ()
 save More...
 

Static Public Member Functions

static _getInstance ()
 get instance More...
 

Static Public Attributes

static $instance = null
 

Private Member Functions

 __construct ()
 Constructor. More...
 
 read ()
 read More...
 

Private Attributes

 $settings
 
 $copyright_selection_active = false
 

Detailed Description

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
Version
$Id$

Definition at line 33 of file class.ilMDSettings.php.

Constructor & Destructor Documentation

◆ __construct()

ilMDSettings::__construct ( )
private

Constructor.

private

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

References read().

47  {
48  $this->read();
49  }
+ Here is the call graph for this function:

Member Function Documentation

◆ _getInstance()

static ilMDSettings::_getInstance ( )
static

get instance

public

Parameters

Definition at line 59 of file class.ilMDSettings.php.

Referenced by ilCopyrightInputGUI\__construct(), ilMDEditorGUI\__construct(), ilMDCopyrightSelectionGUI\__construct(), ilMDUtils\_parseCopyright(), and ilObjMDSettingsGUI\initMDSettings().

60  {
61  if (self::$instance) {
62  return self::$instance;
63  }
64  return self::$instance = new ilMDSettings();
65  }
+ Here is the caller graph for this function:

◆ activateCopyrightSelection()

ilMDSettings::activateCopyrightSelection (   $a_status)

enable copyright selection

public

Parameters
boolstatus

Definition at line 85 of file class.ilMDSettings.php.

86  {
87  $this->copyright_selection_active = $a_status;
88  }

◆ getDelimiter()

ilMDSettings::getDelimiter ( )

Get delimiter.

Returns
string delimiter

Definition at line 105 of file class.ilMDSettings.php.

References $delimiter.

Referenced by save().

106  {
107  if (trim($this->delimiter) == "") {
108  return ",";
109  }
110  return $this->delimiter;
111  }
$delimiter
Definition: showstats.php:16
+ Here is the caller graph for this function:

◆ isCopyrightSelectionActive()

ilMDSettings::isCopyrightSelectionActive ( )

is copyright selection active

public

Definition at line 73 of file class.ilMDSettings.php.

Referenced by save().

74  {
75  return $this->copyright_selection_active ? true : false;
76  }
+ Here is the caller graph for this function:

◆ read()

ilMDSettings::read ( )
private

read

private

Definition at line 131 of file class.ilMDSettings.php.

References settings().

Referenced by __construct().

132  {
133  $this->settings = new ilSetting('md_settings');
134 
135  $this->copyright_selection_active = $this->settings->get('copyright_selection_active', 0);
136  $this->delimiter = $this->settings->get('delimiter', ",");
137  }
settings()
Definition: settings.php:2
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ save()

ilMDSettings::save ( )

save

public

Definition at line 119 of file class.ilMDSettings.php.

References getDelimiter(), isCopyrightSelectionActive(), and settings().

120  {
121  $this->settings->set('copyright_selection_active', (int) $this->isCopyrightSelectionActive());
122  $this->settings->set('delimiter', $this->getDelimiter());
123  }
getDelimiter()
Get delimiter.
isCopyrightSelectionActive()
is copyright selection active
settings()
Definition: settings.php:2
+ Here is the call graph for this function:

◆ setDelimiter()

ilMDSettings::setDelimiter (   $a_val)

Set delimiter (used in quick editing screen)

Parameters
stringdelimiter

Definition at line 95 of file class.ilMDSettings.php.

96  {
97  $this->delimiter = $a_val;
98  }

Field Documentation

◆ $copyright_selection_active

ilMDSettings::$copyright_selection_active = false
private

Definition at line 38 of file class.ilMDSettings.php.

◆ $instance

ilMDSettings::$instance = null
static

Definition at line 35 of file class.ilMDSettings.php.

◆ $settings

ilMDSettings::$settings
private

Definition at line 37 of file class.ilMDSettings.php.


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