aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/relationships.php
diff options
context:
space:
mode:
Diffstat (limited to 'engine/lib/relationships.php')
-rw-r--r--engine/lib/relationships.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/engine/lib/relationships.php b/engine/lib/relationships.php
index 5b9627860..ba6f0182f 100644
--- a/engine/lib/relationships.php
+++ b/engine/lib/relationships.php
@@ -184,6 +184,13 @@
*/
public function getClassName() { return get_class($this); }
+ /**
+ * For a given ID, return the object associated with it.
+ * This is used by the river functionality primarily.
+ * This is useful for checking access permissions etc on objects.
+ */
+ public function getObjectFromID($id) { return get_relationship($id); }
+
// ITERATOR INTERFACE //////////////////////////////////////////////////////////////
/*
* This lets an entity's attributes be displayed using foreach as a normal array.