Public Member Functions | |
| __construct ($guid=null) | |
| Construct a new group entity, optionally from a given guid value. | |
| addObjectToGroup (ElggObject $object) | |
| Add an ElggObject to this group. | |
| removeObjectFromGroup ($guid) | |
| Remove an object from the containing group. | |
| get ($name) | |
| Returns an attribute or metadata. | |
| addFriend ($friend_guid) | |
| Start friendable compatibility block: | |
| removeFriend ($friend_guid) | |
| For compatibility with Friendable. | |
| isFriend () | |
| For compatibility with Friendable. | |
| isFriendsWith ($user_guid) | |
| For compatibility with Friendable. | |
| isFriendOf ($user_guid) | |
| For compatibility with Friendable. | |
| getFriends ($subtype="", $limit=10, $offset=0) | |
| For compatibility with Friendable. | |
| getFriendsOf ($subtype="", $limit=10, $offset=0) | |
| For compatibility with Friendable. | |
| getObjects ($subtype="", $limit=10, $offset=0) | |
| Get objects contained in this group. | |
| getFriendsObjects ($subtype="", $limit=10, $offset=0) | |
| For compatibility with Friendable. | |
| countObjects ($subtype="") | |
| For compatibility with Friendable. | |
| getMembers ($limit=10, $offset=0, $count=false) | |
| End friendable compatibility block. | |
| isPublicMembership () | |
| Returns whether the current group is public membership or not. | |
| isMember ($user=null) | |
| Return whether a given user is a member of this group or not. | |
| join (ElggUser $user) | |
| Join an elgg user to this group. | |
| leave (ElggUser $user) | |
| Remove a user from the group. | |
| save () | |
| Override the save function. | |
| getExportableValues () | |
| Return an array of fields which can be exported. | |
| canComment ($user_guid=0) | |
| Can a user comment on this group? | |
Protected Member Functions | |
| initializeAttributes () | |
| Sets the type to group. | |
| load ($guid) | |
| Load the ElggGroup data from the database. | |
Definition at line 12 of file ElggGroup.php.
| ElggGroup::__construct | ( | $ | guid = null |
) |
Construct a new group entity, optionally from a given guid value.
| mixed | $guid If an int, load that GUID. If an entity table db row, then will load the rest of the data. |
| IOException|InvalidParameterException | if there was a problem creating the group. |
Definition at line 37 of file ElggGroup.php.
| ElggGroup::addFriend | ( | $ | friend_guid | ) |
Start friendable compatibility block:
public function addFriend($friend_guid); public function removeFriend($friend_guid); public function isFriend(); public function isFriendsWith($user_guid); public function isFriendOf($user_guid); public function getFriends($subtype = "", $limit = 10, $offset = 0); public function getFriendsOf($subtype = "", $limit = 10, $offset = 0); public function getObjects($subtype="", $limit = 10, $offset = 0); public function getFriendsObjects($subtype = "", $limit = 10, $offset = 0); public function countObjects($subtype = ""); For compatibility with Friendable.
Join a group when you friend ElggGroup.
| int | $friend_guid The GUID of the user joining the group. |
Implements Friendable.
Definition at line 134 of file ElggGroup.php.
| ElggGroup::addObjectToGroup | ( | ElggObject $ | object | ) |
Add an ElggObject to this group.
| ElggObject | $object The object. |
Definition at line 79 of file ElggGroup.php.
| ElggGroup::canComment | ( | $ | user_guid = 0 |
) |
Can a user comment on this group?
| int | $user_guid User guid (default is logged in user) |
Reimplemented from ElggEntity.
Definition at line 381 of file ElggGroup.php.
| ElggGroup::countObjects | ( | $ | subtype = "" |
) |
For compatibility with Friendable.
| string | $subtype Subtype of entities |
Implements Friendable.
Definition at line 245 of file ElggGroup.php.
| ElggGroup::get | ( | $ | name | ) |
Returns an attribute or metadata.
| string | $name Name |
Reimplemented from ElggEntity.
Definition at line 103 of file ElggGroup.php.
| ElggGroup::getExportableValues | ( | ) |
Return an array of fields which can be exported.
Reimplemented from ElggEntity.
Definition at line 365 of file ElggGroup.php.
| ElggGroup::getFriends | ( | $ | subtype = "", |
|
| $ | limit = 10, |
|||
| $ | offset = 0 | |||
| ) |
For compatibility with Friendable.
| string | $subtype The GUID of a user to check. | |
| int | $limit Limit | |
| int | $offset Offset |
Implements Friendable.
Definition at line 193 of file ElggGroup.php.
| ElggGroup::getFriendsObjects | ( | $ | subtype = "", |
|
| $ | limit = 10, |
|||
| $ | offset = 0 | |||
| ) |
For compatibility with Friendable.
| string | $subtype Entity subtype | |
| int | $limit Limit | |
| int | $offset Offset |
Implements Friendable.
Definition at line 233 of file ElggGroup.php.
| ElggGroup::getFriendsOf | ( | $ | subtype = "", |
|
| $ | limit = 10, |
|||
| $ | offset = 0 | |||
| ) |
For compatibility with Friendable.
| string | $subtype The GUID of a user to check. | |
| int | $limit Limit | |
| int | $offset Offset |
Implements Friendable.
Definition at line 206 of file ElggGroup.php.
| ElggGroup::getMembers | ( | $ | limit = 10, |
|
| $ | offset = 0, |
|||
| $ | count = false | |||
| ) |
End friendable compatibility block.
Get a list of group members.
| int | $limit Limit | |
| int | $offset Offset | |
| bool | $count Count |
Definition at line 263 of file ElggGroup.php.
| ElggGroup::getObjects | ( | $ | subtype = "", |
|
| $ | limit = 10, |
|||
| $ | offset = 0 | |||
| ) |
Get objects contained in this group.
| string | $subtype Entity subtype | |
| int | $limit Limit | |
| int | $offset Offset |
Implements Friendable.
Definition at line 219 of file ElggGroup.php.
| ElggGroup::initializeAttributes | ( | ) | [protected] |
Sets the type to group.
Reimplemented from ElggEntity.
Definition at line 20 of file ElggGroup.php.
| ElggGroup::isFriend | ( | ) |
For compatibility with Friendable.
Friending a group adds you as a member
Implements Friendable.
Definition at line 158 of file ElggGroup.php.
| ElggGroup::isFriendOf | ( | $ | user_guid | ) |
For compatibility with Friendable.
| int | $user_guid The GUID of a user to check. |
Implements Friendable.
Definition at line 180 of file ElggGroup.php.
| ElggGroup::isFriendsWith | ( | $ | user_guid | ) |
For compatibility with Friendable.
| int | $user_guid The GUID of a user to check. |
Implements Friendable.
Definition at line 169 of file ElggGroup.php.
| ElggGroup::isMember | ( | $ | user = null |
) |
Return whether a given user is a member of this group or not.
| ElggUser | $user The user |
Definition at line 287 of file ElggGroup.php.
| ElggGroup::isPublicMembership | ( | ) |
Returns whether the current group is public membership or not.
Definition at line 272 of file ElggGroup.php.
| ElggGroup::join | ( | ElggUser $ | user | ) |
Join an elgg user to this group.
| ElggUser | $user User |
Definition at line 304 of file ElggGroup.php.
| ElggGroup::leave | ( | ElggUser $ | user | ) |
Remove a user from the group.
| ElggUser | $user User |
Definition at line 315 of file ElggGroup.php.
| ElggGroup::load | ( | $ | guid | ) | [protected] |
Load the ElggGroup data from the database.
| mixed | $guid GUID of an ElggGroup entity or database row from entity table |
Reimplemented from ElggEntity.
Definition at line 326 of file ElggGroup.php.
| ElggGroup::removeFriend | ( | $ | friend_guid | ) |
For compatibility with Friendable.
Leave group when you unfriend ElggGroup.
| int | $friend_guid The GUID of the user leaving. |
Implements Friendable.
Definition at line 147 of file ElggGroup.php.
| ElggGroup::removeObjectFromGroup | ( | $ | guid | ) |
Remove an object from the containing group.
| int | $guid The guid of the object. |
Definition at line 90 of file ElggGroup.php.
| ElggGroup::save | ( | ) |
Override the save function.
Reimplemented from ElggEntity.
Definition at line 348 of file ElggGroup.php.
1.6.3