ILIAS  trunk Revision v11.0_alpha-1749-g1a06bdef097
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
class.EditingGUIRequest.php
Go to the documentation of this file.
1 <?php
2 
20 
22 use ilArrayUtil;
23 
28 {
29  use BaseGUIRequest;
30 
31  protected array $params;
32 
33  public function __construct(
36  ?array $passed_query_params = null,
37  ?array $passed_post_data = null
38  ) {
39  $this->initRequest(
40  $http,
41  $refinery,
42  $passed_query_params,
43  $passed_post_data
44  );
45  }
46 
47  public function getRefId(): int
48  {
49  return $this->int("ref_id");
50  }
51 
52  public function getQuestionId(): int
53  {
54  return $this->int("q_id");
55  }
56 
58  public function getQuestionIds(): array
59  {
60  $ids = $this->intArray("q_id");
61  if (count($ids) === 0) {
62  $ids = $this->intArray("qid"); // this one is used in SurveyQuestionGUI
63  }
64  return $ids;
65  }
66 
67  public function getPreview(): int
68  {
69  return $this->int("preview");
70  }
71 
72  public function getSelectedQuestionTypes(): string
73  {
74  return $this->str("sel_question_types");
75  }
76 
77  public function getBaseClass(): string
78  {
79  return $this->str("baseClass");
80  }
81 
83  public function getSort(): array
84  {
85  return $this->strArray("sort");
86  }
87 
88  public function getAnswers(): array
89  {
90  $ans = $this->arrayArray("answers");
92  }
93 
94  public function getColumns(): array
95  {
96  $ans = $this->arrayArray("columns");
98  }
99 
100  public function getRows(): array
101  {
102  $ans = $this->arrayArray("rows");
104  }
105 
106  public function getNeutralScale(): string
107  {
108  return $this->str("answers_neutral_scale");
109  }
110 
111  public function getNeutral(): string
112  {
113  $ans = $this->strArray("answers");
114  return $ans["neutral"];
115  }
116 
117  public function getColumnNeutralScale(): string
118  {
119  return $this->str("columns_neutral_scale");
120  }
121 
122  public function getNewLinkType(): string
123  {
124  return $this->str("internalLinkType");
125  }
126 
127  public function getNewForSurvey(): int
128  {
129  return $this->int("new_for_survey");
130  }
131 
132  public function getNewType(): string
133  {
134  return $this->str("new_type");
135  }
136 
137  public function getLinkSourceId(): int
138  {
139  return $this->int("source_id");
140  }
141 
142  public function getLinkItemId($type): int
143  {
144  return $this->int($type);
145  }
146 
147  public function getReturn(): bool
148  {
149  return (bool) $this->int("rtrn");
150  }
151 
153  public function getFiles(): array
154  {
155  return $this->strArray("file");
156  }
157 
158  public function getPercentRow(): int
159  {
160  return $this->int("percent_row");
161  }
162 
163  public function getPercentColumns(): int
164  {
165  return $this->int("percent_columns");
166  }
167 
168  public function getPercentBipAdj1(): int
169  {
170  return $this->int("percent_bipolar_adjective1");
171  }
172 
173  public function getPercentBipAdj2(): int
174  {
175  return $this->int("percent_bipolar_adjective2");
176  }
177 
178  public function getPercentNeutral(): int
179  {
180  return $this->int("percent_neutral");
181  }
182 
183  public function getObligatory(): array
184  {
185  return $this->intArray("obligatory");
186  }
187 }
static stripSlashesRecursive($a_data, bool $a_strip_html=true, string $a_allow="")
Interface Observer Contains several chained tasks and infos about them.
$http
Definition: deliver.php:30
trait BaseGUIRequest
Base gui request wrapper.
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
initRequest(HTTP\Services $http, Refinery\Factory $refinery, ?array $passed_query_params=null, ?array $passed_post_data=null)
Query params and post data parameters are used for testing.
__construct(\ILIAS\HTTP\Services $http, \ILIAS\Refinery\Factory $refinery, ?array $passed_query_params=null, ?array $passed_post_data=null)
Builds data types.
Definition: Factory.php:35
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...