Moodle PHP Documentation 4.2
Moodle 4.2.8 (Build: 20240610) (2d41ac46f45)
core_question\external\question_summary_exporter Class Reference

Class for exporting a question summary from an stdClass. More...

Inheritance diagram for core_question\external\question_summary_exporter:

Public Member Functions

 __construct (\stdClass $question, $related=[])
 Constructor.
 

Static Public Member Functions

static define_properties ()
 The list of static properties returned.
 
static get_mandatory_properties ()
 The list of mandatory properties required on the question object to export.
 

Protected Member Functions

 get_other_values (\renderer_base $output)
 Calculate the values for the properties defined in the define_other_properties function.
 

Static Protected Member Functions

static define_other_properties ()
 Define the list of calculated properties.
 
static define_related ()
 Set the moodle context as a required related object.
 

Protected Attributes

stdClass $question
 $question
 

Detailed Description

Class for exporting a question summary from an stdClass.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Constructor & Destructor Documentation

◆ __construct()

core_question\external\question_summary_exporter::__construct ( \stdClass $question,
$related = [] )

Constructor.

Parameters
stdClass$question
array$relatedThe related data.

Member Function Documentation

◆ define_other_properties()

static core_question\external\question_summary_exporter::define_other_properties ( )
staticprotected

Define the list of calculated properties.

Return values
arrayThe list of properties.

◆ define_properties()

static core_question\external\question_summary_exporter::define_properties ( )
static

The list of static properties returned.

Return values
arrayList of properties.

◆ define_related()

static core_question\external\question_summary_exporter::define_related ( )
staticprotected

Set the moodle context as a required related object.

Return values
arrayRequired related objects.

◆ get_mandatory_properties()

static core_question\external\question_summary_exporter::get_mandatory_properties ( )
static

The list of mandatory properties required on the question object to export.

Return values
string[]List of properties.

◆ get_other_values()

core_question\external\question_summary_exporter::get_other_values ( \renderer_base $output)
protected

Calculate the values for the properties defined in the define_other_properties function.

Parameters
renderer_base$outputA renderer.
Return values
arrayThe list of properties.

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