how to solve ImmutablePropertyException exception on setting setCurrentIteration
Hello team
|
Accepted answer
Ralph Schoon (63.4k●3●36●46)
| answered Mar 10 '17, 2:57 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER edited Mar 10 '17, 2:57 a.m. Please carefully read Understanding and Using the RTC Java Client API especially the part about working copy. You can not just modify stuff, you usually need a modifiable item (working copy).
From the same blog post read up how to setup the RTC SDK and the plain java client libraries. Use the Eclipse Java Search capability to search for setCurrentIteration and look at how the code is used in the RTC SDK e.g. unit tests.
Example from com.ibm.team.process.internal.client.tests.AbstractTeamProcessTest.setCurrentIteration(IDevelopmentLine, String) to get the workingcopy (called mutable copy in this context)
IProcessItemService service = getProcessItemService(); line = (IDevelopmentLine) service.getMutableCopy(line); line.setCurrentIteration(current); service.save(line, null); vinitha dsouza selected this answer as the correct answer
Comments
vinitha dsouza
commented Mar 10 '17, 3:27 a.m.
Thank You for the reply :)
The point of my reply was what to do and how to get at this information. It took me longer to type the response than to search for the API. If you want to continue with this kind of work, you should learn how to find API examples in the SDK.
You had several questions with a similar pattern and you would be able to answer most of your questions if you could do that.
|
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.