ILIAS
Release_3_10_x_branch Revision 61812
◀ ilDoc Overview
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Groups
Pages
class.ilMDSettings.php
Go to the documentation of this file.
1
<?php
2
/*
3
+-----------------------------------------------------------------------------+
4
| ILIAS open source |
5
+-----------------------------------------------------------------------------+
6
| Copyright (c) 1998-2006 ILIAS open source, University of Cologne |
7
| |
8
| This program is free software; you can redistribute it and/or |
9
| modify it under the terms of the GNU General Public License |
10
| as published by the Free Software Foundation; either version 2 |
11
| of the License, or (at your option) any later version. |
12
| |
13
| This program is distributed in the hope that it will be useful, |
14
| but WITHOUT ANY WARRANTY; without even the implied warranty of |
15
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16
| GNU General Public License for more details. |
17
| |
18
| You should have received a copy of the GNU General Public License |
19
| along with this program; if not, write to the Free Software |
20
| Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21
+-----------------------------------------------------------------------------+
22
*/
23
33
class
ilMDSettings
34
{
35
public
static
$instance
= null;
36
37
private
$settings
;
38
private
$copyright_selection_active
=
false
;
39
46
private
function
__construct
()
47
{
48
$this->
read
();
49
}
50
59
public
static
function
_getInstance
()
60
{
61
if
(self::$instance)
62
{
63
return
self::$instance
;
64
}
65
return
self::$instance =
new
ilMDSettings
();
66
}
67
74
public
function
isCopyrightSelectionActive
()
75
{
76
return
$this->copyright_selection_active ?
true
:
false
;
77
}
78
86
public
function
activateCopyrightSelection
($a_status)
87
{
88
$this->copyright_selection_active = $a_status;
89
}
90
97
public
function
save
()
98
{
99
$this->settings->set(
'copyright_selection_active'
,(
int
) $this->
isCopyrightSelectionActive
());
100
}
101
108
private
function
read
()
109
{
110
$this->settings =
new
ilSetting
(
'md_settings'
);
111
112
$this->copyright_selection_active = $this->settings->get(
'copyright_selection_active'
,0);
113
}
114
}
115
116
117
?>
Services
MetaData
classes
class.ilMDSettings.php
Generated on Tue Apr 26 2016 19:00:48 for ILIAS by
1.8.1.2 (using
Doxyfile
)