Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How to get Team areas List and Process roles list from particular project area using RTC plain java API

 Hi Everyone,


My scenario is that I want to get the list of process roles list and team area list of particular project area using RTC plain java API for that I am referring https://rsjazz.wordpress.com/2012/12/09/analyzing-a-aroject-areas-members-and-roles-using-the-plain-java-client-libraries/
currently I am getting specific project area from RTC
CLM version 6.0.5

Thank You 

0 votes



2 answers

Permanent link

You have the example up there, what more do you want?

See: How should I ask a question in the Forum if I want to receive useful answers?

0 votes


Permanent link

     

public static void teamArea(ITeamRepository repo,
IProjectArea projArea) throws TeamRepositoryException {
List teamAreas = projArea.getTeamAreas();
for (Iterator iterator = teamAreas.iterator(); iterator.hasNext();) {
ITeamAreaHandle handle = (ITeamAreaHandle) iterator.next();
ITeamArea teamArea = (ITeamArea) repo.itemManager()
.fetchCompleteItem(handle, IItemManager.DEFAULT, null);
System.out.println(projArea.getName());
System.out.println(teamArea.getName());

}
}

Using above scenario now I am getting team area also of the specific project area,
I just want to get list of process  roles that are available in particular project area

0 votes

Comments

There is no scenario above, that I can understand. There is a minimal information maximal fuzzy question.

I think the example code you can download from the blog post https://rsjazz.wordpress.com/2012/12/09/analyzing-a-aroject-areas-members-and-roles-using-the-plain-java-client-libraries/ should give you a good idea how to write or change the code to reuse it for your purpose. The downloadable code actually iterates through exactly one project area, if you provide the name. The blog actually explains how the code works to some extend.


 I am writing a code to add users with roles in RTC project area,now users added in project area, but  I want to see how many and which roles are available in RTC project area 

        IClientProcess clientProcess = service.getClientProcess(processArea,
                null);
        IRole[] availableRoles = clientProcess.getRoles(processArea, null);
        for (int i = 0; i < availableRoles.length; i++) {
            if (availableRoles[i].getId().equals(roleID)) {
                return availableRoles[i];
            }
        }

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,939

Question asked: Jul 19 '18, 6:26 a.m.

Question was seen: 3,532 times

Last updated: Jul 23 '18, 4:10 p.m.

Confirmation Cancel Confirm