0 votes
in PDMLink by (user.hidden) (690 points)

1 Answer

0 votes
by (user.hidden) (690 points)
public static ArrayList<WTPrincipalReference> getParticipantsForRole(String role, wt.inf.team.ContainerTeam containerTeam) {
ArrayList<WTPrincipalReference> principalObj = new ArrayList<WTPrincipalReference>();
try {
Role rolePM = wt.project.Role.toRole(role);
ArrayList principalRef = containerTeam.getAllPrincipalsForTarget(rolePM);
if (!principalRef.isEmpty()) {
Iterator roleArrIterator = principalRef.iterator();
while (roleArrIterator.hasNext()) {
wt.org.WTPrincipalReference wtPrincipalRef = (wt.org.WTPrincipalReference) roleArrIterator.next();
principalObj.add(wtPrincipalRef);
}
}
} catch (Exception ex) {
log.debug("Error while executing the getParticipantForRole() : " + ex.toString());
}
return principalObj;
}

 

Welcome to Windchill Guru, where you can ask questions and receive answers from other members of the community. I recommend everyone to Register

Categories

...