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

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

+ Inheritance diagram for ilSCORMResources:
+ Collaboration diagram for ilSCORMResources:

Public Member Functions

 __construct (int $a_id=0)
 Constructor. More...
 
 getXmlBase ()
 
 setXmlBase (?string $a_xml_base)
 
 read ()
 
 create ()
 
 update ()
 
 delete ()
 
- Public Member Functions inherited from ilSCORMObject
 __construct (int $a_id=0)
 Constructor. More...
 
 getId ()
 
 setId (int $a_id)
 
 getType ()
 
 setType (?string $a_type)
 
 getTitle ()
 
 setTitle (string $a_title)
 
 getSLMId ()
 
 setSLMId (int $a_slm_id)
 
 read ()
 
 create ()
 Create database record for SCORM object. More...
 
 update ()
 Updates database record for SCORM object. More...
 
 delete ()
 

Data Fields

string $xml_base = null
 
- Data Fields inherited from ilSCORMObject
int $id
 
string $title = ""
 
string $type = null
 
int $slm_id
 

Additional Inherited Members

- Static Public Member Functions inherited from ilSCORMObject
static _lookupPresentableItems (int $a_slm_id)
 Count number of presentable SCOs/Assets of SCORM learning module. More...
 
static & _getInstance (int $a_id, int $a_slm_id)
 

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 SCORM Resources Element

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

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

Constructor & Destructor Documentation

◆ __construct()

ilSCORMResources::__construct ( int  $a_id = 0)

Constructor.

Parameters
int$a_idObject ID

Definition at line 36 of file class.ilSCORMResources.php.

References $DIC, $lng, ILIAS\GlobalScreen\Provider\__construct(), ilSCORMObject\setTitle(), and ilSCORMObject\setType().

37  {
38  global $DIC;
39  $lng = $DIC->language();
40 
41  parent::__construct($a_id);
42  $this->setType('srs');
43 
44  $this->setTitle($lng->txt('cont_resources'));
45  }
setType(?string $a_type)
$lng
global $DIC
Definition: feed.php:28
setTitle(string $a_title)
__construct(Container $dic, ilPlugin $plugin)
+ Here is the call graph for this function:

Member Function Documentation

◆ create()

ilSCORMResources::create ( )

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

References $DIC, $ilDB, ilSCORMObject\getId(), and getXmlBase().

73  : void
74  {
75  global $DIC;
76  $ilDB = $DIC->database();
77 
78  parent::create();
79 
80  $ilDB->manipulateF(
81  'INSERT INTO sc_resources (obj_id, xml_base) VALUES (%s, %s)',
82  array('integer', 'text'),
83  array($this->getId(), $this->getXmlBase())
84  );
85  }
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

◆ delete()

ilSCORMResources::delete ( )

Definition at line 102 of file class.ilSCORMResources.php.

References $DIC, $ilDB, and ilSCORMObject\getId().

102  : void
103  {
104  global $DIC;
105  $ilDB = $DIC->database();
106 
107  parent::delete();
108 
109  $ilDB->manipulateF(
110  'DELETE FROM sc_resources WHERE obj_id = %s',
111  array('integer'),
112  array($this->getId())
113  );
114  }
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

◆ getXmlBase()

ilSCORMResources::getXmlBase ( )

Definition at line 47 of file class.ilSCORMResources.php.

References $xml_base.

Referenced by create(), and update().

47  : ?string
48  {
49  return $this->xml_base;
50  }
+ Here is the caller graph for this function:

◆ read()

ilSCORMResources::read ( )

Definition at line 57 of file class.ilSCORMResources.php.

References $DIC, $ilDB, ilSCORMObject\getId(), and setXmlBase().

57  : void
58  {
59  global $DIC;
60  $ilDB = $DIC->database();
61 
62  parent::read();
63 
64  $obj_set = $ilDB->queryF(
65  'SELECT xml_base FROM sc_resources WHERE obj_id = %s',
66  array('integer'),
67  array($this->getId())
68  );
69  $obj_rec = $ilDB->fetchAssoc($obj_set);
70  $this->setXmlBase($obj_rec['xml_base']);
71  }
setXmlBase(?string $a_xml_base)
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

◆ setXmlBase()

ilSCORMResources::setXmlBase ( ?string  $a_xml_base)

Definition at line 52 of file class.ilSCORMResources.php.

Referenced by read().

52  : void
53  {
54  $this->xml_base = $a_xml_base;
55  }
+ Here is the caller graph for this function:

◆ update()

ilSCORMResources::update ( )

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

References $DIC, $ilDB, ilSCORMObject\getId(), and getXmlBase().

87  : void
88  {
89  global $DIC;
90  $ilDB = $DIC->database();
91 
92  parent::update();
93 
94  $ilDB->manipulateF(
95  '
96  UPDATE sc_resources SET xml_base = %s WHERE obj_id = %s',
97  array('text', 'integer'),
98  array($this->getXmlBase() ,$this->getId())
99  );
100  }
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

Field Documentation

◆ $xml_base

string ilSCORMResources::$xml_base = null

Definition at line 30 of file class.ilSCORMResources.php.

Referenced by getXmlBase().


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