46 return "u{$this->userId}::q{$this->questionId}";
66 $this->
saveSessionValue(self::SESSION_SUBINDEX_INSTANT_RESPONSE_ACTIVE, $instantResponseActive);
71 return $this->
readSessionValue(self::SESSION_SUBINDEX_INSTANT_RESPONSE_ACTIVE);
76 $this->
saveSessionValue(self::SESSION_SUBINDEX_PARTICIPANT_SOLUTION, $participantSolution);
93 if (!is_array($hints)) {
102 $requestedHints = $this->
readSessionValue(self::SESSION_SUBINDEX_REQUESTED_HINTS);
103 return isset($requestedHints[$hintId]);
108 $requestedHints = $this->
readSessionValue(self::SESSION_SUBINDEX_REQUESTED_HINTS);
109 $requestedHints[$hintId] = $hintId;
110 $this->
saveSessionValue(self::SESSION_SUBINDEX_REQUESTED_HINTS, $requestedHints);
140 if (!isset(
$_SESSION[self::SESSION_BASEINDEX]) || !is_array(
$_SESSION[self::SESSION_BASEINDEX])) {
152 if (!isset($contextSession[self::SESSION_SUBINDEX_INSTANT_RESPONSE_ACTIVE])) {
156 if (!isset($contextSession[self::SESSION_SUBINDEX_PARTICIPANT_SOLUTION])) {
160 if (!isset($contextSession[self::SESSION_SUBINDEX_RANDOMIZER_SEED])) {
An exception for terminatinating execution or to throw for unit testing.
const SESSION_SUBINDEX_REQUESTED_HINTS
const SESSION_SUBINDEX_RANDOMIZER_SEED
ensureSessionStructureExists()
__construct($userId, $questionId)
getParticipantsSolution()
addRequestedHint($hintId)
setParticipantsSolution($participantSolution)
issetSessionValue($subIndex)
saveSessionValue($subIndex, $value)
const SESSION_SUBINDEX_PARTICIPANT_SOLUTION
const SESSION_SUBINDEX_INSTANT_RESPONSE_ACTIVE
isInstantResponseActive()
readSessionValue($subIndex)
setInstantResponseActive($instantResponseActive)