24define(
"QT_UNKNOWN", 
"unknown");
 
   25define(
"QT_KPRIM_CHOICE", 
"assKprimChoice");
 
   26define(
"QT_LONG_MENU", 
"assLongMenu");
 
   27define(
"QT_MULTIPLE_CHOICE_SR", 
"assSingleChoice");
 
   28define(
"QT_MULTIPLE_CHOICE_MR", 
"assMultipleChoice");
 
   29define(
"QT_CLOZE", 
"assClozeTest");
 
   30define(
"QT_ERRORTEXT", 
"assErrorText");
 
   31define(
"QT_MATCHING", 
"assMatchingQuestion");
 
   32define(
"QT_ORDERING", 
"assOrderingQuestion");
 
   33define(
"QT_ORDERING_HORIZONTAL", 
"assOrderingHorizontal");
 
   34define(
"QT_IMAGEMAP", 
"assImagemapQuestion");
 
   35define(
"QT_JAVAAPPLET", 
"assJavaApplet");
 
   36define(
"QT_FLASHAPPLET", 
"assFlashApplet");
 
   37define(
"QT_TEXT", 
"assTextQuestion");
 
   38define(
"QT_FILEUPLOAD", 
"assFileUpload");
 
   39define(
"QT_NUMERIC", 
"assNumeric");
 
   40define(
"QT_FORMULA", 
"assFormulaQuestion");
 
   41define(
"QT_TEXTSUBSET", 
"assTextSubset");
 
   77        $this->response = array();
 
   78        $this->resprocessing = array();
 
   79        $this->itemfeedback = array();
 
   80        $this->presentation = 
null;
 
   81        $this->presentationitem = array();
 
   82        $this->suggested_solutions = array();
 
   83        $this->itemmetadata = array();
 
   85        $this->iliasSourceVersion = 
null;
 
   86        $this->iliasSourceNic = 
null;
 
   91        $this->ident = $a_ident;
 
  101        $this->title = $a_title;
 
  111        if (preg_match(
"/(.*?)\=(.*)/", $a_comment, $matches)) {
 
  113            switch ($matches[1]) {
 
  114                case "ILIAS Version":
 
  115                    $this->ilias_version = $matches[2];
 
  119                    $this->questiontype = $matches[2];
 
  123                    $this->author = $matches[2];
 
  138        if (preg_match(
"/P(\d+)Y(\d+)M(\d+)DT(\d+)H(\d+)M(\d+)S/", $a_duration, $matches)) {
 
  139            $this->duration = array(
 
  154        $this->questiontext = $a_questiontext;
 
  164        array_push($this->resprocessing, $a_resprocessing);
 
  169        array_push($this->itemfeedback, $a_itemfeedback);
 
  174        $this->maxattempts = $a_maxattempts;
 
  184        $this->label = $a_label;
 
  194        $this->xmllang = $a_xmllang;
 
  204        $this->presentation = $a_presentation;
 
  215        if ($this->presentation != 
null) {
 
  221        $this->questiontype = $a_questiontype;
 
  231        array_push($this->presentationitem, $a_presentationitem);
 
  236        switch ($this->questiontype) {
 
  237            case "ORDERING QUESTION":
 
  239            case "KPRIM CHOICE QUESTION":
 
  241            case "LONG MENU QUESTION":
 
  243            case "SINGLE CHOICE QUESTION":
 
  245            case "MULTIPLE CHOICE QUESTION":
 
  247            case "MATCHING QUESTION":
 
  249            case "CLOZE QUESTION":
 
  251            case "IMAGE MAP QUESTION":
 
  253            case "JAVA APPLET QUESTION":
 
  255            case "TEXT QUESTION":
 
  257            case "NUMERIC QUESTION":
 
  259            case "TEXTSUBSET QUESTION":
 
  262        if (!$this->presentation) {
 
  265        foreach ($this->presentation->order as $entry) {
 
  266            switch ($entry[
"type"]) {
 
  268                    $response = $this->presentation->response[$entry[
"index"]];
 
  304                    $material = $this->presentation->material[$entry[
"index"]];
 
  305                    if (is_array($material->matapplet) && count($material->matapplet) > 0) {
 
  311        if (strlen($this->questiontype) == 0) {
 
  320        $this->author = $a_author;
 
  362        array_push($this->suggested_solutions, array(
"solution" => $a_solution, 
"gap_index" => $a_gap_index));
 
  367        array_push($this->itemmetadata, $a_metadata);
 
  377        foreach ($this->itemmetadata as 
$metadata) {
 
  378            if (strcmp(
$metadata[
"label"], $a_label) == 0) {
 
$metadata['__DYNAMIC:1__']
An exception for terminatinating execution or to throw for unit testing.
const QT_MULTIPLE_CHOICE_MR
const QT_MULTIPLE_CHOICE_SR
const R_CARDINALITY_SINGLE
const R_CARDINALITY_ORDERED
const R_CARDINALITY_MULTIPLE
setPresentation($a_presentation)
addResprocessing($a_resprocessing)
setIliasSourceNic($iliasSourceNic)
setMaxattempts($a_maxattempts)
setIliasSourceVersion($iliasSourceVersion)
addSuggestedSolution($a_solution, $a_gap_index)
getMetadataEntry($a_label)
setQuestiontext($a_questiontext)
addItemfeedback($a_itemfeedback)
addPresentationitem($a_presentationitem)
setQuestiontype($a_questiontype)