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

Public Member Functions

getTypicalAgeRangeIds ()
 
getTypicalAgeRange ($a_typical_age_range_id)
 
addTypicalAgeRange ()
 
getDescriptionIds ()
 
getDescription ($a_description_id)
 
addDescription ()
 
getLanguageIds ()
 
getLanguage ($a_language_id)
 
addLanguage ()
 
 setInteractivityType ($a_iat)
 
 getInteractivityType ()
 
 setLearningResourceType ($a_lrt)
 
 getLearningResourceType ()
 
 setInteractivityLevel ($a_iat)
 
 getInteractivityLevel ()
 
 setSemanticDensity ($a_sd)
 
 getSemanticDensity ()
 
 setIntendedEndUserRole ($a_ieur)
 
 getIntendedEndUserRole ()
 
 setContext ($a_context)
 
 getContext ()
 
 setDifficulty ($a_difficulty)
 
 getDifficulty ()
 
 setPhysicalTypicalLearningTime ($months, $days, $hours, $minutes, $seconds)
 
 setTypicalLearningTime ($a_tlt)
 
 getTypicalLearningTime ()
 
 getTypicalLearningTimeSeconds ()
 
 save ()
 
 update ()
 
 delete ()
 
 __getFields ()
 
 read ()
 
 toXML (&$writer)
 
getTypicalAgeRangeIds ()
 
getTypicalAgeRange ($a_typical_age_range_id)
 
addTypicalAgeRange ()
 
getDescriptionIds ()
 
getDescription ($a_description_id)
 
addDescription ()
 
getLanguageIds ()
 
getLanguage ($a_language_id)
 
addLanguage ()
 
 setInteractivityType ($a_iat)
 
 getInteractivityType ()
 
 setLearningResourceType ($a_lrt)
 
 getLearningResourceType ()
 
 setInteractivityLevel ($a_iat)
 
 getInteractivityLevel ()
 
 setSemanticDensity ($a_sd)
 
 getSemanticDensity ()
 
 setIntendedEndUserRole ($a_ieur)
 
 getIntendedEndUserRole ()
 
 setContext ($a_context)
 
 getContext ()
 
 setDifficulty ($a_difficulty)
 
 getDifficulty ()
 
 setTypicalLearningTime ($a_tlt)
 
 getTypicalLearningTime ()
 
 save ()
 
 update ()
 
 delete ()
 
 __getFields ()
 
 read ()
 
 toXML (&$writer)
 
 _getId ($a_rbac_id, $a_obj_id)
 
- Public Member Functions inherited from ilMDBase
 __construct ( $a_rbac_id=0, $a_obj_id=0, $a_type=0)
 
 setRBACId ($a_id)
 
 getRBACId ()
 
 setObjId ($a_id)
 
 getObjId ()
 
 setObjType ($a_type)
 
 getObjType ()
 
 setMetaId ($a_meta_id, $a_read_data=true)
 
 getMetaId ()
 
 setParentType ($a_parent_type)
 
 getParentType ()
 
 setParentId ($a_id)
 
 getParentId ()
 
 setExportMode ($a_export_mode=true)
 
 getExportMode ()
 
 validate ()
 
 update ()
 
 save ()
 
 delete ()
 
 toXML (&$writer)
 
 __construct ( $a_rbac_id=0, $a_obj_id=0, $a_type=0)
 
 setRBACId ($a_id)
 
 getRBACId ()
 
 setObjId ($a_id)
 
 getObjId ()
 
 setObjType ($a_type)
 
 getObjType ()
 
 setMetaId ($a_meta_id, $a_read_data=true)
 
 getMetaId ()
 
 setParentType ($a_parent_type)
 
 getParentType ()
 
 setParentId ($a_id)
 
 getParentId ()
 
 validate ()
 
 update ()
 
 save ()
 
 delete ()
 
 toXML (&$writer)
 

Static Public Member Functions

static _getId ($a_rbac_id, $a_obj_id)
 
static _getTypicalLearningTimeSeconds ($a_rbac_id, $a_obj_id=0)
 

Additional Inherited Members

- Data Fields inherited from ilMDBase
 $rbac_id
 
 $obj_id
 
 $obj_type
 
 $export_mode = false
 
- Protected Attributes inherited from ilMDBase
 $log
 

Detailed Description

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

Member Function Documentation

◆ __getFields() [1/2]

ilMDEducational::__getFields ( )

Definition at line 333 of file class.ilMDEducational.php.

References array, getContext(), getDifficulty(), getIntendedEndUserRole(), getInteractivityLevel(), getInteractivityType(), getLearningResourceType(), ilMDBase\getObjId(), ilMDBase\getObjType(), ilMDBase\getRBACId(), getSemanticDensity(), getTypicalLearningTime(), and ilUtil\prepareDBString().

334  {
335  return array('rbac_id' => $this->getRBACId(),
336  'obj_id' => $this->getObjId(),
337  'obj_type' => ilUtil::prepareDBString($this->getObjType()),
338  'interactivity_type' => ilUtil::prepareDBString($this->getInteractivityType()),
339  'learning_resource_type' => ilUtil::prepareDBString($this->getLearningResourceType()),
340  'interactivity_level' => ilUtil::prepareDBString($this->getInteractivityLevel()),
341  'semantic_density' => ilUtil::prepareDBString($this->getSemanticDensity()),
342  'intended_end_user_role' => ilUtil::prepareDBString($this->getIntendedEndUserRole()),
343  'context' => ilUtil::prepareDBString($this->getContext()),
344  'difficulty' => ilUtil::prepareDBString($this->getDifficulty()),
345  'typical_learning_time' => ilUtil::prepareDBString($this->getTypicalLearningTime()));
346  }
Create styles array
The data for the language used.
static prepareDBString($a_str)
prepare a string for db writing (insert/update)
+ Here is the call graph for this function:

◆ __getFields() [2/2]

ilMDEducational::__getFields ( )

Definition at line 369 of file class.ilMDEducational.php.

References array, getContext(), getDifficulty(), getIntendedEndUserRole(), getInteractivityLevel(), getInteractivityType(), getLearningResourceType(), ilMDBase\getObjId(), ilMDBase\getObjType(), ilMDBase\getRBACId(), getSemanticDensity(), and getTypicalLearningTime().

Referenced by save().

370  {
371  return array('rbac_id' => array('integer',$this->getRBACId()),
372  'obj_id' => array('integer',$this->getObjId()),
373  'obj_type' => array('text',$this->getObjType()),
374  'interactivity_type' => array('text',$this->getInteractivityType()),
375  'learning_resource_type' => array('text',$this->getLearningResourceType()),
376  'interactivity_level' => array('text',$this->getInteractivityLevel()),
377  'semantic_density' => array('text',$this->getSemanticDensity()),
378  'intended_end_user_role' => array('text',$this->getIntendedEndUserRole()),
379  'context' => array('text',$this->getContext()),
380  'difficulty' => array('text',$this->getDifficulty()),
381  'typical_learning_time' => array('text',$this->getTypicalLearningTime()));
382  }
Create styles array
The data for the language used.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _getId() [1/2]

ilMDEducational::_getId (   $a_rbac_id,
  $a_obj_id 
)

Definition at line 415 of file class.ilMDEducational.php.

References $ilDB, $query, $res, $row, and ilDBConstants\FETCHMODE_OBJECT.

416  {
417  global $ilDB;
418 
419  $query = "SELECT meta_educational_id FROM il_meta_educational " .
420  "WHERE rbac_id = " . $ilDB->quote($a_rbac_id) . " " .
421  "AND obj_id = " . $ilDB->quote($a_obj_id);
422 
423  $res = $ilDB->query($query);
424  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
425  return $row->meta_educational_id;
426  }
427  return false;
428  }
foreach($_POST as $key=> $value) $res
$query
global $ilDB

◆ _getId() [2/2]

static ilMDEducational::_getId (   $a_rbac_id,
  $a_obj_id 
)
static

Definition at line 476 of file class.ilMDEducational.php.

References $ilDB, $query, $res, $row, and ilDBConstants\FETCHMODE_OBJECT.

Referenced by ilMD\getEducational().

477  {
478  global $ilDB;
479 
480  $query = "SELECT meta_educational_id FROM il_meta_educational " .
481  "WHERE rbac_id = " . $ilDB->quote($a_rbac_id, 'integer') . " " .
482  "AND obj_id = " . $ilDB->quote($a_obj_id, 'integer');
483 
484  $res = $ilDB->query($query);
485  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
486  return $row->meta_educational_id;
487  }
488  return false;
489  }
foreach($_POST as $key=> $value) $res
$query
global $ilDB
+ Here is the caller graph for this function:

◆ _getTypicalLearningTimeSeconds()

static ilMDEducational::_getTypicalLearningTimeSeconds (   $a_rbac_id,
  $a_obj_id = 0 
)
static

Definition at line 491 of file class.ilMDEducational.php.

References $ilDB, $query, $res, $row, ilMDUtils\_LOMDurationToArray(), and ilDBConstants\FETCHMODE_OBJECT.

Referenced by ilLearningProgressBaseGUI\__readItemStatusInfo(), ilCourseContentGUI\__renderItem(), ilCourseContentGUI\__renderUserItem(), ilLearningProgressBaseGUI\__showObjectDetails(), ilLPStatusCollectionTLT\_getStatusInfo(), ilLPStatusTypicalLearningTime\_getStatusInfo(), ilLPStatus\_getTypicalLearningTime(), ilLPStatusTypicalLearningTime\determinePercentage(), ilCourseContentGUI\editTimings(), and ilLPCollectionOfLMChapters\getPossibleItems().

492  {
493  global $ilDB;
494 
495  $a_obj_id = $a_obj_id ? $a_obj_id : $a_rbac_id;
496 
497  $query = "SELECT typical_learning_time FROM il_meta_educational " .
498  "WHERE rbac_id = " . $ilDB->quote($a_rbac_id, 'integer') . " " .
499  "AND obj_id = " . $ilDB->quote($a_obj_id, 'integer');
500  $res = $ilDB->query($query);
501  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
502  include_once './Services/MetaData/classes/class.ilMDUtils.php';
503 
504  $time_arr = ilMDUtils::_LOMDurationToArray($row->typical_learning_time);
505 
506  return 60 * 60 * 24 * 30 * $time_arr[0] +
507  60 * 60 * 24 * $time_arr[1] +
508  60 * 60 * $time_arr[2] +
509  60 * $time_arr[3] +
510  $time_arr[4];
511  }
512  return 0;
513  }
static _LOMDurationToArray($a_string)
LOM datatype duration is a string like P2M4DT7H18M2S (2 months 4 days 7 hours 18 minutes 2 seconds) T...
foreach($_POST as $key=> $value) $res
$query
global $ilDB
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addDescription() [1/2]

& ilMDEducational::addDescription ( )

Definition at line 82 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

83  {
84  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDDescription.php';
85 
86  $des = new ilMDDescription($this->getRBACId(), $this->getObjId(), $this->getObjType());
87  $des->setParentId($this->getMetaId());
88  $des->setParentType('meta_educational');
89 
90  return $des;
91  }
+ Here is the call graph for this function:

◆ addDescription() [2/2]

& ilMDEducational::addDescription ( )

Definition at line 82 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

83  {
84  include_once 'Services/MetaData/classes/class.ilMDDescription.php';
85 
86  $des = new ilMDDescription($this->getRBACId(), $this->getObjId(), $this->getObjType());
87  $des->setParentId($this->getMetaId());
88  $des->setParentType('meta_educational');
89 
90  return $des;
91  }
+ Here is the call graph for this function:

◆ addLanguage() [1/2]

& ilMDEducational::addLanguage ( )

Definition at line 110 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

111  {
112  include_once 'Services/MetaData/classes/class.ilMDLanguage.php';
113 
114  $lan = new ilMDLanguage($this->getRBACId(), $this->getObjId(), $this->getObjType());
115  $lan->setParentId($this->getMetaId());
116  $lan->setParentType('meta_educational');
117 
118  return $lan;
119  }
+ Here is the call graph for this function:

◆ addLanguage() [2/2]

& ilMDEducational::addLanguage ( )

Definition at line 110 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

111  {
112  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLanguage.php';
113 
114  $lan = new ilMDLanguage($this->getRBACId(), $this->getObjId(), $this->getObjType());
115  $lan->setParentId($this->getMetaId());
116  $lan->setParentType('meta_educational');
117 
118  return $lan;
119  }
+ Here is the call graph for this function:

◆ addTypicalAgeRange() [1/2]

& ilMDEducational::addTypicalAgeRange ( )

Definition at line 54 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

55  {
56  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDTypicalAgeRange.php';
57 
58  $typ = new ilMDTypicalAgeRange($this->getRBACId(), $this->getObjId(), $this->getObjType());
59  $typ->setParentId($this->getMetaId());
60  $typ->setParentType('meta_educational');
61 
62  return $typ;
63  }
+ Here is the call graph for this function:

◆ addTypicalAgeRange() [2/2]

& ilMDEducational::addTypicalAgeRange ( )

Definition at line 54 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

55  {
56  include_once 'Services/MetaData/classes/class.ilMDTypicalAgeRange.php';
57 
58  $typ = new ilMDTypicalAgeRange($this->getRBACId(), $this->getObjId(), $this->getObjType());
59  $typ->setParentId($this->getMetaId());
60  $typ->setParentType('meta_educational');
61 
62  return $typ;
63  }
+ Here is the call graph for this function:

◆ delete() [1/2]

ilMDEducational::delete ( )

Definition at line 303 of file class.ilMDEducational.php.

References $id, $ilDB, $query, getDescription(), getDescriptionIds(), getLanguage(), getLanguageIds(), ilMDBase\getMetaId(), getTypicalAgeRange(), and getTypicalAgeRangeIds().

304  {
305  global $ilDB;
306 
307  if ($this->getMetaId()) {
308  $query = "DELETE FROM il_meta_educational " .
309  "WHERE meta_educational_id = " . $ilDB->quote($this->getMetaId());
310 
311  $this->db->query($query);
312 
313  foreach ($this->getTypicalAgeRangeIds() as $id) {
314  $typ =&$this->getTypicalAgeRange($id);
315  $typ->delete();
316  }
317  foreach ($this->getDescriptionIds() as $id) {
318  $des =&$this->getDescription($id);
319  $des->delete();
320  }
321  foreach ($this->getLanguageIds() as $id) {
322  $lan =&$this->getLanguage($id);
323  $lan->delete();
324  }
325 
326 
327  return true;
328  }
329  return false;
330  }
& getLanguage($a_language_id)
& getDescription($a_description_id)
if(!array_key_exists('StateId', $_REQUEST)) $id
& getTypicalAgeRange($a_typical_age_range_id)
$query
global $ilDB
+ Here is the call graph for this function:

◆ delete() [2/2]

ilMDEducational::delete ( )

Definition at line 340 of file class.ilMDEducational.php.

References $id, $ilDB, $query, $res, getDescription(), getDescriptionIds(), getLanguage(), getLanguageIds(), ilMDBase\getMetaId(), getTypicalAgeRange(), and getTypicalAgeRangeIds().

341  {
342  global $ilDB;
343 
344  if ($this->getMetaId()) {
345  $query = "DELETE FROM il_meta_educational " .
346  "WHERE meta_educational_id = " . $ilDB->quote($this->getMetaId());
347  $res = $ilDB->manipulate($query);
348 
349  foreach ($this->getTypicalAgeRangeIds() as $id) {
350  $typ = $this->getTypicalAgeRange($id);
351  $typ->delete();
352  }
353  foreach ($this->getDescriptionIds() as $id) {
354  $des = $this->getDescription($id);
355  $des->delete();
356  }
357  foreach ($this->getLanguageIds() as $id) {
358  $lan = $this->getLanguage($id);
359  $lan->delete();
360  }
361 
362 
363  return true;
364  }
365  return false;
366  }
& getLanguage($a_language_id)
& getDescription($a_description_id)
if(!array_key_exists('StateId', $_REQUEST)) $id
& getTypicalAgeRange($a_typical_age_range_id)
foreach($_POST as $key=> $value) $res
$query
global $ilDB
+ Here is the call graph for this function:

◆ getContext() [1/2]

ilMDEducational::getContext ( )

Definition at line 238 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

239  {
240  return $this->context;
241  }
+ Here is the caller graph for this function:

◆ getContext() [2/2]

ilMDEducational::getContext ( )

Definition at line 238 of file class.ilMDEducational.php.

239  {
240  return $this->context;
241  }

◆ getDescription() [1/2]

& ilMDEducational::getDescription (   $a_description_id)

Definition at line 70 of file class.ilMDEducational.php.

Referenced by delete(), and toXML().

71  {
72  include_once 'Services/MetaData/classes/class.ilMDDescription.php';
73 
74  if (!$a_description_id) {
75  return false;
76  }
77  $des = new ilMDDescription();
78  $des->setMetaId($a_description_id);
79 
80  return $des;
81  }
+ Here is the caller graph for this function:

◆ getDescription() [2/2]

& ilMDEducational::getDescription (   $a_description_id)

Definition at line 70 of file class.ilMDEducational.php.

71  {
72  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDDescription.php';
73 
74  if (!$a_description_id) {
75  return false;
76  }
77  $des = new ilMDDescription();
78  $des->setMetaId($a_description_id);
79 
80  return $des;
81  }

◆ getDescriptionIds() [1/2]

& ilMDEducational::getDescriptionIds ( )

Definition at line 64 of file class.ilMDEducational.php.

References ilMDDescription\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

65  {
66  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDDescription.php';
67 
68  return ilMDDescription::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
69  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:

◆ getDescriptionIds() [2/2]

& ilMDEducational::getDescriptionIds ( )

Definition at line 64 of file class.ilMDEducational.php.

References ilMDDescription\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

65  {
66  include_once 'Services/MetaData/classes/class.ilMDDescription.php';
67 
68  return ilMDDescription::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
69  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getDifficulty() [1/2]

ilMDEducational::getDifficulty ( )

Definition at line 257 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

258  {
259  return $this->difficulty;
260  }
+ Here is the caller graph for this function:

◆ getDifficulty() [2/2]

ilMDEducational::getDifficulty ( )

Definition at line 257 of file class.ilMDEducational.php.

258  {
259  return $this->difficulty;
260  }

◆ getIntendedEndUserRole() [1/2]

ilMDEducational::getIntendedEndUserRole ( )

Definition at line 220 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

221  {
222  return $this->intended_end_user_role;
223  }
+ Here is the caller graph for this function:

◆ getIntendedEndUserRole() [2/2]

ilMDEducational::getIntendedEndUserRole ( )

Definition at line 220 of file class.ilMDEducational.php.

221  {
222  return $this->intended_end_user_role;
223  }

◆ getInteractivityLevel() [1/2]

ilMDEducational::getInteractivityLevel ( )

Definition at line 183 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

184  {
185  return $this->interactivity_level;
186  }
+ Here is the caller graph for this function:

◆ getInteractivityLevel() [2/2]

ilMDEducational::getInteractivityLevel ( )

Definition at line 183 of file class.ilMDEducational.php.

184  {
185  return $this->interactivity_level;
186  }

◆ getInteractivityType() [1/2]

ilMDEducational::getInteractivityType ( )

Definition at line 135 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

136  {
137  return $this->interactivity_type;
138  }
+ Here is the caller graph for this function:

◆ getInteractivityType() [2/2]

ilMDEducational::getInteractivityType ( )

Definition at line 135 of file class.ilMDEducational.php.

136  {
137  return $this->interactivity_type;
138  }

◆ getLanguage() [1/2]

& ilMDEducational::getLanguage (   $a_language_id)

Definition at line 98 of file class.ilMDEducational.php.

Referenced by delete(), and toXML().

99  {
100  include_once 'Services/MetaData/classes/class.ilMDLanguage.php';
101 
102  if (!$a_language_id) {
103  return false;
104  }
105  $lan = new ilMDLanguage();
106  $lan->setMetaId($a_language_id);
107 
108  return $lan;
109  }
+ Here is the caller graph for this function:

◆ getLanguage() [2/2]

& ilMDEducational::getLanguage (   $a_language_id)

Definition at line 98 of file class.ilMDEducational.php.

99  {
100  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLanguage.php';
101 
102  if (!$a_language_id) {
103  return false;
104  }
105  $lan = new ilMDLanguage();
106  $lan->setMetaId($a_language_id);
107 
108  return $lan;
109  }

◆ getLanguageIds() [1/2]

& ilMDEducational::getLanguageIds ( )

Definition at line 92 of file class.ilMDEducational.php.

References ilMDLanguage\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

93  {
94  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLanguage.php';
95 
96  return ilMDLanguage::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
97  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:

◆ getLanguageIds() [2/2]

& ilMDEducational::getLanguageIds ( )

Definition at line 92 of file class.ilMDEducational.php.

References ilMDLanguage\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

93  {
94  include_once 'Services/MetaData/classes/class.ilMDLanguage.php';
95 
96  return ilMDLanguage::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
97  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getLearningResourceType() [1/2]

ilMDEducational::getLearningResourceType ( )

Definition at line 164 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

165  {
166  return $this->learning_resource_type;
167  }
+ Here is the caller graph for this function:

◆ getLearningResourceType() [2/2]

ilMDEducational::getLearningResourceType ( )

Definition at line 164 of file class.ilMDEducational.php.

165  {
166  return $this->learning_resource_type;
167  }

◆ getSemanticDensity() [1/2]

ilMDEducational::getSemanticDensity ( )

Definition at line 202 of file class.ilMDEducational.php.

Referenced by __getFields(), and toXML().

203  {
204  return $this->semantic_density;
205  }
+ Here is the caller graph for this function:

◆ getSemanticDensity() [2/2]

ilMDEducational::getSemanticDensity ( )

Definition at line 202 of file class.ilMDEducational.php.

203  {
204  return $this->semantic_density;
205  }

◆ getTypicalAgeRange() [1/2]

& ilMDEducational::getTypicalAgeRange (   $a_typical_age_range_id)

Definition at line 42 of file class.ilMDEducational.php.

43  {
44  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDTypicalAgeRange.php';
45 
46  if (!$a_typical_age_range_id) {
47  return false;
48  }
49  $typ = new ilMDTypicalAgeRange();
50  $typ->setMetaId($a_typical_age_range_id);
51 
52  return $typ;
53  }

◆ getTypicalAgeRange() [2/2]

& ilMDEducational::getTypicalAgeRange (   $a_typical_age_range_id)

Definition at line 42 of file class.ilMDEducational.php.

Referenced by delete(), and toXML().

43  {
44  include_once 'Services/MetaData/classes/class.ilMDTypicalAgeRange.php';
45 
46  if (!$a_typical_age_range_id) {
47  return false;
48  }
49  $typ = new ilMDTypicalAgeRange();
50  $typ->setMetaId($a_typical_age_range_id);
51 
52  return $typ;
53  }
+ Here is the caller graph for this function:

◆ getTypicalAgeRangeIds() [1/2]

& ilMDEducational::getTypicalAgeRangeIds ( )

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

References ilMDTypicalAgeRange\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

37  {
38  include_once 'Services/MetaData/classes/class.ilMDTypicalAgeRange.php';
39 
40  return ilMDTypicalAgeRange::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
41  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTypicalAgeRangeIds() [2/2]

& ilMDEducational::getTypicalAgeRangeIds ( )

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

References ilMDTypicalAgeRange\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

37  {
38  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDTypicalAgeRange.php';
39 
40  return ilMDTypicalAgeRange::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_educational');
41  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:

◆ getTypicalLearningTime() [1/2]

ilMDEducational::getTypicalLearningTime ( )

Definition at line 265 of file class.ilMDEducational.php.

266  {
267  return $this->typical_learning_time;
268  }

◆ getTypicalLearningTime() [2/2]

ilMDEducational::getTypicalLearningTime ( )

Definition at line 296 of file class.ilMDEducational.php.

Referenced by __getFields(), getTypicalLearningTimeSeconds(), and toXML().

297  {
298  return $this->typical_learning_time;
299  }
+ Here is the caller graph for this function:

◆ getTypicalLearningTimeSeconds()

ilMDEducational::getTypicalLearningTimeSeconds ( )

Definition at line 301 of file class.ilMDEducational.php.

References ilMDUtils\_LOMDurationToArray(), and getTypicalLearningTime().

302  {
303  include_once './Services/MetaData/classes/class.ilMDUtils.php';
304 
306 
307  return 60 * 60 * 24 * 30 * $time_arr[0] + 60 * 60 * 24 * $time_arr[1] + 60 * 60 * $time_arr[2] + 60 * $time_arr[3] + $time_arr[4];
308  }
static _LOMDurationToArray($a_string)
LOM datatype duration is a string like P2M4DT7H18M2S (2 months 4 days 7 hours 18 minutes 2 seconds) T...
+ Here is the call graph for this function:

◆ read() [1/2]

ilMDEducational::read ( )

Definition at line 348 of file class.ilMDEducational.php.

References $ilDB, $query, $res, $row, ilDBConstants\FETCHMODE_OBJECT, ilMDBase\getMetaId(), setContext(), setDifficulty(), setIntendedEndUserRole(), setInteractivityLevel(), setInteractivityType(), setLearningResourceType(), ilMDBase\setObjId(), ilMDBase\setObjType(), ilMDBase\setRBACId(), setSemanticDensity(), setTypicalLearningTime(), and ilUtil\stripSlashes().

349  {
350  global $ilDB;
351 
352  if ($this->getMetaId()) {
353  $query = "SELECT * FROM il_meta_educational " .
354  "WHERE meta_educational_id = " . $ilDB->quote($this->getMetaId());
355 
356 
357  $res = $this->db->query($query);
358  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
359  $this->setRBACId($row->rbac_id);
360  $this->setObjId($row->obj_id);
361  $this->setObjType($row->obj_type);
362  $this->setInteractivityType(ilUtil::stripSlashes($row->interactivity_type));
363  $this->setLearningResourceType(ilUtil::stripSlashes($row->learning_resource_type));
364  $this->setInteractivityLevel(ilUtil::stripSlashes($row->interactivity_level));
365  $this->setSemanticDensity(ilUtil::stripSlashes($row->semantic_density));
366  $this->setIntendedEndUserRole(ilUtil::stripSlashes($row->intended_end_user_role));
367  $this->setContext(ilUtil::stripSlashes($row->context));
368  $this->setDifficulty(ilUtil::stripSlashes($row->difficulty));
369  $this->setTypicalLearningTime(ilUtil::stripSlashes($row->typical_learning_time));
370  }
371  return true;
372  }
373  return false;
374  }
setObjType($a_type)
setDifficulty($a_difficulty)
foreach($_POST as $key=> $value) $res
setObjId($a_id)
setRBACId($a_id)
$query
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
global $ilDB
+ Here is the call graph for this function:

◆ read() [2/2]

ilMDEducational::read ( )

Definition at line 384 of file class.ilMDEducational.php.

References $ilDB, $query, $res, $row, ilDBConstants\FETCHMODE_OBJECT, ilMDBase\getMetaId(), setContext(), setDifficulty(), setIntendedEndUserRole(), setInteractivityLevel(), setInteractivityType(), setLearningResourceType(), ilMDBase\setObjId(), ilMDBase\setObjType(), ilMDBase\setRBACId(), setSemanticDensity(), and setTypicalLearningTime().

385  {
386  global $ilDB;
387 
388  if ($this->getMetaId()) {
389  $query = "SELECT * FROM il_meta_educational " .
390  "WHERE meta_educational_id = " . $ilDB->quote($this->getMetaId(), 'integer');
391 
392 
393  $res = $this->db->query($query);
394  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
395  $this->setRBACId($row->rbac_id);
396  $this->setObjId($row->obj_id);
397  $this->setObjType($row->obj_type);
398  $this->setInteractivityType($row->interactivity_type);
399  $this->setLearningResourceType($row->learning_resource_type);
400  $this->setInteractivityLevel($row->interactivity_level);
401  $this->setSemanticDensity($row->semantic_density);
402  $this->setIntendedEndUserRole($row->intended_end_user_role);
403  $this->setContext($row->context);
404  $this->setDifficulty($row->difficulty);
405  $this->setTypicalLearningTime($row->typical_learning_time);
406  }
407  return true;
408  }
409  return false;
410  }
setObjType($a_type)
setDifficulty($a_difficulty)
foreach($_POST as $key=> $value) $res
setObjId($a_id)
setRBACId($a_id)
$query
global $ilDB
+ Here is the call graph for this function:

◆ save() [1/2]

ilMDEducational::save ( )

Definition at line 271 of file class.ilMDEducational.php.

References ilMDBase\getMetaId(), ilDBConstants\MDB2_AUTOQUERY_INSERT, and ilMDBase\setMetaId().

272  {
273  if ($this->db->autoExecute(
274  'il_meta_educational',
275  $this->__getFields(),
277  )) {
278  $this->setMetaId($this->db->getLastInsertId());
279 
280  return $this->getMetaId();
281  }
282 
283  return false;
284  }
setMetaId($a_meta_id, $a_read_data=true)
+ Here is the call graph for this function:

◆ save() [2/2]

ilMDEducational::save ( )

Definition at line 310 of file class.ilMDEducational.php.

References $ilDB, __getFields(), array, ilMDBase\getMetaId(), and ilMDBase\setMetaId().

311  {
312  global $ilDB;
313 
314  $fields = $this->__getFields();
315  $fields['meta_educational_id'] = array('integer',$next_id = $ilDB->nextId('il_meta_educational'));
316 
317  if ($this->db->insert('il_meta_educational', $fields)) {
318  $this->setMetaId($next_id);
319  return $this->getMetaId();
320  }
321  return false;
322  }
setMetaId($a_meta_id, $a_read_data=true)
Create styles array
The data for the language used.
global $ilDB
+ Here is the call graph for this function:

◆ setContext() [1/2]

ilMDEducational::setContext (   $a_context)

Definition at line 224 of file class.ilMDEducational.php.

225  {
226  switch ($a_context) {
227  case 'School':
228  case 'HigherEducation':
229  case 'Training':
230  case 'Other':
231  $this->context = $a_context;
232  return true;
233 
234  default:
235  return false;
236  }
237  }

◆ setContext() [2/2]

ilMDEducational::setContext (   $a_context)

Definition at line 224 of file class.ilMDEducational.php.

Referenced by read().

225  {
226  switch ($a_context) {
227  case 'School':
228  case 'HigherEducation':
229  case 'Training':
230  case 'Other':
231  $this->context = $a_context;
232  return true;
233 
234  default:
235  return false;
236  }
237  }
+ Here is the caller graph for this function:

◆ setDifficulty() [1/2]

ilMDEducational::setDifficulty (   $a_difficulty)

Definition at line 242 of file class.ilMDEducational.php.

243  {
244  switch ($a_difficulty) {
245  case 'VeryEasy':
246  case 'Easy':
247  case 'Medium':
248  case 'Difficult':
249  case 'VeryDifficult':
250  $this->difficulty = $a_difficulty;
251  return true;
252 
253  default:
254  return false;
255  }
256  }

◆ setDifficulty() [2/2]

ilMDEducational::setDifficulty (   $a_difficulty)

Definition at line 242 of file class.ilMDEducational.php.

Referenced by read().

243  {
244  switch ($a_difficulty) {
245  case 'VeryEasy':
246  case 'Easy':
247  case 'Medium':
248  case 'Difficult':
249  case 'VeryDifficult':
250  $this->difficulty = $a_difficulty;
251  return true;
252 
253  default:
254  return false;
255  }
256  }
+ Here is the caller graph for this function:

◆ setIntendedEndUserRole() [1/2]

ilMDEducational::setIntendedEndUserRole (   $a_ieur)

Definition at line 206 of file class.ilMDEducational.php.

207  {
208  switch ($a_ieur) {
209  case 'Teacher':
210  case 'Author':
211  case 'Learner':
212  case 'Manager':
213  $this->intended_end_user_role = $a_ieur;
214  return true;
215 
216  default:
217  return false;
218  }
219  }

◆ setIntendedEndUserRole() [2/2]

ilMDEducational::setIntendedEndUserRole (   $a_ieur)

Definition at line 206 of file class.ilMDEducational.php.

Referenced by read().

207  {
208  switch ($a_ieur) {
209  case 'Teacher':
210  case 'Author':
211  case 'Learner':
212  case 'Manager':
213  $this->intended_end_user_role = $a_ieur;
214  return true;
215 
216  default:
217  return false;
218  }
219  }
+ Here is the caller graph for this function:

◆ setInteractivityLevel() [1/2]

ilMDEducational::setInteractivityLevel (   $a_iat)

Definition at line 168 of file class.ilMDEducational.php.

Referenced by read().

169  {
170  switch ($a_iat) {
171  case 'VeryLow':
172  case 'Low':
173  case 'Medium':
174  case 'High':
175  case 'VeryHigh':
176  $this->interactivity_level = $a_iat;
177  return true;
178 
179  default:
180  return false;
181  }
182  }
+ Here is the caller graph for this function:

◆ setInteractivityLevel() [2/2]

ilMDEducational::setInteractivityLevel (   $a_iat)

Definition at line 168 of file class.ilMDEducational.php.

169  {
170  switch ($a_iat) {
171  case 'VeryLow':
172  case 'Low':
173  case 'Medium':
174  case 'High':
175  case 'VeryHigh':
176  $this->interactivity_level = $a_iat;
177  return true;
178 
179  default:
180  return false;
181  }
182  }

◆ setInteractivityType() [1/2]

ilMDEducational::setInteractivityType (   $a_iat)

Definition at line 122 of file class.ilMDEducational.php.

Referenced by read().

123  {
124  switch ($a_iat) {
125  case 'Active':
126  case 'Expositive':
127  case 'Mixed':
128  $this->interactivity_type = $a_iat;
129  return true;
130 
131  default:
132  return false;
133  }
134  }
+ Here is the caller graph for this function:

◆ setInteractivityType() [2/2]

ilMDEducational::setInteractivityType (   $a_iat)

Definition at line 122 of file class.ilMDEducational.php.

123  {
124  switch ($a_iat) {
125  case 'Active':
126  case 'Expositive':
127  case 'Mixed':
128  $this->interactivity_type = $a_iat;
129  return true;
130 
131  default:
132  return false;
133  }
134  }

◆ setLearningResourceType() [1/2]

ilMDEducational::setLearningResourceType (   $a_lrt)

Definition at line 139 of file class.ilMDEducational.php.

Referenced by read().

140  {
141  switch ($a_lrt) {
142  case 'Exercise':
143  case 'Simulation':
144  case 'Questionnaire':
145  case 'Diagram':
146  case 'Figure':
147  case 'Graph':
148  case 'Index':
149  case 'Slide':
150  case 'Table':
151  case 'NarrativeText':
152  case 'Exam':
153  case 'Experiment':
154  case 'ProblemStatement':
155  case 'SelfAssessment':
156  case 'Lecture':
157  $this->learning_resource_type = $a_lrt;
158  return true;
159 
160  default:
161  return false;
162  }
163  }
+ Here is the caller graph for this function:

◆ setLearningResourceType() [2/2]

ilMDEducational::setLearningResourceType (   $a_lrt)

Definition at line 139 of file class.ilMDEducational.php.

140  {
141  switch ($a_lrt) {
142  case 'Exercise':
143  case 'Simulation':
144  case 'Questionnaire':
145  case 'Diagram':
146  case 'Figure':
147  case 'Graph':
148  case 'Index':
149  case 'Slide':
150  case 'Table':
151  case 'NarrativeText':
152  case 'Exam':
153  case 'Experiment':
154  case 'ProblemStatement':
155  case 'SelfAssessment':
156  case 'Lecture':
157  $this->learning_resource_type = $a_lrt;
158  return true;
159 
160  default:
161  return false;
162  }
163  }

◆ setPhysicalTypicalLearningTime()

ilMDEducational::setPhysicalTypicalLearningTime (   $months,
  $days,
  $hours,
  $minutes,
  $seconds 
)

Definition at line 262 of file class.ilMDEducational.php.

References setTypicalLearningTime().

263  {
264  if (!$months and !$days and !$hours and !$minutes and !$seconds) {
265  $this->setTypicalLearningTime('PT00H00M');
266  return true;
267  }
268  $tlt = 'P';
269  if ($months) {
270  $tlt .= ($months . 'M');
271  }
272  if ($days) {
273  $tlt .= ($days . 'D');
274  }
275  if ($hours or $minutes or $seconds) {
276  $tlt .= 'T';
277  }
278  if ($hours) {
279  $tlt .= ($hours . 'H');
280  }
281  if ($minutes) {
282  $tlt .= ($minutes . 'M');
283  }
284  if ($seconds) {
285  $tlt .= ($seconds . 'S');
286  }
287  $this->setTypicalLearningTime($tlt);
288  return true;
289  }
+ Here is the call graph for this function:

◆ setSemanticDensity() [1/2]

ilMDEducational::setSemanticDensity (   $a_sd)

Definition at line 187 of file class.ilMDEducational.php.

Referenced by read().

188  {
189  switch ($a_sd) {
190  case 'VeryLow':
191  case 'Low':
192  case 'Medium':
193  case 'High':
194  case 'VeryHigh':
195  $this->semantic_density = $a_sd;
196  return true;
197 
198  default:
199  return false;
200  }
201  }
+ Here is the caller graph for this function:

◆ setSemanticDensity() [2/2]

ilMDEducational::setSemanticDensity (   $a_sd)

Definition at line 187 of file class.ilMDEducational.php.

188  {
189  switch ($a_sd) {
190  case 'VeryLow':
191  case 'Low':
192  case 'Medium':
193  case 'High':
194  case 'VeryHigh':
195  $this->semantic_density = $a_sd;
196  return true;
197 
198  default:
199  return false;
200  }
201  }

◆ setTypicalLearningTime() [1/2]

ilMDEducational::setTypicalLearningTime (   $a_tlt)

Definition at line 261 of file class.ilMDEducational.php.

262  {
263  $this->typical_learning_time = $a_tlt;
264  }

◆ setTypicalLearningTime() [2/2]

ilMDEducational::setTypicalLearningTime (   $a_tlt)

Definition at line 292 of file class.ilMDEducational.php.

Referenced by read(), and setPhysicalTypicalLearningTime().

293  {
294  $this->typical_learning_time = $a_tlt;
295  }
+ Here is the caller graph for this function:

◆ toXML() [1/2]

ilMDEducational::toXML ( $writer)

Definition at line 381 of file class.ilMDEducational.php.

References $id, $key, $lang, array, getContext(), getDescription(), getDescriptionIds(), getDifficulty(), getIntendedEndUserRole(), getInteractivityLevel(), getInteractivityType(), getLanguage(), getLanguageIds(), getLearningResourceType(), getSemanticDensity(), getTypicalAgeRange(), getTypicalAgeRangeIds(), and getTypicalLearningTime().

382  {
383  $writer->xmlStartTag(
384  'Educational',
385  array('InteractivityType' => $this->getInteractivityType(),
386  'LearningResourceType' => $this->getLearningResourceType(),
387  'InteractivityLevel' => $this->getInteractivityLevel(),
388  'SemanticDensity' => $this->getSemanticDensity(),
389  'IntendedEndUserRole' => $this->getIntendedEndUserRole(),
390  'Context' => $this->getContext(),
391  'Difficulty' => $this->getDifficulty())
392  );
393 
394  // TypicalAgeRange
395  foreach ($this->getTypicalAgeRangeIds() as $id) {
396  $key =&$this->getTypicalAgeRange($id);
397  $key->toXML($writer);
398  }
399  // TypicalLearningTime
400  $writer->xmlElement('TypicalLearningTime', null, $this->getTypicalLearningTime());
401 
402  // Description
403  foreach ($this->getDescriptionIds() as $id) {
404  $key =&$this->getDescription($id);
405  $key->toXML($writer);
406  }
407  // Language
408  foreach ($this->getLanguageIds() as $id) {
409  $lang =&$this->getLanguage($id);
410  $lang->toXML($writer);
411  }
412  $writer->xmlEndTag('Educational');
413  }
& getLanguage($a_language_id)
& getDescription($a_description_id)
if(!array_key_exists('StateId', $_REQUEST)) $id
& getTypicalAgeRange($a_typical_age_range_id)
Create styles array
The data for the language used.
$key
Definition: croninfo.php:18
+ Here is the call graph for this function:

◆ toXML() [2/2]

ilMDEducational::toXML ( $writer)

Definition at line 417 of file class.ilMDEducational.php.

References $id, $key, $lang, array, getContext(), getDescription(), getDescriptionIds(), getDifficulty(), getIntendedEndUserRole(), getInteractivityLevel(), getInteractivityType(), getLanguage(), getLanguageIds(), getLearningResourceType(), ilMDBase\getObjId(), ilMDBase\getRBACId(), getSemanticDensity(), getTypicalAgeRange(), getTypicalAgeRangeIds(), and getTypicalLearningTime().

418  {
419  $writer->xmlStartTag(
420  'Educational',
421  array('InteractivityType' => $this->getInteractivityType()
422  ? $this->getInteractivityType()
423  : 'Active',
424  'LearningResourceType' => $this->getLearningResourceType()
425  ? $this->getLearningResourceType()
426  : 'Exercise',
427  'InteractivityLevel' => $this->getInteractivityLevel()
428  ? $this->getInteractivityLevel()
429  : 'Medium',
430  'SemanticDensity' => $this->getSemanticDensity()
431  ? $this->getSemanticDensity()
432  : 'Medium',
433  'IntendedEndUserRole' => $this->getIntendedEndUserRole()
434  ? $this->getIntendedEndUserRole()
435  : 'Learner',
436  'Context' => $this->getContext()
437  ? $this->getContext()
438  : 'Other',
439  'Difficulty' => $this->getDifficulty()
440  ? $this->getDifficulty()
441  : 'Medium')
442  );
443 
444  // TypicalAgeRange
445  $typ_ages = $this->getTypicalAgeRangeIds();
446  foreach ($typ_ages as $id) {
447  $key =&$this->getTypicalAgeRange($id);
448 
449  // extra test due to bug 5316 (may be due to eLaix import)
450  if (is_object($key)) {
451  $key->toXML($writer);
452  }
453  }
454  if (!count($typ_ages)) {
455  include_once 'Services/MetaData/classes/class.ilMDTypicalAgeRange.php';
456  $typ = new ilMDTypicalAgeRange($this->getRBACId(), $this->getObjId());
457  $typ->toXML($writer);
458  }
459 
460  // TypicalLearningTime
461  $writer->xmlElement('TypicalLearningTime', null, $this->getTypicalLearningTime());
462 
463  // Description
464  foreach ($this->getDescriptionIds() as $id) {
465  $key =&$this->getDescription($id);
466  $key->toXML($writer);
467  }
468  // Language
469  foreach ($this->getLanguageIds() as $id) {
470  $lang =&$this->getLanguage($id);
471  $lang->toXML($writer);
472  }
473  $writer->xmlEndTag('Educational');
474  }
& getLanguage($a_language_id)
& getDescription($a_description_id)
if(!array_key_exists('StateId', $_REQUEST)) $id
& getTypicalAgeRange($a_typical_age_range_id)
Create styles array
The data for the language used.
$key
Definition: croninfo.php:18
+ Here is the call graph for this function:

◆ update() [1/2]

ilMDEducational::update ( )

Definition at line 286 of file class.ilMDEducational.php.

References $ilDB, ilMDBase\getMetaId(), and ilDBConstants\MDB2_AUTOQUERY_UPDATE.

287  {
288  global $ilDB;
289 
290  if ($this->getMetaId()) {
291  if ($this->db->autoExecute(
292  'il_meta_educational',
293  $this->__getFields(),
295  "meta_educational_id = " . $ilDB->quote($this->getMetaId())
296  )) {
297  return true;
298  }
299  }
300  return false;
301  }
global $ilDB
+ Here is the call graph for this function:

◆ update() [2/2]

ilMDEducational::update ( )

Definition at line 324 of file class.ilMDEducational.php.

References $ilDB, array, and ilMDBase\getMetaId().

325  {
326  global $ilDB;
327 
328  if ($this->getMetaId()) {
329  if ($this->db->update(
330  'il_meta_educational',
331  $this->__getFields(),
332  array("meta_educational_id" => array('integer',$this->getMetaId()))
333  )) {
334  return true;
335  }
336  }
337  return false;
338  }
Create styles array
The data for the language used.
global $ilDB
+ Here is the call graph for this function:

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