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.

Provides support for the conversion of moodle1 backup to the moodle2 format

Copyright: 2011 David Mudrak <david@moodle.com>
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 159 lines (6 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

moodle1_mod_glossary_handler:: (6 methods):
  get_paths()
  process_glossary()
  on_glossary_categories_start()
  process_glossary_category()
  on_glossary_categories_end()
  on_glossary_end()


Class: moodle1_mod_glossary_handler  - X-Ref

Glossary conversion handler

get_paths()   X-Ref
Declare the paths in moodle.xml we are able to convert

The method returns list of {@link convert_path} instances.
For each path returned, the corresponding conversion method must be
defined.

Note that the path /MOODLE_BACKUP/COURSE/MODULES/MOD/GLOSSARY does not
actually exist in the file. The last element with the module name was
appended by the moodle1_converter class.

return: array of {@link convert_path} instances

process_glossary($data)   X-Ref
This is executed every time we have one /MOODLE_BACKUP/COURSE/MODULES/MOD/GLOSSARY
data available


on_glossary_categories_start()   X-Ref
This is executed when the parser reaches the <CATEGORIES> opening element


process_glossary_category($data)   X-Ref
This is executed every time we have one /MOODLE_BACKUP/COURSE/MODULES/MOD/GLOSSARY/CATEGORIES/CATEGORY
data available


on_glossary_categories_end()   X-Ref
This is executed when the parser reaches the closing </CATEGORIES> element


on_glossary_end()   X-Ref
This is executed when we reach the closing </MOD> tag of our 'glossary' path