How to create access groups programmatically?
Accepted answer
Java Client API code:
IAccessGroupClientService clientService = (IAccessGroupClientService) repo.getClientLibrary(IAccessGroupClientService.class);
IWorkItemCommon workItemCommon = (IWorkItemCommon)repo.getClientLibrary(IWorkItemCommon.class);
accessGroup = (IAccessGroup) workItemCommon.getAuditableCommon().createAuditable(IAccessGroup.ITEM_TYPE);
accessGroup.setName(strAccessGroupName);
//Add at least one IProjectArea, ITeamArea or IContributor
accessGroup.add(projectArea, ReadAccessContextType.MEMBERS);
clientService.save(accessGroup, null);
One other answer
FYI, for more info. about access groups, see Using access groups to control access to artifacts.
Ken
Comments
sam detweiler
Jul 25 '16, 8:27 a.m.sam detweiler
Jul 25 '16, 12:17 p.m.David Lafreniere
FORUM MODERATOR / JAZZ DEVELOPER Jul 25 '16, 12:52 p.m.