This commit is contained in:
Jun Pataleta 2024-03-08 08:00:41 +08:00
commit 3278ce7aba
No known key found for this signature in database
GPG key ID: F83510526D99E2C7
1147 changed files with 2621 additions and 2617 deletions

View file

@ -77,7 +77,7 @@ abstract class condition extends tree_node {
* @param int $userid User ID to check availability for
* @return bool True if available
*/
public abstract function is_available($not, info $info, $grabthelot, $userid);
abstract public function is_available($not, info $info, $grabthelot, $userid);
public function check_available($not, info $info, $grabthelot, $userid) {
// Use is_available, and we always display (at this stage).
@ -195,7 +195,7 @@ abstract class condition extends tree_node {
* @return string Information string (for admin) about all restrictions on
* this item
*/
public abstract function get_description($full, $not, info $info);
abstract public function get_description($full, $not, info $info);
/**
* Obtains a string describing this restriction, used when there is only
@ -235,7 +235,7 @@ abstract class condition extends tree_node {
*
* @return string Text representation of parameters
*/
protected abstract function get_debug_string();
abstract protected function get_debug_string();
public function update_dependency_id($table, $oldid, $newid) {
// By default, assumes there are no dependent ids.

View file

@ -81,7 +81,7 @@ abstract class info {
*
* @return \context Context for this item
*/
public abstract function get_context();
abstract public function get_context();
/**
* Obtains the modinfo associated with this availability information.
@ -378,7 +378,7 @@ abstract class info {
*
* @return string Name of item
*/
protected abstract function get_thing_name();
abstract protected function get_thing_name();
/**
* Stores an updated availability tree JSON structure into the relevant
@ -386,7 +386,7 @@ abstract class info {
*
* @param string $availabilty New JSON value
*/
protected abstract function set_in_database($availabilty);
abstract protected function set_in_database($availabilty);
/**
* In rare cases the system may want to change all references to one ID
@ -662,7 +662,7 @@ abstract class info {
*
* @return string Name of capability used to view hidden items of this type
*/
protected abstract function get_view_hidden_capability();
abstract protected function get_view_hidden_capability();
/**
* Obtains SQL that returns a list of enrolled users that has been filtered

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -63,7 +63,7 @@ abstract class tree_node {
* @param int $userid User ID to check availability for
* @return result Availability check result
*/
public abstract function check_available($not,
abstract public function check_available($not,
\core_availability\info $info, $grabthelot, $userid);
/**
@ -77,14 +77,14 @@ abstract class tree_node {
* @param bool $not Set true if we are inverting the condition
* @return bool True if condition will return available for everyone
*/
public abstract function is_available_for_all($not = false);
abstract public function is_available_for_all($not = false);
/**
* Saves tree data back to a structure object.
*
* @return \stdClass Structure object (ready to be made into JSON format)
*/
public abstract function save();
abstract public function save();
/**
* Checks whether this node should be included after restore or not. The
@ -134,7 +134,7 @@ abstract class tree_node {
* @param int $newid New ID
* @return bool True if it changed, otherwise false
*/
public abstract function update_dependency_id($table, $oldid, $newid);
abstract public function update_dependency_id($table, $oldid, $newid);
/**
* Checks whether this condition applies to user lists. The default is

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -40,7 +40,7 @@ class provider implements \core_privacy\local\metadata\null_provider {
*
* @return string
*/
public static function get_reason() : string {
public static function get_reason(): string {
return 'privacy:metadata';
}
}

View file

@ -109,7 +109,7 @@ class mock_info_module extends info_module {
* Override course-module info.
* @param \cm_info $cm
*/
public function set_cm (\cm_info $cm) {
public function set_cm(\cm_info $cm) {
$this->cm = $cm;
}
}

View file

@ -110,7 +110,7 @@ class mock_info_section extends info_section {
*
* @param \section_info $section
*/
public function set_section (\section_info $section) {
public function set_section(\section_info $section) {
$this->section = $section;
}
}