Conform the new interface requirments
authorDavid Mudrak <david.mudrak@gmail.com>
Mon, 4 Jan 2010 18:07:07 +0000 (18:07 +0000)
committerDavid Mudrak <david.mudrak@gmail.com>
Mon, 4 Jan 2010 18:07:07 +0000 (18:07 +0000)
mod/workshop/form/accumulative/lib.php

index 47466593347577347b5391072ab20372008c2e26..98a40914c176eb3286f72089aad617b43d165621 100644 (file)
@@ -239,6 +239,22 @@ class workshop_accumulative_strategy implements workshop_strategy {
         return false;
     }
 
+    /**
+     * Returns true if the given evaluation method is supported by this strategy
+     *
+     * To support an evaluation method, the strategy subplugin must usually implement some
+     * required public methods. In theory, this is what interfaces should be used for.
+     * Unfortunatelly, we can't extend "implements" declaration as the interface must
+     * be known to the PHP interpret. So we can't declare implementation of a non-installed
+     * evaluation subplugin.
+     *
+     * @param workshop_evaluation $evaluation the instance of grading evaluation class
+     * @return bool true if the evaluation method is supported, false otherwise
+     */
+    public function evaluation_supported(workshop_evaluation $evaluation) {
+        return false;   // todo does not support any evaluation yet
+    }
+
 ////////////////////////////////////////////////////////////////////////////////
 // Internal methods                                                           //
 ////////////////////////////////////////////////////////////////////////////////