19 declare(strict_types=1);
    37         $result = $this->db->queryF(
    38             'SELECT * FROM ' . self::DB_TABLE . 
' WHERE test_fi = %s ORDER BY minimum_level',
    42         if ($this->db->numRows($result) > 0) {
    44             while (
$data = $this->db->fetchAssoc($result)) {
    45                 $mark_steps[] = 
new Mark(
    47                     $data[
'official_name'],
    48                     (
float) 
$data[
'minimum_level'],
    49                     (
bool) $data[
'passed']
    52             return $schema->withMarkSteps($mark_steps);
    55         return $schema->createSimpleSchema();
    64         $this->db->manipulateF(
    65             'DELETE FROM ' . self::DB_TABLE . 
' WHERE test_fi = %s',
    75             $mark_array = $mark->toStorage();
    76             $mark_array[
'mark_id'] = [
'integer', $this->db->nextId(self::DB_TABLE)];
    77             $mark_array[
'test_fi'] = [
'integer', $mark_schema->
getTestId()];
 
A class defining mark schemas for assessment test objects. 
 
A class defining marks for assessment test objects. 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
getMarkSchemaFor(int $test_id)
 
__construct(private readonly \ilDBInterface $db)
 
storeMarkSchema(MarkSchema $mark_schema)