How to get the IIterationHandle by Iteration's name?
I want to get the IIterationHandle(target_handle) of the given Iteration(name:ABCDEFG) via list code,But I failed.
Please help me,thank you. |
4 answers
I want to get the IIterationHandle(target_handle) of the given Iteration(name:ABCDEFG) via list code,But I failed. Hi, Is it failing to find the matching iteration or failing with an exception? If it is failing with an exception can you please provide the stack trace? I would suggest using iteration.getLabel() method to fetch the name of the iteration as it automatically handles null value for iteration name. Thanks, Sridevi Jazz Process Team |
Thank you,it's failing to find the matching iteration.
It's only get the currently iteration handle.
|
Jared Burns (4.5k●2●9)
| answered Jun 07 '10, 11:01 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
On Mon, 07 Jun 2010 08:38:06 +0000, codeboy wrote:
I want to get the IIterationHandle(target_handle) of the given There are a couple problems with this code. First, the code that's fetching the items is passing in a bad "flags" parameter to the item manager. IDevelopmentLine.DEVELOPMENT_LINE and IIteration.ITERATION are type constants. They're not valid parameters to this method. Instead, you should use IItemManager.DEFAULT or IItemManager.REFRESH. Second, the method IDevelopmentLine.getIterations() will only return you the top-level iterations. If you want to traverse the whole hierarchy of iterations in the development line, you'll need to start walking IIteration.getChildren() as well. - Jared --------------------- Jazz Team Process |
Thank you very much.It's OK.
On Mon, 07 Jun 2010 08:38:06 +0000, codeboy wrote: I want to get the IIterationHandle(target_handle) of the given There are a couple problems with this code. First, the code that's fetching the items is passing in a bad "flags" parameter to the item manager. IDevelopmentLine.DEVELOPMENT_LINE and IIteration.ITERATION are type constants. They're not valid parameters to this method. Instead, you should use IItemManager.DEFAULT or IItemManager.REFRESH. Second, the method IDevelopmentLine.getIterations() will only return you the top-level iterations. If you want to traverse the whole hierarchy of iterations in the development line, you'll need to start walking IIteration.getChildren() as well. - Jared --------------------- Jazz Team Process |
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.