ILIAS
eassessment Revision 61809
◀ ilDoc Overview
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
Examples
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Groups
Pages
class.ilSCORMResources.php
Go to the documentation of this file.
1
<?php
2
/*
3
+-----------------------------------------------------------------------------+
4
| ILIAS open source |
5
+-----------------------------------------------------------------------------+
6
| Copyright (c) 1998-2001 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
24
require_once(
"./Modules/ScormAicc/classes/SCORM/class.ilSCORMObject.php"
);
25
34
class
ilSCORMResources
extends
ilSCORMObject
35
{
36
var
$xml_base
;
37
38
45
function
ilSCORMResources
($a_id = 0)
46
{
47
global
$lng
;
48
49
parent::ilSCORMObject
($a_id);
50
$this->
setType
(
'srs'
);
51
52
$this->
setTitle
($lng->txt(
'cont_resources'
));
53
}
54
55
function
getXmlBase
()
56
{
57
return
$this->xml_base
;
58
}
59
60
function
setXmlBase
($a_xml_base)
61
{
62
$this->xml_base = $a_xml_base;
63
}
64
65
function
read
()
66
{
67
global
$ilDB
;
68
69
parent::read
();
70
71
$obj_set = $ilDB->queryF(
72
'SELECT xml_base FROM sc_resources WHERE obj_id = %s'
,
73
array(
'integer'
),
74
array($this->
getId
())
75
);
76
$obj_rec = $ilDB->fetchAssoc($obj_set);
77
$this->
setXmlBase
($obj_rec[
'xml_base'
]);
78
}
79
80
function
create
()
81
{
82
global
$ilDB
;
83
84
parent::create
();
85
86
$ilDB->manipulateF(
87
'INSERT INTO sc_resources (obj_id, xml_base) VALUES (%s, %s)'
,
88
array(
'integer'
,
'text'
),
89
array($this->
getId
(), $this->
getXmlBase
())
90
);
91
}
92
93
function
update
()
94
{
95
global
$ilDB
;
96
97
parent::update
();
98
99
$ilDB->manipulateF(
'
100
UPDATE sc_resources SET xml_base = %s WHERE obj_id = %s'
,
101
array(
'text'
,
'integer'
),
102
array($this->
getXmlBase
() ,$this->
getId
())
103
);
104
}
105
106
function
delete
()
107
{
108
global
$ilDB
;
109
110
parent::delete
();
111
112
$ilDB->manipulateF(
113
'DELETE FROM sc_resources WHERE obj_id = %s'
,
114
array(
'integer'
),
115
array($this->
getId
())
116
);
117
}
118
}
119
?>
Modules
ScormAicc
classes
SCORM
class.ilSCORMResources.php
Generated on Mon Apr 25 2016 19:01:13 for ILIAS by
1.8.1.2 (using
Doxyfile
)