PHP Interface Loggable, Elgg

This interface defines a set of methods that permit the system log functions to hook in and retrieve the necessary information and to identify what events can actually be logged. To have events involving your object to be logged simply implement this interface.
Mostrar archivo Open project: elgg/elgg Interface Usage Examples

Public Methods

Method Description
getObjectFromID ( integer $id ) : ElggEntity For a given ID, return the object associated with it.
getSubtype ( ) : string Return a subtype. For metadata & annotations this is the 'name' and for relationship this is the relationship type.
getSystemLogID ( ) : integer Return an identification for the object for storage in the system log.
getType ( ) : string Return the type of the object - eg. object, group, user, relationship, metadata, annotation etc

Method Details

getObjectFromID() public method

This is used by the river functionality primarily. This is useful for checking access permissions etc on objects.
public getObjectFromID ( integer $id ) : ElggEntity
$id integer GUID of an entity
return ElggEntity

getSubtype() public method

Return a subtype. For metadata & annotations this is the 'name' and for relationship this is the relationship type.
public getSubtype ( ) : string
return string

getSystemLogID() public method

This id must be an integer.
public getSystemLogID ( ) : integer
return integer

getType() public method

Return the type of the object - eg. object, group, user, relationship, metadata, annotation etc
public getType ( ) : string
return string