Méthode | Description | |
---|---|---|
addFriend ( integer $friend_guid ) : boolean | Adds a user as a friend | |
getFriends ( array $options = [] ) : array | false | Gets this entity's friends | |
getFriendsObjects ( array $options = [] ) : array | false | Get an array of \ElggObjects owned by this entity's friends. | |
getFriendsOf ( array $options = [] ) : array | false | Gets users who have made this entity a friend | |
getObjects ( array $options = [] ) : array | false | Get an array of \ElggObject owned by this entity. | |
isFriend ( ) : boolean | Determines whether or not the current user is a friend of this entity | |
isFriendOf ( integer $user_guid ) : boolean | Determines whether or not a foreign entity has made this one a friend | |
isFriendsWith ( integer $user_guid ) : boolean | Determines whether or not this entity is friends with a particular entity | |
removeFriend ( integer $friend_guid ) : boolean | Removes a user as a friend |
public getFriends ( array $options = [] ) : array | false | ||
$options | array | Options array. See elgg_get_entities_from_relationship() for a list of options. 'relationship_guid' is set to this entity, relationship name to 'friend' and type to 'user'. |
Résultat | array | false | Array of \ElggUser, or false, depending on success |
public getFriendsObjects ( array $options = [] ) : array | false | ||
$options | array | Options array. See elgg_get_entities_from_relationship() for a list of options. 'relationship_guid' is set to this entity, type to 'object', relationship name to 'friend' and relationship_join_on to 'container_guid'. |
Résultat | array | false |
public getFriendsOf ( array $options = [] ) : array | false | ||
$options | array | Options array. See elgg_get_entities_from_relationship() for a list of options. 'relationship_guid' is set to this entity, relationship name to 'friend', type to 'user' and inverse_relationship to true. |
Résultat | array | false | Array of \ElggUser, or false, depending on success |
public getObjects ( array $options = [] ) : array | false | ||
$options | array | Options array. See elgg_get_entities() for a list of options. 'type' is set to object and owner_guid to this entity. |
Résultat | array | false |
public isFriendOf ( integer $user_guid ) : boolean | ||
$user_guid | integer | The GUID of the foreign entity |
Résultat | boolean |
public isFriendsWith ( integer $user_guid ) : boolean | ||
$user_guid | integer | The GUID of the entity this entity may or may not be friends with |
Résultat | boolean |
public removeFriend ( integer $friend_guid ) : boolean | ||
$friend_guid | integer | The GUID of the user to remove |
Résultat | boolean |