It's all about the answers!

Ask a question

iRole and itemType


Andrew Salmela (813) | asked Sep 23 '14, 9:26 a.m.
edited Sep 23 '14, 10:27 a.m. by Ralph Schoon (55.1k23642)
 I am trying to retrieve the itemType of a RTC role but I not able to determine how to find it.  Here are the attributes I able to find.  How can I get the itemType of the IRole using the java api?

IRole[] projectAreaProcessRoleCollection = clientProcess.getRoles(projArea, null);
for (IRole iRole : projectAreaProcessRoleCollection)
{
IRole2 role2 = (IRole2) iRole;
                        String id = role2.getId();
                        String name = role2.getRoleName();
                        String label = role2.getRoleLabel();
                        String desc = role2.getDescription();
                }

Comments
Ralph Schoon commented Sep 23 '14, 10:28 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

For what purpose would you want to get the IItemType? What do you want to do?


Andrew Salmela commented Sep 23 '14, 11:16 a.m.

We are creating a solution to programmaticly administer RTC to create projects, manage user, manage roles, etc. to reduce administration needs and streamline with our company processes and policies.  According to a post by Nick it is best to store both the UUID and itemType.


In order to cover all bases and prepare for future requirements I would like to access the itemType for Roles.  I am able to access the itemType by simply calling getItemType() for Users, ProjectAreas and ProcessDefinitions but I cannot find a similar method for Roles.

Accepted answer


permanent link
Ralph Schoon (55.1k23642) | answered Sep 23 '14, 11:37 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
As far as I can see from looking into the SDK IRole and IRole2 are no interfaces that implement IItem. Therefore I assume you won't be able to get that information. I would suggest to store the identifier, name etc from IRole and IRole2 instead.
Andrew Salmela selected this answer as the correct answer

Your answer


Register or to post your answer.