Moodle PHP Documentation 4.3
Moodle 4.3.5 (Build: 20240610) (7dcfaa79f78)
mod_quiz\question\qubaids_for_quiz Class Reference
Inheritance diagram for mod_quiz\question\qubaids_for_quiz:
qubaid_join qubaid_condition

Public Member Functions

 __construct (int $quizid, bool $includepreviews=true, bool $onlyfinished=false)
 Constructor.
 
 from_question_attempts ($alias)
 Get the SQL fragment to go in a FROM clause.
 
 from_where_params ()
 
 get_hash_code ()
 
 usage_id_in ()
 
 usage_id_in_params ()
 
 where ()
 

Public Attributes

 $from
 
 $params
 
 $usageidcolumn
 
 $where
 

Detailed Description

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

Constructor & Destructor Documentation

◆ __construct()

mod_quiz\question\qubaids_for_quiz::__construct ( int $quizid,
bool $includepreviews = true,
bool $onlyfinished = false )

Constructor.

Parameters
int$quizidThe quiz to search.
bool$includepreviewsWhether to include preview attempts
bool$onlyfinishedWhether to only include finished attempts or not

Member Function Documentation

◆ from_question_attempts()

qubaid_join::from_question_attempts ( $alias)
inherited

Get the SQL fragment to go in a FROM clause.

The SQL that needs to go in the FROM clause when trying to select records from the 'question_attempts' table based on this qubaid_condition.

Parameters
string$alias
Return values
stringSQL fragment.

Reimplemented from qubaid_condition.

◆ from_where_params()

qubaid_join::from_where_params ( )
inherited
Return values
arraythe params needed by a query that uses from_question_attempts() and where().

Reimplemented from qubaid_condition.

◆ get_hash_code()

qubaid_condition::get_hash_code ( )
inherited
Return values
string40-character hash code that uniquely identifies the combination of properties and class name of this qubaid condition.

◆ usage_id_in()

qubaid_join::usage_id_in ( )
inherited
Return values
stringSQL that can use used in a WHERE qubaid IN (...) query. This method returns the "IN (...)" part.

Reimplemented from qubaid_condition.

◆ usage_id_in_params()

qubaid_join::usage_id_in_params ( )
inherited
Return values
arraythe params needed by a query that uses usage_id_in().

Reimplemented from qubaid_condition.

◆ where()

qubaid_join::where ( )
inherited
Return values
stringthe SQL that needs to go in the where clause.

Reimplemented from qubaid_condition.


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