Moodle PHP Documentation 4.5
Moodle 4.5dev (Build: 20240606) (d3ae1391abe)
core\check\access\riskbackup_result Class Reference

Lists all roles that have the ability to backup user data, as well as users. More...

Inheritance diagram for core\check\access\riskbackup_result:
core\check\result renderable

Public Member Functions

 __construct ()
 Constructor.
 
 export_for_template (\renderer_base $output)
 Export this data so it can be used as the context for a mustache template.
 
 get_details ()
 Showing the full list of roles may be slow so defer it.
 
 get_ref ()
 Get the check reference label.
 
 get_status ()
 Get the check status.
 
 get_summary ()
 Summary of the check.
 
 get_template_name ()
 Which mustache template?
 

Public Attributes

const CRITICAL = 'critical'
 This is used to notify if a check is a major critical issue.
 
const ERROR = 'error'
 This is used to notify if a check failed.
 
const INFO = 'info'
 This is used to show info for a check.
 
const NA = 'na'
 This is used to notify if a check does not apply.
 
const OK = 'ok'
 Ideally all checks should be ok.
 
const UNKNOWN = 'unknown'
 This means we could not determine the state.
 
const WARNING = 'warning'
 Warnings.
 

Protected Attributes

string $details = ''
 details about check.
 
string $status = self::UNKNOWN
 $status - status
 
string $summary = ''
 summary - should be roughly 1 line of plain text and may change depending on the state.
 

Detailed Description

Lists all roles that have the ability to backup user data, as well as users.

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

Member Function Documentation

◆ export_for_template()

core\check\result::export_for_template ( \renderer_base $output)
inherited

Export this data so it can be used as the context for a mustache template.

Parameters
renderer_base$outputtypically, the renderer that's calling this function
Return values
arraydata context for a mustache template

◆ get_details()

core\check\access\riskbackup_result::get_details ( )

Showing the full list of roles may be slow so defer it.

Return values
string

Reimplemented from core\check\result.

◆ get_ref()

core\check\result::get_ref ( )
inherited

Get the check reference label.

Return values
stringmust be globally unique

◆ get_status()

core\check\result::get_status ( )
inherited

Get the check status.

Return values
stringone of the consts eg result\OK

◆ get_summary()

core\check\result::get_summary ( )
inherited

Summary of the check.

Return values
stringformatted html

◆ get_template_name()

core\check\result::get_template_name ( )
inherited

Which mustache template?

Return values
stringpath to mustache template

Member Data Documentation

◆ $details

string core\check\result::$details = ''
protectedinherited

details about check.

This may be a large amount of preformatted html text, possibly describing all the different states and actions to address them.

◆ CRITICAL

const core\check\result::CRITICAL = 'critical'
inherited

This is used to notify if a check is a major critical issue.

An error which is affecting everyone in a major way.

◆ ERROR

const core\check\result::ERROR = 'error'
inherited

This is used to notify if a check failed.

Something is wrong with a component and a feature is not working.

◆ INFO

const core\check\result::INFO = 'info'
inherited

This is used to show info for a check.

This is equivalent to OK but could be used for alerting to potential future warnings such as a deprecation in a service.

◆ NA

const core\check\result::NA = 'na'
inherited

This is used to notify if a check does not apply.

In most cases if a check doesn't apply a check object shouldn't be made. This state exists for when you always want visibilty of the check itself. Can be useful for a check which depends on another check and it helps focus on the other check which matters more.

◆ UNKNOWN

const core\check\result::UNKNOWN = 'unknown'
inherited

This means we could not determine the state.

An example might be an expensive check done via cron, and it has never run. It would be prudent to consider an unknown check as a warning or error.

◆ WARNING

const core\check\result::WARNING = 'warning'
inherited

Warnings.

Something is not ideal and should be addressed, eg usability or the speed of the site may be affected, but it may self heal (eg a load spike)


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