Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

Differences Between: [Versions 310 and 311] [Versions 311 and 402] [Versions 311 and 403] [Versions 39 and 311]

Defines classes used to handle restore settings

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: 250 lines (8 kb)
Included or required:0 times
Referenced: 1 time
Includes or requires: 0 files

Defines 25 classes

restore_generic_setting:: (0 methods):

restore_users_setting:: (0 methods):

restore_permissions_setting:: (0 methods):

restore_groups_setting:: (0 methods):

restore_customfield_setting:: (0 methods):

restore_role_assignments_setting:: (0 methods):

restore_activities_setting:: (0 methods):

restore_comments_setting:: (0 methods):

restore_badges_setting:: (0 methods):

restore_competencies_setting:: (1 method):
  __construct()

restore_calendarevents_setting:: (0 methods):

restore_userscompletion_setting:: (0 methods):

restore_logs_setting:: (0 methods):

restore_grade_histories_setting:: (0 methods):

restore_course_generic_setting:: (0 methods):

restore_course_overwrite_conf_setting:: (0 methods):

restore_course_defaultcustom_setting:: (2 methods):
  validate_value()
  get_normalized_value()

restore_course_generic_text_setting:: (1 method):
  __construct()

restore_section_generic_setting:: (0 methods):

restore_section_included_setting:: (0 methods):

restore_section_userinfo_setting:: (0 methods):

restore_activity_generic_setting:: (0 methods):

restore_activity_included_setting:: (0 methods):

restore_activity_userinfo_setting:: (0 methods):

restore_contentbankcontent_setting:: (0 methods):


Class: restore_generic_setting  - X-Ref

root generic setting to store different things without dependencies

Class: restore_users_setting  - X-Ref

root setting to control if restore will create user information
A lot of other settings are dependent of this (module's user info,
grades user info, messages, blogs...

Class: restore_permissions_setting  - X-Ref

root setting to control if restore will create override permission information by roles

Class: restore_groups_setting  - X-Ref

root setting to control if restore will create groups/grouping information. Depends on @restore_users_setting

Class: restore_customfield_setting  - X-Ref

root setting to control if restore will include custom field information

Class: restore_role_assignments_setting  - X-Ref

root setting to control if restore will create role assignments
or no (any level), depends of @restore_users_setting

Class: restore_activities_setting  - X-Ref

root setting to control if restore will create activities
A lot of other settings (_included at activity levels)
are dependent of this setting

Class: restore_comments_setting  - X-Ref

root setting to control if restore will create
comments or no, depends of @restore_users_setting
exactly in the same way than @restore_role_assignments_setting so we extend from it

Class: restore_badges_setting  - X-Ref

root setting to control if restore will create badges or not,
depends on @restore_activities_setting

Class: restore_competencies_setting  - X-Ref

root setting to control if competencies will also be restored.

__construct($hascompetencies)   X-Ref
restore_competencies_setting constructor.

param: bool $hascompetencies Flag whether to set the restore setting as checked and unlocked.

Class: restore_calendarevents_setting  - X-Ref

root setting to control if restore will create
events or no, depends of @restore_users_setting
exactly in the same way than @restore_role_assignments_setting so we extend from it

Class: restore_userscompletion_setting  - X-Ref

root setting to control if restore will create
completion info or no, depends of @restore_users_setting
exactly in the same way than @restore_role_assignments_setting so we extend from it

Class: restore_logs_setting  - X-Ref

root setting to control if restore will create
logs or no, depends of @restore_users_setting
exactly in the same way than @restore_role_assignments_setting so we extend from it

Class: restore_grade_histories_setting  - X-Ref

root setting to control if restore will create
grade_histories or no, depends of @restore_users_setting
exactly in the same way than @restore_role_assignments_setting so we extend from it

Class: restore_course_generic_setting  - X-Ref

generic course setting to pass various settings between tasks and steps

Class: restore_course_overwrite_conf_setting  - X-Ref

Setting to define is we are going to overwrite course configuration

Class: restore_course_defaultcustom_setting  - X-Ref

Setting to switch between current and new course name/startdate

validate_value($vtype, $value)   X-Ref
Validates that the value $value has type $vtype

param: int $vtype
param: mixed $value
return: mixed

get_normalized_value()   X-Ref
Special method for this element only. When value is "false" returns the default value.

return: mixed

Class: restore_course_generic_text_setting  - X-Ref

__construct($name, $vtype, $value = null, $visibility = self::VISIBLE, $status = self::NOT_LOCKED)   X-Ref
No description

Class: restore_section_generic_setting  - X-Ref

generic section setting to pass various settings between tasks and steps

Class: restore_section_included_setting  - X-Ref

Setting to define if one section is included or no. Activities _included
settings depend of them if available

Class: restore_section_userinfo_setting  - X-Ref

section backup setting to control if section will include
user information or no, depends of @restore_users_setting

Class: restore_activity_generic_setting  - X-Ref

generic activity setting to pass various settings between tasks and steps

Class: restore_activity_included_setting  - X-Ref

activity backup setting to control if activity will
be included or no, depends of @restore_activities_setting and
optionally parent section included setting

Class: restore_activity_userinfo_setting  - X-Ref

activity backup setting to control if activity will include
user information or no, depends of @restore_users_setting

Class: restore_contentbankcontent_setting  - X-Ref

root setting to control if restore will create content bank content or no