Moodle PHP Documentation 4.3
Moodle 4.3.5 (Build: 20240610) (7dcfaa79f78)
|
Public Member Functions | |
find_course_areas (int $courseid) | |
Return a recordset of the course areas for the course id. | |
find_relevant_areas (\core\event\base $event) | |
Return a recordset of the relevant areas for the component/module. | |
find_system_areas () | |
Return an array of area objects that contain content at the site and system levels only. | |
get_component () | |
Return the component from the full class name. | |
get_courseid_filtering () | |
Processes any sql filtering data. | |
get_fieldname () | |
Return the name of the field in the table that has the content. | |
get_ref_tablename () | |
Return the name of the reference data table name. | |
get_reftable_field_sql () | |
The standard Moodle parameter DML parameter substitution doesn't work on all versions of MySQL or Postgres, so we need to use inline function substitution to ensure that the left side is a string. | |
get_standard_area_fields_sql () | |
The standard Moodle parameter DML parameter substitution doesn't work on all versions of MySQL or Postgres, so we need to use inline function substitution to ensure that the left side is a string. | |
get_tablename () | |
Return the name of the database table where information is stored. | |
is_available () | |
Check if the system plugin is avaliable. | |
Static Public Member Functions | |
static | checkgroup_name (int $checkgroupvalue) |
Return the name for the specified checkgroup value, or 'unknown' if no valid name for the value. | |
static | checkgroup_value (string $checkgroupname) |
Return the value for the specified checkgroup name, or the unknown value if no valid value for the name. | |
Public Attributes | |
const | CHECKGROUP_FORM = 1 |
Defines the form for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_IMAGE = 2 |
Defines the image for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_LAYOUT = 3 |
Defines the layout for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_LINK = 4 |
Defines the link for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_MEDIA = 5 |
Defines the media for the 'checkgroup' field in the tool_brickfield_checks table. | |
string[] const | CHECKGROUP_NAMES |
Array for quick access of string names for 'checkgroups'. | |
const | CHECKGROUP_TABLE = 6 |
Defines the table for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_TEXT = 7 |
Defines the text for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | CHECKGROUP_UNKNOWN = 0 |
Defines the unknown for the 'checkgroup' field in the tool_brickfield_checks table. | |
const | TYPE_FIELD = 0 |
Defines field value. | |
const | TYPE_FILE = 1 |
Defines file value. | |
Protected Member Functions | |
get_type () | |
Return the defined content type. | |
Protected Attributes | |
string string | $filter = '' |
To store the filter. | |
string | $filterfieldname |
To store the filter field name. | |
array array | $filterparams = [] |
To store the filter parameters. | |
|
staticfinal |
Return the name for the specified checkgroup value, or 'unknown' if no valid name for the value.
Preferably, use this rather than direct access to CHECKGROUP_NAMES, since it checks value boundaries.
int | $checkgroupvalue |
string |
|
staticfinal |
Return the value for the specified checkgroup name, or the unknown value if no valid value for the name.
string | $checkgroupname |
int |
|
abstract |
Return a recordset of the course areas for the course id.
int | $courseid |
moodle_recordset|null |
Reimplemented in tool_brickfield\local\areas\core_course\base, tool_brickfield\local\areas\core_course\category_base, tool_brickfield\local\areas\core_course\sectionname, tool_brickfield\local\areas\core_course\sectionsummary, tool_brickfield\local\areas\core_question\answerbase, tool_brickfield\local\areas\core_question\base, tool_brickfield\local\areas\mod_book\chaptercontent, tool_brickfield\local\areas\mod_book\chaptertitle, tool_brickfield\local\areas\mod_choice\option, tool_brickfield\local\areas\mod_lesson\answer_base, tool_brickfield\local\areas\mod_lesson\page_base, and tool_brickfield\local\areas\module_area_base.
|
abstract |
Return a recordset of the relevant areas for the component/module.
core\event\base | $event |
moodle_recordset|null |
Reimplemented in tool_brickfield\local\areas\mod_choice\option, and tool_brickfield\local\areas\module_area_base.
tool_brickfield\area_base::find_system_areas | ( | ) |
Return an array of area objects that contain content at the site and system levels only.
Override this where necessary.
moodle_recordset|null |
Reimplemented in tool_brickfield\local\areas\core_course\base, tool_brickfield\local\areas\core_course\category_base, tool_brickfield\local\areas\core_question\answerbase, and tool_brickfield\local\areas\core_question\base.
tool_brickfield\area_base::get_component | ( | ) |
Return the component from the full class name.
mixed|string |
tool_brickfield\area_base::get_courseid_filtering | ( | ) |
Processes any sql filtering data.
Implement in extensions.
null |
coding_exception | |
dml_exception |
|
abstract |
Return the name of the field in the table that has the content.
string |
Reimplemented in tool_brickfield\local\areas\core_course\category_description, tool_brickfield\local\areas\core_course\category_name, tool_brickfield\local\areas\core_course\fullname, tool_brickfield\local\areas\core_course\sectionname, tool_brickfield\local\areas\core_course\sectionsummary, tool_brickfield\local\areas\core_course\shortname, tool_brickfield\local\areas\core_course\summary, tool_brickfield\local\areas\core_question\generalfeedback, tool_brickfield\local\areas\core_question\questionanswers, tool_brickfield\local\areas\core_question\questionfeedback, tool_brickfield\local\areas\core_question\questionname, tool_brickfield\local\areas\core_question\questiontext, tool_brickfield\local\areas\mod_assign\intro, tool_brickfield\local\areas\mod_assign\name, tool_brickfield\local\areas\mod_book\chaptercontent, tool_brickfield\local\areas\mod_book\chaptertitle, tool_brickfield\local\areas\mod_book\intro, tool_brickfield\local\areas\mod_book\name, tool_brickfield\local\areas\mod_chat\intro, tool_brickfield\local\areas\mod_chat\name, tool_brickfield\local\areas\mod_choice\intro, tool_brickfield\local\areas\mod_choice\name, tool_brickfield\local\areas\mod_choice\option, tool_brickfield\local\areas\mod_data\intro, tool_brickfield\local\areas\mod_data\name, tool_brickfield\local\areas\mod_feedback\intro, tool_brickfield\local\areas\mod_feedback\name, tool_brickfield\local\areas\mod_folder\intro, tool_brickfield\local\areas\mod_folder\name, tool_brickfield\local\areas\mod_forum\intro, tool_brickfield\local\areas\mod_forum\name, tool_brickfield\local\areas\mod_glossary\intro, tool_brickfield\local\areas\mod_glossary\name, tool_brickfield\local\areas\mod_imscp\intro, tool_brickfield\local\areas\mod_imscp\name, tool_brickfield\local\areas\mod_label\intro, tool_brickfield\local\areas\mod_lesson\answer_answer, tool_brickfield\local\areas\mod_lesson\answer_response, tool_brickfield\local\areas\mod_lesson\intro, tool_brickfield\local\areas\mod_lesson\name, tool_brickfield\local\areas\mod_lesson\pagecontent, tool_brickfield\local\areas\mod_lesson\pagetitle, tool_brickfield\local\areas\mod_lti\intro, tool_brickfield\local\areas\mod_lti\name, tool_brickfield\local\areas\mod_page\content, tool_brickfield\local\areas\mod_page\intro, tool_brickfield\local\areas\mod_page\name, tool_brickfield\local\areas\mod_quiz\intro, tool_brickfield\local\areas\mod_quiz\name, tool_brickfield\local\areas\mod_resource\intro, tool_brickfield\local\areas\mod_resource\name, tool_brickfield\local\areas\mod_scorm\intro, tool_brickfield\local\areas\mod_scorm\name, tool_brickfield\local\areas\mod_survey\intro, tool_brickfield\local\areas\mod_survey\name, tool_brickfield\local\areas\mod_url\intro, tool_brickfield\local\areas\mod_url\name, tool_brickfield\local\areas\mod_wiki\intro, tool_brickfield\local\areas\mod_wiki\name, tool_brickfield\local\areas\mod_workshop\intro, and tool_brickfield\local\areas\mod_workshop\name.
tool_brickfield\area_base::get_ref_tablename | ( | ) |
Return the name of the reference data table name.
string |
Reimplemented in tool_brickfield\local\areas\core_course\sectionname, tool_brickfield\local\areas\core_course\sectionsummary, tool_brickfield\local\areas\core_question\answerbase, tool_brickfield\local\areas\mod_book\chaptercontent, tool_brickfield\local\areas\mod_book\chaptertitle, tool_brickfield\local\areas\mod_choice\option, tool_brickfield\local\areas\mod_lesson\answer_base, and tool_brickfield\local\areas\mod_lesson\page_base.
tool_brickfield\area_base::get_reftable_field_sql | ( | ) |
tool_brickfield\area_base::get_standard_area_fields_sql | ( | ) |
|
abstract |
Return the name of the database table where information is stored.
string |
Reimplemented in tool_brickfield\local\areas\core_course\category_description, tool_brickfield\local\areas\core_course\category_name, tool_brickfield\local\areas\core_course\fullname, tool_brickfield\local\areas\core_course\sectionname, tool_brickfield\local\areas\core_course\sectionsummary, tool_brickfield\local\areas\core_course\shortname, tool_brickfield\local\areas\core_course\summary, tool_brickfield\local\areas\core_question\generalfeedback, tool_brickfield\local\areas\core_question\questionanswers, tool_brickfield\local\areas\core_question\questionfeedback, tool_brickfield\local\areas\core_question\questionname, tool_brickfield\local\areas\core_question\questiontext, tool_brickfield\local\areas\mod_assign\intro, tool_brickfield\local\areas\mod_assign\name, tool_brickfield\local\areas\mod_book\chaptercontent, tool_brickfield\local\areas\mod_book\chaptertitle, tool_brickfield\local\areas\mod_book\intro, tool_brickfield\local\areas\mod_book\name, tool_brickfield\local\areas\mod_chat\intro, tool_brickfield\local\areas\mod_chat\name, tool_brickfield\local\areas\mod_choice\intro, tool_brickfield\local\areas\mod_choice\name, tool_brickfield\local\areas\mod_choice\option, tool_brickfield\local\areas\mod_data\intro, tool_brickfield\local\areas\mod_data\name, tool_brickfield\local\areas\mod_feedback\intro, tool_brickfield\local\areas\mod_feedback\name, tool_brickfield\local\areas\mod_folder\intro, tool_brickfield\local\areas\mod_folder\name, tool_brickfield\local\areas\mod_forum\intro, tool_brickfield\local\areas\mod_forum\name, tool_brickfield\local\areas\mod_glossary\intro, tool_brickfield\local\areas\mod_glossary\name, tool_brickfield\local\areas\mod_imscp\intro, tool_brickfield\local\areas\mod_imscp\name, tool_brickfield\local\areas\mod_label\intro, tool_brickfield\local\areas\mod_lesson\answer_answer, tool_brickfield\local\areas\mod_lesson\answer_response, tool_brickfield\local\areas\mod_lesson\intro, tool_brickfield\local\areas\mod_lesson\name, tool_brickfield\local\areas\mod_lesson\pagecontent, tool_brickfield\local\areas\mod_lesson\pagetitle, tool_brickfield\local\areas\mod_lti\intro, tool_brickfield\local\areas\mod_lti\name, tool_brickfield\local\areas\mod_page\content, tool_brickfield\local\areas\mod_page\intro, tool_brickfield\local\areas\mod_page\name, tool_brickfield\local\areas\mod_quiz\intro, tool_brickfield\local\areas\mod_quiz\name, tool_brickfield\local\areas\mod_resource\intro, tool_brickfield\local\areas\mod_resource\name, tool_brickfield\local\areas\mod_scorm\intro, tool_brickfield\local\areas\mod_scorm\name, tool_brickfield\local\areas\mod_survey\intro, tool_brickfield\local\areas\mod_survey\name, tool_brickfield\local\areas\mod_url\intro, tool_brickfield\local\areas\mod_url\name, tool_brickfield\local\areas\mod_wiki\intro, tool_brickfield\local\areas\mod_wiki\name, tool_brickfield\local\areas\mod_workshop\intro, and tool_brickfield\local\areas\mod_workshop\name.
|
protected |
Return the defined content type.
int |
tool_brickfield\area_base::is_available | ( | ) |
Check if the system plugin is avaliable.
bool |
string [] const tool_brickfield\area_base::CHECKGROUP_NAMES |
Array for quick access of string names for 'checkgroups'.