Skip to content

Commit 22f9831

Browse files
authored
feat: implement get_question_summary
1 parent d46d5e4 commit 22f9831

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

question.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,21 @@ public function apply_attempt_state(question_attempt_step $step) {
219219
}
220220
}
221221

222+
/**
223+
* Generate a brief, plain-text, summary of this question. This is used by
224+
* various reports. This should show the particular variant of the question
225+
* as presented to students. For example, the calculated question type would
226+
* fill in the particular numbers that were presented to the student.
227+
* This method will return null if such a summary is not possible, or
228+
* inappropriate.
229+
*
230+
* @return string|null a plain text summary of this question.
231+
*/
232+
public function get_question_summary() {
233+
// Parent method is not called, because we do not use questiontext.
234+
return null;
235+
}
236+
222237
/**
223238
* Checks that our behaviour has been set, which happens in {@see qbehaviour_questionpy::__construct}.
224239
*

0 commit comments

Comments
 (0)