Search in sources :

Example 1 with GcAddMember

use of edu.internet2.middleware.grouperClient.api.GcAddMember in project uPortal by Jasig.

the class GrouperEntityGroupStore method updateMembers.

/** @see IEntityGroupStore#updateMembers(IEntityGroup) */
public void updateMembers(IEntityGroup group) throws GroupsException {
    // assume key is fully qualified group name
    String groupName = group.getLocalKey();
    GcAddMember gcAddMember = new GcAddMember().assignGroupName(groupName);
    for (IGroupMember iGroupMember : group.getChildren()) {
        EntityIdentifier entityIdentifier = iGroupMember.getEntityIdentifier();
        String identifier = entityIdentifier.getKey();
        gcAddMember.addSubjectIdentifier(identifier);
    }
    gcAddMember.execute();
}
Also used : IGroupMember(org.apereo.portal.groups.IGroupMember) EntityIdentifier(org.apereo.portal.EntityIdentifier) GcAddMember(edu.internet2.middleware.grouperClient.api.GcAddMember)

Aggregations

GcAddMember (edu.internet2.middleware.grouperClient.api.GcAddMember)1 EntityIdentifier (org.apereo.portal.EntityIdentifier)1 IGroupMember (org.apereo.portal.groups.IGroupMember)1