4 require_once
'Modules/TestQuestionPool/classes/class.ilAssQuestionList.php';
75 $dynamicQuestionSetConfig,
80 $dynamicQuestionSetConfig,
85 $dynamicQuestionSetConfig,
90 $dynamicQuestionSetConfig,
91 $this->filteredQuestionList
101 $answerStatusActiveId
104 $questionList->load();
106 return $questionList;
121 require_once
'Services/Taxonomy/classes/class.ilObjTaxonomy.php';
128 $questionList->addTaxonomyFilter(
131 $this->testOBJ->getId(),
132 $this->testOBJ->getType()
136 $questionList->setAvailableTaxonomyIds(array(
143 $questionList->load();
145 return $questionList;
161 require_once
'Services/Taxonomy/classes/class.ilObjTaxonomy.php';
168 $questionList->addTaxonomyFilter(
171 $this->testOBJ->getId(),
172 $this->testOBJ->getType()
177 $questionList->load();
179 return $questionList;
198 require_once
'Services/Taxonomy/classes/class.ilObjTaxonomy.php';
201 require_once
'Modules/Test/classes/class.ilTestTaxonomyTree.php';
203 $tree->initOrderedTreeIndex($tax);
205 $questionsByNode = array();
206 $nodelessQuestions = array();
209 if (isset($qData[
'taxonomies'][$orderingTaxId]) && count($qData[
'taxonomies'][$orderingTaxId])) {
210 foreach ($qData[
'taxonomies'][$orderingTaxId] as $nodeId => $itemData) {
211 $nodeOrderingPath =
$tree->getNodeOrderingPathString($itemData[
'node_id']);
213 if (!isset($questionsByNode[ $nodeOrderingPath ])) {
214 $questionsByNode[ $nodeOrderingPath ] = array();
218 $questionsByNode[ $nodeOrderingPath ][$itemData[
'order_nr']] = $qId;
220 $questionsByNode[ $nodeOrderingPath ][$qData[
'title'] .
'::' . $qId] = $qId;
224 $nodelessQuestions[$qData[
'tstamp'] .
'::' . $qId] = $qId;
228 foreach ($questionsByNode as
$path => $questions) {
230 ksort($questions, SORT_NUMERIC);
232 ksort($questions, SORT_STRING);
235 $questionsByNode[
$path] = array_values($questions);
238 ksort($questionsByNode, SORT_STRING);
239 $sequence = array_values($questionsByNode);
241 ksort($nodelessQuestions);
242 $sequence[] = array_values($nodelessQuestions);
252 $sequence[ $qData[
'tstamp'] .
'::' . $qId ] = $qId;
256 $sequence = array_values($sequence);
258 return array($sequence);
270 $questionData = $this->completeQuestionList->getQuestionDataArray();
271 return isset($questionData[$questionId]);
276 $questionData = $this->completeQuestionList->getQuestionDataArray();
277 return $questionData[$questionId];
282 return $this->completeQuestionList->getQuestionDataArray();
318 $questionList =
new ilAssQuestionList($this->db, $this->lng, $this->pluginAdmin);
319 $questionList->setParentObjId($sourceQuestionPoolId);
320 $questionList->setAnswerStatusActiveId($answerStatusActiveId);
321 return $questionList;
__construct(ilDBInterface $db, ilLanguage $lng, ilPluginAdmin $pluginAdmin, ilObjTest $testOBJ)
Constructor.
getCompleteQuestionList()
initFilteredQuestionList(ilObjTestDynamicQuestionSetConfig $dynamicQuestionSetConfig, ilTestDynamicQuestionSetFilterSelection $filterSelection)
getQuestionSequenceStructuredByUpdateDate(ilAssQuestionList $questionList)
static getUsageOfObject($a_obj_id, $a_include_titles=false)
Get usage of object.
isTaxonomyFilterEnabled()
isser for taxonomie filter enabled
getAnswerStatusSelection()
getAnswerStatusActiveId()
Administration class for plugins.
initActualQuestionSequence(ilObjTestDynamicQuestionSetConfig $dynamicQuestionSetConfig, ilAssQuestionList $questionList)
initSelectionQuestionList(ilObjTestDynamicQuestionSetConfig $dynamicQuestionSetConfig, ilTestDynamicQuestionSetFilterSelection $filterSelection)
getFilteredQuestionList()
getQuestionSequenceStructuredByTaxonomy(ilAssQuestionList $questionList, $orderingTaxId)
questionExists($questionId)
isAnswerStatusFilterEnabled()
buildQuestionList($sourceQuestionPoolId, $answerStatusActiveId)
getActualQuestionSequence()
getSelectionQuestionList()
getQuestionData($questionId)
getOrderingTaxonomyId()
setter for ordering taxonomy id
getSourceQuestionPoolId()
getter for source question pool id
initCompleteQuestionList(ilObjTestDynamicQuestionSetConfig $dynamicQuestionSetConfig, $answerStatusActiveId)
load(ilObjTestDynamicQuestionSetConfig $dynamicQuestionSetConfig, ilTestDynamicQuestionSetFilterSelection $filterSelection)