ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilTestSkillLevelThresholdImportFails Class Reference
+ Collaboration diagram for ilTestSkillLevelThresholdImportFails:

Public Member Functions

 __construct ($parentObjId)
 ilTestSkillLevelThresholdImportFails constructor. More...
 
 getFailedImports ()
 
 registerFailedImports (ilAssQuestionAssignedSkillList $skillList)
 
 deleteRegisteredImportFails ()
 
 failedImportsRegistered ()
 
 getFailedImportsMessage (ilLanguage $lng)
 

Protected Member Functions

 getSettings ()
 
 getParentObjId ()
 
 buildSettingsKey ()
 

Protected Attributes

 $settings
 
 $parentObjId
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilTestSkillLevelThresholdImportFails::__construct (   $parentObjId)

ilTestSkillLevelThresholdImportFails constructor.

Parameters
$parentObjId

Definition at line 26 of file class.ilTestSkillLevelThresholdImportFails.php.

References $parentObjId.

Member Function Documentation

◆ buildSettingsKey()

ilTestSkillLevelThresholdImportFails::buildSettingsKey ( )
protected
Returns
string

Definition at line 56 of file class.ilTestSkillLevelThresholdImportFails.php.

57 {
58 return 'failed_imp_slt_parentobj_' . $this->getParentObjId();
59 }

References getParentObjId().

Referenced by deleteRegisteredImportFails(), getFailedImports(), and registerFailedImports().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ deleteRegisteredImportFails()

ilTestSkillLevelThresholdImportFails::deleteRegisteredImportFails ( )

◆ failedImportsRegistered()

ilTestSkillLevelThresholdImportFails::failedImportsRegistered ( )
Returns
bool

Definition at line 93 of file class.ilTestSkillLevelThresholdImportFails.php.

References getFailedImports().

+ Here is the call graph for this function:

◆ getFailedImports()

ilTestSkillLevelThresholdImportFails::getFailedImports ( )
Returns
ilAssQuestionAssignedSkillList|null

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

65 {
66 $value = $this->getSettings()->get($this->buildSettingsKey(), null);
67
68 if ($value !== null) {
69 return unserialize($value);
70 }
71
72 return null;
73 }

References buildSettingsKey(), and getSettings().

Referenced by failedImportsRegistered(), and getFailedImportsMessage().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getFailedImportsMessage()

ilTestSkillLevelThresholdImportFails::getFailedImportsMessage ( ilLanguage  $lng)
Parameters
ilLanguage$lng
Returns
string

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

103 {
104 require_once 'Services/Skill/classes/class.ilBasicSkill.php';
105
106 $msg = $lng->txt('tst_failed_imp_skl_thresholds');
107
108 $msg .= '<ul>';
109 foreach ($this->getFailedImports() as $skillKey) {
110 list($skillBaseId, $skillTrefId) = explode(':', $skillKey);
111 $skillTitle = ilBasicSkill::_lookupTitle($skillBaseId, $skillTrefId);
112
113 $msg .= '<li>' . $skillTitle . '</li>';
114 }
115 $msg .= '</ul>';
116
117 return $msg;
118 }
static _lookupTitle($a_obj_id, $a_tref_id=0)
Lookup Title.
$lng

References $lng, ilSkillTreeNode\_lookupTitle(), and getFailedImports().

+ Here is the call graph for this function:

◆ getParentObjId()

ilTestSkillLevelThresholdImportFails::getParentObjId ( )
protected
Returns
int

Definition at line 48 of file class.ilTestSkillLevelThresholdImportFails.php.

49 {
50 return $this->parentObjId;
51 }

References $parentObjId.

Referenced by buildSettingsKey().

+ Here is the caller graph for this function:

◆ getSettings()

ilTestSkillLevelThresholdImportFails::getSettings ( )
protected
Returns
ilSetting

Definition at line 34 of file class.ilTestSkillLevelThresholdImportFails.php.

35 {
36 if ($this->settings === null) {
37 require_once 'Modules/TestQuestionPool/classes/questions/class.ilAssQuestionAssignedSkillList.php';
38
39 $this->settings = new ilSetting('assimportfails');
40 }
41
42 return $this->settings;
43 }
ILIAS Setting Class.
settings()
Definition: settings.php:2

References $settings, and settings().

Referenced by deleteRegisteredImportFails(), getFailedImports(), and registerFailedImports().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ registerFailedImports()

ilTestSkillLevelThresholdImportFails::registerFailedImports ( ilAssQuestionAssignedSkillList  $skillList)
Parameters
ilAssQuestionAssignedSkillList$skillList

Definition at line 78 of file class.ilTestSkillLevelThresholdImportFails.php.

79 {
80 $this->getSettings()->set($this->buildSettingsKey(), serialize($skillList));
81 }

References buildSettingsKey(), and getSettings().

+ Here is the call graph for this function:

Field Documentation

◆ $parentObjId

ilTestSkillLevelThresholdImportFails::$parentObjId
protected

Definition at line 20 of file class.ilTestSkillLevelThresholdImportFails.php.

Referenced by __construct(), and getParentObjId().

◆ $settings

ilTestSkillLevelThresholdImportFails::$settings
protected

Definition at line 15 of file class.ilTestSkillLevelThresholdImportFails.php.

Referenced by getSettings().


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