aclObjectGetGroups
Client-side
Server-side
Shared
Syntax
table aclObjectGetGroups ( string theObject )
Required Arguments
- theObject: The name of the ACL entry to get groups of.
Returns
- table: groups list
Returns a table of all groups the object is in on success, false if something went wrong.
Code Examples
server
This example outputs a list of all groups of the calling user.
addCommandHandler("listGroups", function(player) local account = getPlayerAccount(player) if (not account or isGuestAccount(account)) then return end
outputChatBox('Groups:', player) local groups = aclObjectGetGroups('user.'..getAccountName(account))
for _,v in ipairs(groups) do outputChatBox('* '..aclGroupGetName(v), player) endend)
See Also
ACL Functions
- aclCreate
- aclCreateGroup
- aclDestroyGroup
- aclDestroy
- aclGet
- aclGetName
- aclGetGroup
- aclGetRight
- aclGroupAddACL
- aclGroupAddObject
- aclGroupGetName
- aclGroupList
- aclGroupListACL
- aclGroupListObjects
- aclGroupRemoveACL
- aclGroupRemoveObject
- aclList
- aclListRights
- aclReload
- aclRemoveRight
- aclObjectGetGroups
- aclSave
- hasObjectPermissionTo
- aclSetRight
- isObjectInACLGroup