ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
|
A class defining mark schemas for assessment test objects. More...
Public Member Functions | |
__construct () | |
ASS_MarkSchema constructor. More... | |
createSimpleSchema ( $txt_failed_short="failed", $txt_failed_official="failed", $percentage_failed=0, $failed_passed=0, $txt_passed_short="passed", $txt_passed_official="passed", $percentage_passed=50, $passed_passed=1) | |
Creates a simple mark schema for two mark steps: failed and passed. More... | |
addMarkStep ($txt_short="", $txt_official="", $percentage=0, $passed=0) | |
Adds a mark step to the mark schema. More... | |
saveToDb ($test_id) | |
Saves an ASS_MarkSchema object to a database. More... | |
loadFromDb ($test_id) | |
Loads an ASS_MarkSchema object from a database. More... | |
flush () | |
Empties the mark schema and removes all mark steps. More... | |
sort () | |
Sorts the mark schema using the minimum level values. More... | |
deleteMarkStep ($index=0) | |
Deletes the mark step with a given index. More... | |
deleteMarkSteps ($indexes) | |
Deletes multiple mark steps using their index positions. More... | |
getMatchingMark ($percentage) | |
Returns the matching mark for a given percentage. More... | |
checkMarks () | |
Check the marks for consistency. More... | |
getMarkSteps () | |
setMarkSteps ($mark_steps) | |
Static Public Member Functions | |
static | _getMatchingMark ($test_id, $percentage) |
Returns the matching mark for a given percentage. More... | |
static | _getMatchingMarkFromObjId ($a_obj_id, $percentage) |
Returns the matching mark for a given percentage. More... | |
Data Fields | |
$mark_steps | |
A class defining mark schemas for assessment test objects.
Definition at line 16 of file class.assMarkSchema.php.
ASS_MarkSchema::__construct | ( | ) |
ASS_MarkSchema constructor.
The constructor takes possible arguments an creates an instance of the ASS_MarkSchema object.
Definition at line 28 of file class.assMarkSchema.php.
References array.
|
static |
Returns the matching mark for a given percentage.
integer | $test_id | The database id of the test. |
double | $percentage | A percentage value between 0 and 100. |
PhpAssignmentInConditionInspection
Definition at line 315 of file class.assMarkSchema.php.
References $ilDB, $result, $row, and array.
|
static |
Returns the matching mark for a given percentage.
integer | $a_obj_id | The database id of the test. |
double | $percentage | A percentage value between 0 and 100. |
Definition at line 343 of file class.assMarkSchema.php.
References $ilDB, $result, $row, and array.
Referenced by ilObjTestAccess\_isPassed(), and ilObjTestAccess\isFailed().
ASS_MarkSchema::addMarkStep | ( | $txt_short = "" , |
|
$txt_official = "" , |
|||
$percentage = 0 , |
|||
$passed = 0 |
|||
) |
Adds a mark step to the mark schema.
A new ASS_Mark object will be created and stored in the $mark_steps array.
string | $txt_short | The short text of the mark. |
string | $txt_official | The official text of the mark. |
float | integer | $percentage | The minimum percentage level reaching the mark. |
integer | $passed | The passed status of the mark (0 = failed, 1 = passed). |
Definition at line 74 of file class.assMarkSchema.php.
Referenced by createSimpleSchema(), and loadFromDb().
ASS_MarkSchema::checkMarks | ( | ) |
Check the marks for consistency.
Definition at line 395 of file class.assMarkSchema.php.
References $i.
ASS_MarkSchema::createSimpleSchema | ( | $txt_failed_short = "failed" , |
|
$txt_failed_official = "failed" , |
|||
$percentage_failed = 0 , |
|||
$failed_passed = 0 , |
|||
$txt_passed_short = "passed" , |
|||
$txt_passed_official = "passed" , |
|||
$percentage_passed = 50 , |
|||
$passed_passed = 1 |
|||
) |
Creates a simple mark schema for two mark steps: failed and passed.
string | $txt_failed_short | The short text of the failed mark. |
string | $txt_failed_official | The official text of the failed mark. |
float | int | $percentage_failed | The minimum percentage level reaching the failed mark. |
integer | $failed_passed | Indicates the passed status of the failed mark (0 = failed, 1 = passed). |
string | $txt_passed_short | The short text of the passed mark. |
string | $txt_passed_official | The official text of the passed mark. |
float | int | $percentage_passed | The minimum percentage level reaching the passed mark. |
integer | $passed_passed | Indicates the passed status of the passed mark (0 = failed, 1 = passed). |
Definition at line 48 of file class.assMarkSchema.php.
References addMarkStep(), and flush().
ASS_MarkSchema::deleteMarkStep | ( | $index = 0 | ) |
Deletes the mark step with a given index.
integer | $index | The index of the mark step to delete. |
Definition at line 252 of file class.assMarkSchema.php.
References $index.
ASS_MarkSchema::deleteMarkSteps | ( | $indexes | ) |
Deletes multiple mark steps using their index positions.
array | $indexes | An array with all the index positions to delete. |
Definition at line 274 of file class.assMarkSchema.php.
ASS_MarkSchema::flush | ( | ) |
Empties the mark schema and removes all mark steps.
Definition at line 218 of file class.assMarkSchema.php.
References array.
Referenced by createSimpleSchema().
ASS_MarkSchema::getMarkSteps | ( | ) |
ASS_MarkSchema::getMatchingMark | ( | $percentage | ) |
Returns the matching mark for a given percentage.
double | $percentage | A percentage value between 0 and 100. |
Definition at line 293 of file class.assMarkSchema.php.
References $i.
ASS_MarkSchema::loadFromDb | ( | $test_id | ) |
Loads an ASS_MarkSchema object from a database.
integer | $test_id | A unique key which defines the test in the database. |
PhpAssignmentInConditionInspection
Definition at line 193 of file class.assMarkSchema.php.
References $data, $ilDB, $result, addMarkStep(), and array.
ASS_MarkSchema::saveToDb | ( | $test_id | ) |
Saves an ASS_MarkSchema object to a database.
integer | $test_id | The database id of the related test. |
PhpAssignmentInConditionInspection
PhpAssignmentInConditionInspection
Definition at line 86 of file class.assMarkSchema.php.
References $ilDB, $key, $lng, $result, $row, ilObjAssessmentFolder\_enabledAssessmentLogging(), ilObjAssessmentFolder\_getLogLanguage(), array, and time.
ASS_MarkSchema::setMarkSteps | ( | $mark_steps | ) |
ASS_Mark[] | $mark_steps |
Definition at line 429 of file class.assMarkSchema.php.
References $_GET, $ilUser, $mark_steps, ilObjAssessmentFolder\_addLog(), and ilObjTest\_getObjectIDFromTestID().
ASS_MarkSchema::sort | ( | ) |
Sorts the mark schema using the minimum level values.
Definition at line 228 of file class.assMarkSchema.php.
References $res.
ASS_MarkSchema::$mark_steps |
Definition at line 19 of file class.assMarkSchema.php.
Referenced by getMarkSteps(), and setMarkSteps().