Moodle PHP Documentation 4.5
Moodle 4.5dev (Build: 20240606) (d3ae1391abe)
|
This class is one varying singleton that, for all the logs corresponding to one task, is in charge of storing all its restore_log_rule rules, dispatching to the correct one and insert/log the resulting information. More...
Public Member Functions | |
process_log_record ($log) | |
Static Public Member Functions | |
static | get_instance ($task, $values) |
static | register_log_rules_for_course () |
Adds all the activity restore_log_rule rules defined in activity task but corresponding to log records at course level (cmid = 0). | |
This class is one varying singleton that, for all the logs corresponding to one task, is in charge of storing all its restore_log_rule rules, dispatching to the correct one and insert/log the resulting information.
Each time the task getting the instance changes, the rules are completely reloaded with the ones in the new task. And all rules are informed with new fixed values if explicity set.
This class adopts the singleton pattern to be able to provide some persistency of rules along the restore of all the logs corresponding to one restore_task