(no description)
Copyright: | 2010 onwards Eloy Lafuente (stronk7) {@link http://stronk7.com} |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 161 lines (7 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
restore_lesson_activity_task:: (7 methods):
define_my_settings()
define_my_steps()
define_decode_contents()
define_decode_rules()
define_restore_log_rules()
define_restore_log_rules_for_course()
after_restore()
Class: restore_lesson_activity_task - X-Ref
lesson restore task that provides all the settings and steps to perform onedefine_my_settings() X-Ref |
Define (add) particular settings this activity can have |
define_my_steps() X-Ref |
Define (add) particular steps this activity can have |
define_decode_contents() X-Ref |
Define the contents in the activity that must be processed by the link decoder |
define_decode_rules() X-Ref |
Define the decoding rules for links belonging to the activity to be executed by the link decoder |
define_restore_log_rules() X-Ref |
Define the restore log rules that will be applied by the {@link restore_logs_processor} when restoring lesson logs. It must return one array of {@link restore_log_rule} objects |
define_restore_log_rules_for_course() X-Ref |
Define the restore log rules that will be applied by the {@link restore_logs_processor} when restoring course logs. It must return one array of {@link restore_log_rule} objects Note this rules are applied when restoring course logs by the restore final task, but are defined here at activity level. All them are rules not linked to any module instance (cmid = 0) |
after_restore() X-Ref |
Re-map the dependency and activitylink information If a depency or activitylink has no mapping in the backup data then it could either be a duplication of a lesson, or a backup/restore of a single lesson. We have no way to determine which and whether this is the same site and/or course. Therefore we try and retrieve a mapping, but fallback to the original value if one was not found. We then test to see whether the value found is valid for the course being restored into. |