|
Moodle
2.2.1
http://www.collinsharper.com
|


Static Public Member Functions | |
| static | get_blockids_from_moduleid ($moduleid) |
| static | get_blockids_from_courseid ($courseid) |
| static | get_modules_from_sectionid ($sectionid) |
| static | get_sections_from_courseid ($courseid) |
| static | get_courseformat_from_courseid ($courseid) |
| static | get_theme_from_courseid ($courseid) |
| static | get_mnet_localhost_wwwroot () |
| static | get_default_backup_filename ($format, $type, $id, $users, $anonymised, $useidasname=false) |
| static | require_gradebook_backup ($courseid, $backupid) |
Non instantiable helper class providing DB support to the class
This class contains various static methods available for all the DB operations performed by the (and builder) classes
TODO: Finish phpdocs
Definition at line 33 of file backup_plan_dbops.class.php.
| static get_blockids_from_courseid | ( | $ | courseid | ) | [static] |
Given one course id, return one array with all the block intances that belong to it
Definition at line 56 of file backup_plan_dbops.class.php.


| static get_blockids_from_moduleid | ( | $ | moduleid | ) | [static] |
Given one course module id, return one array with all the block intances that belong to it
Definition at line 38 of file backup_plan_dbops.class.php.


| static get_courseformat_from_courseid | ( | $ | courseid | ) | [static] |
Given one course id, return its format in DB
Definition at line 125 of file backup_plan_dbops.class.php.

| static get_default_backup_filename | ( | $ | format, |
| $ | type, | ||
| $ | id, | ||
| $ | users, | ||
| $ | anonymised, | ||
| $ | useidasname = false |
||
| ) | [static] |
Returns the default backup filename, based in passed params.
Default format is (see MDL-22145) backup word - format - type - name - date - info . mbz where name is variable (course shortname, section name/id, activity modulename + cmid) and info can be (nu = no user info, an = anonymized). The last param $useidasname, defaulting to false, allows to replace the course shortname by the course id (used by automated backups, to avoid non-ascii chars in OS filesystem)
| string | $format | One of backup::FORMAT_ |
| string | $type | One of backup::TYPE_ |
| int | $courseid,/$sectionid/$cmid | |
| bool | $users | Should be true is users were included in the backup |
| bool | $anonymised | Should be true is user information was anonymized. |
| bool | $useidasname | true to use id, false to use strings (default) |
Definition at line 203 of file backup_plan_dbops.class.php.


| static get_mnet_localhost_wwwroot | ( | ) | [static] |
Return the wwwroot of the $CFG->mnet_localhost_id host caching it along the request
Definition at line 174 of file backup_plan_dbops.class.php.

| static get_modules_from_sectionid | ( | $ | sectionid | ) | [static] |
Given one section id, return one array with all the course modules that belong to it
Definition at line 74 of file backup_plan_dbops.class.php.

| static get_sections_from_courseid | ( | $ | courseid | ) | [static] |
Given one course id, return one array with all the course_sections belonging to it
Definition at line 110 of file backup_plan_dbops.class.php.

| static get_theme_from_courseid | ( | $ | courseid | ) | [static] |
Given a course id, returns its theme. This can either be the course theme or (if not specified in course) the category, site theme.
User, session, and inherited-from-mnet themes cannot have backed-up per course data. This is course-related data so it must be in a course theme specified as part of the course structure
| int | $courseid |
Definition at line 142 of file backup_plan_dbops.class.php.

| static require_gradebook_backup | ( | $ | courseid, |
| $ | backupid | ||
| ) | [static] |
Returns a flag indicating the need to backup gradebook elements like calculated grade items and category visibility If all activity related grade items are being backed up we can also backup calculated grade items and categories
Definition at line 257 of file backup_plan_dbops.class.php.
