Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Differences Between: [Versions 400 and 402] [Versions 400 and 403]

Base class for checks

Copyright: 2020 Brendan Heywood <brendan@catalyst-au.net>
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 118 lines (3 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

check:: (6 methods):
  get_component()
  set_component()
  get_id()
  get_ref()
  get_name()
  get_action_link()


Class: check  - X-Ref

Base class for checks

get_component()   X-Ref
Get the frankenstyle component name

return: string

set_component(string $component)   X-Ref
Get the frankenstyle component name

param: string $component name

get_id()   X-Ref
Get the check's id

This defaults to the base name of the class which is ok in the most
cases but if you have a check which can have multiple instances then
you should override this to be unique.

return: string must be unique within a component

get_ref()   X-Ref
Get the check reference

return: string must be globally unique

get_name()   X-Ref
Get the short check name

return: string

get_action_link()   X-Ref
A link to a place to action this

return: action_link|null