WorkspaceManager's findAllWorkspaceNames() just stream names
Somewhere in the forum I found an example on how to get workspace names of a process area and tried to use it like this:
However the findAllWorkspaceNames methods just returns the stream names of the process area. When I trie a different approch using workspace search like the following I get no workspace handles back like I would imagine:
The resulting List is empty. I tried with RTC 3.0.1 plainjava API. Can anybody tell me what I am doing wrong or if there is a bug with the API? Or can anybody point me to some documentation to get further information on this? Thank you in advance, - Oliver - |
3 answers
Geoffrey Clemm (30.1k●3●30●35)
| answered Aug 04 '11, 12:21 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Workspaces are owned by users, not by project or team areas.
Cheers, Geoff On 8/3/2011 10:53 AM, odrees wrote: Somewhere in the forum I found an example on how to get workspace |
I see my misunderstanding regarding users and project areas.
But why does Set workspacesSet = wm.findAllWorkspaceNames(processArea, new gives me the names of the streams and not of the workspaces as the method name says? Is this a bug? I tried to get all worspace names and wanted to open workspace connections for them to get further information of each workspace. As far as I now understand I have to create a search criteria for the kind workspaces. With that I get back WorkspaceHandles with all workspaces in the repository. With them I can get IWorkspaceConnection objects to work with further. However I do not see how I can decide on if a workspace belongs to the project area I want to look at. Is there a way to get the name of the project area from the work space handle? Best Regards, - Oliver - |
Geoffrey Clemm (30.1k●3●30●35)
| answered Aug 05 '11, 10:06 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
I'm not fluent in the actual API calls, but I can provide some
conceptual guidance. Under the hood, streams and workspaces have a shared implementation. This sometimes shows through in the API, where "workspace" means "workspace or stream". So that probably is the case for the findAllWorkspaceNames, and since streams belong to a process area while workspaces do not, that would explain why you are only getting streams back from your query. WRT finding out the process area of a stream (as a reminder, a repository workspace does not belong to a process area), I'll have to defer that to an API expert. One possibility would be to look at the owner field. Cheers, Geoff On 8/5/2011 7:08 AM, odrees wrote: I see my misunderstanding regarding users and project areas. |
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.