ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
class.ilQTIRenderHotspot.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
31 {
32  public const SHOWDRAW_NO = "1";
33  public const SHOWDRAW_YES = "2";
34 
35  public string $showdraw = self::SHOWDRAW_NO;
36  public ?string $minnumber = null;
37  public ?string $maxnumber = null;
39  public array $response_labels = [];
41  public array $material = [];
42 
43  public function setShowdraw(string $a_showdraw): void
44  {
45  switch (strtolower($a_showdraw)) {
46  case "1":
47  case "no":
48  $this->showdraw = self::SHOWDRAW_NO;
49  break;
50  case "2":
51  case "yes":
52  $this->showdraw = self::SHOWDRAW_YES;
53  break;
54  }
55  }
56 
57  public function getShowdraw(): string
58  {
59  return $this->showdraw;
60  }
61 
62  public function setMinnumber(string $a_minnumber): void
63  {
64  $this->minnumber = $a_minnumber;
65  }
66 
67  public function getMinnumber(): ?string
68  {
69  return $this->minnumber;
70  }
71 
72  public function setMaxnumber(string $a_maxnumber): void
73  {
74  $this->maxnumber = $a_maxnumber;
75  }
76 
77  public function getMaxnumber(): ?string
78  {
79  return $this->maxnumber;
80  }
81 
82  public function addResponseLabel(ilQTIResponseLabel $a_response_label): void
83  {
84  $this->response_labels[] = $a_response_label;
85  }
86 
87  public function addMaterial(ilQTIMaterial $a_material): void
88  {
89  $this->material[] = $a_material;
90  }
91 }
addMaterial(ilQTIMaterial $a_material)
setMaxnumber(string $a_maxnumber)
addResponseLabel(ilQTIResponseLabel $a_response_label)
setShowdraw(string $a_showdraw)
setMinnumber(string $a_minnumber)