메소드 |
설명 |
|
__clone ( ) : void |
Clone an entity |
|
__get ( string $name ) : mixed |
Get an attribute or metadata value |
|
__set ( string $name, mixed $value ) : void |
Set an attribute or metadata value for this entity |
|
__unset ( string $name ) : void |
Unset a property from metadata or attribute. |
|
addRelationship ( integer $guid_two, string $relationship ) : boolean |
Add a relationship between this an another entity. |
|
annotate ( string $name, mixed $value, integer $access_id = ACCESS_PRIVATE, integer $owner_guid, string $vartype = "" ) : boolean | integer |
Adds an annotation to an entity. |
|
canAnnotate ( integer $user_guid, string $annotation_name = '' ) : boolean |
Can a user annotate an entity? |
|
canComment ( integer $user_guid, boolean $default = null ) : boolean |
Can a user comment on an entity? |
|
canDelete ( integer $user_guid ) : boolean |
Can a user delete this entity? |
|
canEdit ( integer $user_guid ) : boolean |
Can a user edit this entity? |
|
canEditMetadata ( ElggMetadata $metadata = null, integer $user_guid ) : boolean |
Can a user edit metadata on this entity? |
|
canWriteToContainer ( integer $user_guid, string $type = 'all', string $subtype = 'all' ) : boolean |
Can a user add an entity to this container |
|
countAnnotations ( string $name = "" ) : integer |
Count annotations. |
|
countComments ( ) : integer |
Count the number of comments attached to this entity. |
|
countEntitiesFromRelationship ( string $relationship, boolean $inverse_relationship = false ) : integer | false |
Gets the number of entities from a specific relationship type |
|
delete ( boolean $recursive = true ) : boolean |
Deletes the entity. |
|
deleteAccessCollectionMemberships ( ) : boolean |
Remove the membership of all access collections for this entity (if the entity is a user) |
|
deleteAnnotations ( null | string $name = null ) : boolean |
Deletes all annotations on this object (annotations.entity_guid = $this->guid). |
|
deleteIcon ( string $type = 'icon' ) : boolean |
Removes all icon files and metadata for the passed type of icon. |
|
deleteMetadata ( null | string $name = null ) : boolean |
Deletes all metadata on this object (metadata.entity_guid = $this->guid). |
|
deleteOwnedAccessCollections ( ) : boolean |
Remove all access collections owned by this entity |
|
deleteOwnedAnnotations ( null | string $name = null ) : boolean |
Deletes all annotations owned by this object (annotations.owner_guid = $this->guid). |
|
deleteOwnedMetadata ( null | string $name = null ) : boolean |
Deletes all metadata owned by this object (metadata.owner_guid = $this->guid). |
|
deleteRelationships ( null | string $relationship = null ) : boolean |
Remove all relationships to and from this entity. |
|
disable ( string $reason = "", boolean $recursive = true ) : boolean |
Disable this entity. |
|
disableAnnotations ( string $name = '' ) : boolean |
Disables annotations for this entity, optionally based on name. |
|
disableMetadata ( string $name = '' ) : boolean |
Disables metadata for this entity, optionally based on name. |
|
enable ( boolean $recursive = true ) : boolean |
Enable the entity |
|
enableAnnotations ( string $name = '' ) : boolean |
Enables annotations for this entity, optionally based on name. |
|
enableMetadata ( string $name = '' ) : boolean |
Enables metadata for this entity, optionally based on name. |
|
getAccessID ( ) : integer |
Returns the access_id. |
|
getAnnotations ( array $options = [] ) : array |
Gets an array of annotations. |
|
getAnnotationsAvg ( string $name ) : integer |
Get the average of an integer type annotation. |
|
getAnnotationsMax ( string $name ) : integer |
Get the maximum of integer type annotations of a given name. |
|
getAnnotationsMin ( string $name ) : integer |
Get the minimum of integer type annotations of given name. |
|
getAnnotationsSum ( string $name ) : integer |
Get the sum of integer type annotations of a given name. |
|
getContainerEntity ( ) : ElggEntity |
Get the container entity for this object. |
|
getContainerGUID ( ) : integer |
Gets the container GUID for this entity. |
|
getDisplayName ( ) : string |
Get the entity's display name |
|
getEntitiesFromRelationship ( array $options = [] ) : array | false |
Gets an array of entities with a relationship to this entity. |
|
getGUID ( ) : integer | null |
Returns the guid. |
|
getIcon ( string $size, string $type = 'icon' ) : ElggIcon |
Returns entity icon as an ElggIcon object
The icon file may or may not exist on filestore |
|
getIconLastChange ( string $size, string $type = 'icon' ) : integer | null |
Returns the timestamp of when the icon was changed. |
|
getIconURL ( mixed $params = [] ) : string |
Get the URL for this entity's icon |
|
getLatitude ( ) : float |
Return the entity's latitude. |
|
getLocation ( ) : string |
Gets the 'location' metadata for the entity |
|
getLongitude ( ) : float |
Return the entity's longitude |
|
getMetadata ( string $name ) : mixed |
Return the value of a piece of metadata. |
|
getObjectFromID ( integer $id ) : integer |
For a given ID, return the object associated with it. |
|
getOriginalAttributes ( ) : array |
Get the original values of attribute(s) that have been modified since the entity was persisted. |
|
getOwnerEntity ( ) : ElggEntity |
Gets the \ElggEntity that owns this entity. |
|
getOwnerGUID ( ) : integer |
Get the guid of the entity's owner. |
|
getPrivateSetting ( string $name ) : mixed |
Returns a private setting value |
|
getSubtype ( ) : string |
Get the entity subtype |
|
getSystemLogID ( ) : integer |
Return an identification for the object for storage in the system log. |
|
getTags ( array $tag_names = null ) : array |
Returns tags for this entity. |
|
getTimeUpdated ( ) : integer |
Returns the UNIX epoch time that this entity was last updated |
|
getType ( ) : string |
Returns the entity type |
|
getURL ( ) : string |
Gets the URL for this entity. |
|
getVolatileData ( string $name ) : mixed |
Get a piece of volatile (non-persisted) data on this entity. |
|
hasIcon ( string $size, string $type = 'icon' ) : boolean |
Returns if the entity has an icon of the passed type. |
|
isEnabled ( ) : boolean |
Is this entity enabled? |
|
isFullyLoaded ( ) : boolean |
Tests to see whether the object has been persisted. |
|
refresh ( stdClass $row ) : boolean |
Load new data from database into existing entity. Overwrites data but
does not change values not included in the latest data. |
|
removePrivateSetting ( string $name ) : boolean |
Removes private setting |
|
removeRelationship ( integer $guid_two, string $relationship ) : boolean |
Remove a relationship |
|
save ( ) : boolean | integer |
Save an entity. |
|
saveIconFromElggFile ( ElggFile $file, string $type = 'icon', array $coords = [] ) : boolean |
Saves icons using a file located in the data store as the source. |
|
saveIconFromLocalFile ( string $filename, string $type = 'icon', array $coords = [] ) : boolean |
Saves icons using a local file as the source. |
|
saveIconFromUploadedFile ( string $input_name, string $type = 'icon', array $coords = [] ) : boolean |
Saves icons using an uploaded file as the source. |
|
setContainerGUID ( integer $container_guid ) : boolean |
Set the container for this object. |
|
setDisplayName ( string $displayName ) : void |
Sets the title or name of this entity. |
|
setLatLong ( float $lat, float $long ) : void |
Set latitude and longitude metadata tags for a given entity. |
|
setLocation ( string $location ) : void |
Sets the 'location' metadata for the entity |
|
setMetadata ( string $name, mixed $value, string $value_type = '', boolean $multiple = false, integer $owner_guid, integer $access_id = null ) : boolean |
Set metadata on this entity. |
|
setPrivateSetting ( string $name, mixed $value ) : boolean |
Adds a private setting to this entity. |
|
setVolatileData ( string $name, mixed $value ) : void |
Set a piece of volatile (non-persisted) data on this entity |
|
storeInPersistedCache ( ElggSharedMemoryCache $cache, integer $last_action ) : void |
Cache the entity in a persisted cache |
|
toObject ( ) |
|
|
updateLastAction ( integer $posted = null ) : integer | false |
Update the last_action column in the entities table. |
|