public class StandardGroupMembershipProvider extends AbstractGroupMembershipProvider
Constructor and Description |
---|
StandardGroupMembershipProvider() |
Modifier and Type | Method and Description |
---|---|
void |
addMember(String groupId,
String memberId)
Add a member into a group.
|
protected Collection<CacheItem<Collection<String>>> |
bulkLoadMemberships(ICacheMultiDataProvider.IRequest request)
Bulk load the memberships.
|
void |
deleteGroupMembershipData(String groupId)
Deletes all data stored for managing the membership of a group.
|
void |
destroy()
Indicates that this membership provider will no longer be used.
|
Collection<String> |
getGroups(String principalId)
Returns the groups of a principal.
|
Collection<String> |
getMembers(String groupId,
int filterType)
Returns the members of a group.
|
void |
init(GroupType groupType)
Initializes this membership provider to be used for the given group type.
|
void |
removeMember(String groupId,
String memberId)
Remove a member from a group.
|
deleteGroupTypeMembershipData, getGroupConfigurationInterfaceId, getGroupType, getGroupTypeConfigurationInterfaceId
protected Collection<CacheItem<Collection<String>>> bulkLoadMemberships(ICacheMultiDataProvider.IRequest request) throws PortalException
request
- the cache request.PortalException
public void init(GroupType groupType)
IGroupMembershipProvider
This method is the first method called after an instance creation.
init
in interface IGroupMembershipProvider
init
in class AbstractGroupMembershipProvider
groupType
- the group type.public void destroy()
IGroupMembershipProvider
This method may be used to clean up resources allocated in this instance. This instance is no longer used after this method is called.
destroy
in interface IGroupMembershipProvider
destroy
in class AbstractGroupMembershipProvider
public void addMember(String groupId, String memberId) throws PortalException
IGroupMembershipProvider
addMember
in interface IGroupMembershipProvider
addMember
in class AbstractGroupMembershipProvider
groupId
- the group identifier.memberId
- the member identifier.PortalException
public void removeMember(String groupId, String memberId) throws PortalException
IGroupMembershipProvider
removeMember
in interface IGroupMembershipProvider
removeMember
in class AbstractGroupMembershipProvider
groupId
- the group identifier.memberId
- the member identifier.PortalException
public Collection<String> getGroups(String principalId) throws PortalException
IGroupMembershipProvider
principalId
- the principal identifier.PortalException
public Collection<String> getMembers(String groupId, int filterType) throws PortalException
IGroupMembershipProvider
groupId
- the group identifier.filterType
- defines how the result will be filtered.
This may be one of IGroupManager.FILTER_TYPE_USERS_AND_GROUPS
,
IGroupManager.FILTER_TYPE_ONLY_USERS
or
IGroupManager.FILTER_TYPE_ONLY_GROUPS
.PortalException
public void deleteGroupMembershipData(String groupId) throws PortalException
IGroupMembershipProvider
This allows this provider to cleanup membership, configuration or other data that it stores for managing a group membership.
This deletion process order is illustrated in the following diagram:
deleteGroupMembershipData
in interface IGroupMembershipProvider
deleteGroupMembershipData
in class AbstractGroupMembershipProvider
groupId
- the group identifier.PortalException
LumisXP 12.3.0.200408 - Copyright © 2006–2020 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.