ILIAS  Release_4_2_x_branch Revision 61807
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilQTIRenderChoice.php
Go to the documentation of this file.
1 <?php
2 /*
3  +-----------------------------------------------------------------------------+
4  | ILIAS open source |
5  +-----------------------------------------------------------------------------+
6  | Copyright (c) 1998-2001 ILIAS open source, University of Cologne |
7  | |
8  | This program is free software; you can redistribute it and/or |
9  | modify it under the terms of the GNU General Public License |
10  | as published by the Free Software Foundation; either version 2 |
11  | of the License, or (at your option) any later version. |
12  | |
13  | This program is distributed in the hope that it will be useful, |
14  | but WITHOUT ANY WARRANTY; without even the implied warranty of |
15  | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16  | GNU General Public License for more details. |
17  | |
18  | You should have received a copy of the GNU General Public License |
19  | along with this program; if not, write to the Free Software |
20  | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21  +-----------------------------------------------------------------------------+
22 */
23 
24 define ("SHUFFLE_NO", "0");
25 define ("SHUFFLE_YES", "1");
26 
36 {
37  var $shuffle;
41  var $material;
42 
43  function ilQTIRenderChoice()
44  {
45  $this->shuffle = SHUFFLE_NO;
46  $this->response_labels = array();
47  $this->material = array();
48  }
49 
50  function setShuffle($a_shuffle)
51  {
52  switch (strtolower($a_shuffle))
53  {
54  case "0":
55  case "no":
56  $this->shuffle = SHUFFLE_NO;
57  break;
58  case "1":
59  case "yes":
60  $this->shuffle = SHUFFLE_YES;
61  break;
62  }
63  }
64 
65  function getShuffle()
66  {
67  return $this->shuffle;
68  }
69 
70  function setMinnumber($a_minnumber)
71  {
72  $this->minnumber = $a_minnumber;
73  }
74 
75  function getMinnumber()
76  {
77  return $this->minnumber;
78  }
79 
80  function setMaxnumber($a_maxnumber)
81  {
82  $this->maxnumber = $a_maxnumber;
83  }
84 
85  function getMaxnumber()
86  {
87  return $this->maxnumber;
88  }
89 
90  function addResponseLabel($a_response_label)
91  {
92  array_push($this->response_labels, $a_response_label);
93  }
94 
95  function addMaterial($a_material)
96  {
97  array_push($this->material, $a_material);
98  }
99 }
100 ?>