Moodle APIs  3.8
Moodle 3.8.6 (Build: 20201109)
Static Public Member Functions | List of all members
core_auth\digital_consent Class Reference

Helper class for digital consent. More...

Static Public Member Functions

static is_age_digital_consent_verification_enabled ()
 Returns true if age and location verification is enabled in the site. More...
 
static is_minor ($age, $country)
 Checks if a user is a digital minor. More...
 
static parse_age_digital_consent_map ($ageconsentmap)
 Parse the agedigitalconsentmap setting into an array. More...
 

Detailed Description

Helper class for digital consent.

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

Member Function Documentation

◆ is_age_digital_consent_verification_enabled()

static core_auth\digital_consent::is_age_digital_consent_verification_enabled ( )
static

Returns true if age and location verification is enabled in the site.

Return values
bool

◆ is_minor()

static core_auth\digital_consent::is_minor (   $age,
  $country 
)
static

Checks if a user is a digital minor.

Parameters
int$age
string$countryThe country code (ISO 3166-2)
Return values
bool

◆ parse_age_digital_consent_map()

static core_auth\digital_consent::parse_age_digital_consent_map (   $ageconsentmap)
static

Parse the agedigitalconsentmap setting into an array.

Parameters
string$ageconsentmapThe value of the agedigitalconsentmap setting
Return values
array::$ageconsentmapparsed

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