ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
class.ilTestPlayerCommands.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3
12{
13 const START_TEST = 'startTest';
14 const INIT_TEST = 'initTest';
15 const START_PLAYER = 'startPlayer';
16 const RESUME_PLAYER = 'resumePlayer';
17
18 const DISPLAY_ACCESS_CODE = 'displayAccessCode';
19 const ACCESS_CODE_CONFIRMED = 'accessCodeConfirmed';
20
21 const SHOW_QUESTION = 'showQuestion';
22
23 const PREVIOUS_QUESTION = 'previousQuestion';
24 const NEXT_QUESTION = 'nextQuestion';
25
26 const EDIT_SOLUTION = 'editSolution';
27 const MARK_QUESTION = 'markQuestion';
28 const MARK_QUESTION_SAVE = 'markQuestionAndSaveIntermediate';
29 const UNMARK_QUESTION = 'unmarkQuestion';
30 const UNMARK_QUESTION_SAVE = 'unmarkQuestionAndSaveIntermediate';
31
32 const SUBMIT_INTERMEDIATE_SOLUTION = 'submitIntermediateSolution';
33 const SUBMIT_SOLUTION = 'submitSolution';
34 const SUBMIT_SOLUTION_AND_NEXT = 'submitSolutionAndNext';
35 // fau: testNav - define new commands
36 const REVERT_CHANGES = 'revertChanges';
37 const DETECT_CHANGES = 'detectChanges';
38 // fau.
39 const DISCARD_SOLUTION = 'discardSolution';
40 const SKIP_QUESTION = 'skipQuestion';
41 const SHOW_INSTANT_RESPONSE = 'showInstantResponse';
42
43 const CONFIRM_HINT_REQUEST = 'confirmHintRequest';
44 const SHOW_REQUESTED_HINTS_LIST = 'showRequestedHintList';
45
46 const QUESTION_SUMMARY = 'outQuestionSummary';
47 const QUESTION_SUMMARY_INC_OBLIGATIONS = 'outQuestionSummaryWithObligationsInfo';
48 const QUESTION_SUMMARY_OBLIGATIONS_ONLY = 'outObligationsOnlySummary';
49 const TOGGLE_SIDE_LIST = 'toggleSideList';
50
51 const SHOW_QUESTION_SELECTION = 'showQuestionSelection';
52 const UNFREEZE_ANSWERS = 'unfreezeCheckedQuestionsAnswers';
53
54 const AUTO_SAVE = 'autosave';
55 const AUTO_SAVE_ON_TIME_LIMIT = 'autosaveOnTimeLimit';
56 const REDIRECT_ON_TIME_LIMIT = 'redirectAfterAutosave';
57
58 const SUSPEND_TEST = 'suspendTest';
59 const FINISH_TEST = 'finishTest';
60 const AFTER_TEST_PASS_FINISHED = 'afterTestPassFinished';
61 const SHOW_FINAL_STATMENT = 'showFinalStatement';
62
63 const BACK_TO_INFO_SCREEN = 'backToInfoScreen';
64 const BACK_FROM_FINISHING = 'backFromFinishing';
65
69 private static $nonExecutionCommands = array(
70// fau: testNav - declare DETECT_CHANGES as non execution command
71 self::DETECT_CHANGES,
72// fau.
73 self::AUTO_SAVE, self::AUTO_SAVE_ON_TIME_LIMIT, self::REDIRECT_ON_TIME_LIMIT,
74 self::AFTER_TEST_PASS_FINISHED, self::SHOW_FINAL_STATMENT
75 );
76
81 public static function isTestExecutionCommand($cmd)
82 {
83 return !in_array($cmd, self::$nonExecutionCommands);
84 }
85}
An exception for terminatinating execution or to throw for unit testing.