Moodle PHP Documentation 4.5
Moodle 4.5dev (Build: 20240606) (d3ae1391abe)
qtype_ordering\output\feedback Class Reference
Inheritance diagram for qtype_ordering\output\feedback:
qtype_ordering\output\renderable_base templatable renderable

Public Member Functions

 __construct (question_attempt $qa, protected question_display_options question_display_options $options)
 Define the feedback with options for display.
 
 export_for_template (renderer_base $output)
 Function to export the renderer data in a format that is suitable for a mustache template.
 

Constructor & Destructor Documentation

◆ __construct()

qtype_ordering\output\feedback::__construct ( question_attempt $qa,
protected question_display_options question_display_options $options )

Define the feedback with options for display.

Parameters
question_attempt$qaThe question attempt object.
question_display_options$optionsControls what should and should not be displayed via question_display_options but unit tests are fickle.
Parameters
$optionsThe question display options.

Member Function Documentation

◆ export_for_template()

qtype_ordering\output\feedback::export_for_template ( renderer_base $output)

Function to export the renderer data in a format that is suitable for a mustache template.

This means:

  1. No complex types - only stdClass, array, int, string, float, bool
  2. Any additional info that is required for the template is pre-calculated (e.g. capability checks).
Parameters
renderer_base$outputUsed to do a final render of any components that need to be rendered for export.
Return values
stdClass|array

Implements templatable.


The documentation for this class was generated from the following file: