How to get the corresponding stream of a known workspace?
Hi, now I have the UUID of the build workspace, how can I get its flow target stream?
|
One answer
First, you have to retrieve the IWorkspace object for the build workspace from the UUID param:
UUID uuid = ...
Then, you can retrieve the flows from that workspace:
List<FlowEntry> flows = ((Workspace) wks).getFlows();
Notice you have to cast the IWorkspace object to a Workspace object to invoke the getFlows() method.
Finally, you will have to filter that list to get only the deliver targets:
if ((flow.getFlags() & FlowFlags.DELIVER) != 0) {
Cheers.
Comments
Stephen Lai
commented May 20 '15, 4:55 a.m.
Thanks a lot for your solution, it works properly for me! |
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.