23 include_once
"./Modules/Test/classes/inc.AssessmentConstants.php";
53 $this->
object =& $a_object;
58 $feedbacksgeneric = array();
59 foreach ($item->resprocessing as $resprocessing)
61 foreach ($resprocessing->respcondition as $respcondition)
63 foreach ($respcondition->displayfeedback as $feedbackpointer)
65 if (strlen($feedbackpointer->getLinkrefid()))
67 foreach ($item->itemfeedback as $ifb)
69 if (strcmp($ifb->getIdent(),
"response_allcorrect") == 0)
72 if (count($ifb->material))
74 foreach ($ifb->material as $material)
76 $feedbacksgeneric[1] = $material;
79 if ((count($ifb->flow_mat) > 0))
81 foreach ($ifb->flow_mat as $fmat)
83 if (count($fmat->material))
85 foreach ($fmat->material as $material)
87 $feedbacksgeneric[1] = $material;
93 else if (strcmp($ifb->getIdent(),
"response_onenotcorrect") == 0)
96 if (count($ifb->material))
98 foreach ($ifb->material as $material)
100 $feedbacksgeneric[0] = $material;
103 if ((count($ifb->flow_mat) > 0))
105 foreach ($ifb->flow_mat as $fmat)
107 if (count($fmat->material))
109 foreach ($fmat->material as $material)
111 $feedbacksgeneric[0] = $material;
123 foreach ($feedbacksgeneric as $correctness => $material)
125 $m = $this->
object->QTIMaterialToString($material);
126 $feedbacksgeneric[$correctness] = $m;
128 return $feedbacksgeneric;
144 function fromXML(&$item, $questionpool_id, &$tst_id, &$tst_object, &$question_counter, &$import_mapping)