]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Refs #2597: Pulled Loggable functions with identical implementations into ElggData
authorewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sat, 30 Oct 2010 23:53:57 +0000 (23:53 +0000)
committerewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sat, 30 Oct 2010 23:53:57 +0000 (23:53 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@7155 36083f99-b078-4883-b0ff-0f9b5a30f544

engine/classes/ElggData.php
engine/classes/ElggEntity.php
engine/classes/ElggExtender.php
engine/classes/ElggRelationship.php

index f200a7c216d5b2fd0145ef7c095f1d72cc96b8c4..a206964faa64c1761a5044de65b6dc2407e410f0 100644 (file)
@@ -1,8 +1,34 @@
 <?php
 abstract class ElggData implements
+       Loggable,       // Can events related to this object class be logged
        Iterator,       // Override foreach behaviour
        ArrayAccess // Override for array access
 {
+       
+       
+       
+       /*
+        *  SYSTEM LOG INTERFACE
+        */
+
+       /**
+        * Return the class name of the object.
+        *
+        * @return string
+        */
+       public function getClassName() {
+               return get_class($this);
+       }
+
+       /**
+        * Return the GUID of the owner of this object.
+        *
+        * @return int
+        */
+       public function getObjectOwnerGUID() {
+               return $this->owner_guid;
+       }
+
        /**
         * The main attributes of an entity.
         * Holds attributes to save to database
index 56ac96f8f53d383e8dcb88bfe3cddb59dc88f837..9b6b048999f5435fa5160ec53f7b44c632d9a2b3 100644 (file)
@@ -30,8 +30,7 @@ abstract class ElggEntity extends ElggData implements
        Notable,    // Calendar interface
        Locatable,  // Geocoding interface
        Exportable, // Allow export of data
-       Importable, // Allow import of data
-       Loggable        // Can events related to this object class be logged
+       Importable // Allow import of data
 {
 
        /**
@@ -1302,15 +1301,6 @@ abstract class ElggEntity extends ElggData implements
                return $this->getGUID();
        }
 
-       /**
-        * Return the class name of the object.
-        *
-        * @return string
-        */
-       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.
@@ -1328,15 +1318,6 @@ abstract class ElggEntity extends ElggData implements
                return get_entity($id);
        }
 
-       /**
-        * Returns the GUID of the owner of this entity.
-        *
-        * @return int Owner guid
-        */
-       public function getObjectOwnerGUID() {
-               return $this->owner_guid;
-       }
-
        /**
         * Returns tags for this entity.
         *
index d6ea14ba8edd5fbd9bc2d537df426aaddb7834fd..ca92dca748b48d84e80709379e947f56badda63b 100644 (file)
@@ -18,8 +18,7 @@
  * @see        ElggMetadata
  */
 abstract class ElggExtender extends ElggData implements
-       Exportable,
-       Loggable        // Can events related to this object class be logged
+       Exportable
 {
        
        /**
@@ -186,24 +185,6 @@ abstract class ElggExtender extends ElggData implements
                return $this->id;
        }
 
-       /**
-        * Return the class name of the object.
-        *
-        * @return string
-        */
-       public function getClassName() {
-               return get_class($this);
-       }
-
-       /**
-        * Return the GUID of the owner of this object.
-        *
-        * @return int
-        */
-       public function getObjectOwnerGUID() {
-               return $this->owner_guid;
-       }
-
        /**
         * Return a type of extension.
         *
index e2b0e4e1321169b59f4543c5c3323663caf32ff2..4dcdb6297bfeb481c8a960b1b445f7486e02bcf0 100644 (file)
@@ -7,8 +7,7 @@
  */
 class ElggRelationship extends ElggData implements
        Importable,
-       Exportable,
-       Loggable        // Can events related to this object class be logged
+       Exportable
 {
 
        /**
@@ -190,15 +189,6 @@ class ElggRelationship extends ElggData implements
                return $this->id;
        }
 
-       /**
-        * Return the class name of the object.
-        *
-        * @return string
-        */
-       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.
@@ -212,15 +202,6 @@ class ElggRelationship extends ElggData implements
                return get_relationship($id);
        }
 
-       /**
-        * Return the GUID of the owner of this object.
-        *
-        * @return int
-        */
-       public function getObjectOwnerGUID() {
-               return $this->owner_guid;
-       }
-
        /**
         * Return a type of the object - eg. object, group, user, relationship, metadata, annotation etc
         *