abe0b393525b4e0b7805d6807a8f64333d0b1bc6
[moodle.git] / question / behaviour / upgrade.txt
1 This files describes API changes for question behaviour plugins.
3 === 2.3 ===
5 * This plugin type now supports cron in the standard way. If required, Create a
6   lib.php file containing
7 function qbehaviour_mypluginname_cron() {};
9 === 2.2 ===
11 1) The old
12     public static function get_required_behaviours()
13 method is no more. Instead use the ->dependencies facility in version.php. E.g.
14 $plugin->dependencies = array(
15     'qbehaviour_immediatefeedback' => 2011102700,
16     'qbehaviour_deferredcbm'       => 2011102700
17 );
19 2) The old required_question_definition_type method has been replaced by a new
20 is_compatible_question method. You should change your behaviour to override the
21 new method, not the old one. This change has been implemented in a
22 backwards-compatible way, so behaviours will not break.