aboutsummaryrefslogtreecommitdiff
path: root/lib/modules/OERModule.php
diff options
context:
space:
mode:
authorJan-Hendrik Willms <tleilax+github@gmail.com>2021-07-22 16:07:19 +0200
committerJan-Hendrik Willms <tleilax+github@gmail.com>2021-07-22 16:19:12 +0200
commita3da1483a9e689846179159355badfec8073dbec (patch)
tree770dcca6bdf5f6f2a11b0e7fcbbeda6919a3fc52 /lib/modules/OERModule.php
current code from svn, revision 62608
Diffstat (limited to 'lib/modules/OERModule.php')
-rw-r--r--lib/modules/OERModule.php29
1 files changed, 29 insertions, 0 deletions
diff --git a/lib/modules/OERModule.php b/lib/modules/OERModule.php
new file mode 100644
index 0000000..6cc8909
--- /dev/null
+++ b/lib/modules/OERModule.php
@@ -0,0 +1,29 @@
+<?php
+
+interface OERModule
+{
+ /**
+ * Determines if the StudipModule wants to handle the OERMaterial. Returns false if not.
+ * @param OERMaterial $material
+ * @return false|Icon
+ */
+ public static function oerModuleWantsToUseMaterial(OERMaterial $material);
+
+ /**
+ * This function is triggered i a user chose to use this module as the target of the oermaterial.
+ * Now this module should put a copy of $material in its own area of the given course.
+ * @param OERMaterial $material
+ * @param Course $course
+ * @return void
+ */
+ public static function oerModuleIntegrateMaterialToCourse(OERMaterial $material, Course $course);
+
+ /**
+ * Returns an Icon class object with the given role.
+ * @param string $role
+ * @return null|Icon
+ */
+ public function oerGetIcon($role = Icon::ROLE_CLICKABLE);
+
+ public function getMetadata();
+}