MDL-64417 message: allow processors to run their own cleanup tasks.

This commit is contained in:
Paul Holden 2020-02-06 07:59:57 +00:00
parent 788dfb9c7d
commit db8bda61a3
3 changed files with 42 additions and 5 deletions

View file

@ -121,7 +121,26 @@ abstract class message_output {
public function force_process_messages() {
return false;
}
/**
* Allow processors to perform cleanup tasks for all notifications by overriding this method
*
* @since Moodle 3.9
* @param int $notificationdeletetime
* @return void
*/
public function cleanup_all_notifications(int $notificationdeletetime): void {
return;
}
/**
* Allow processors to perform cleanup tasks for read notifications by overriding this method
*
* @since Moodle 3.9
* @param int $notificationdeletetime
* @return void
*/
public function cleanup_read_notifications(int $notificationdeletetime): void {
return;
}
}