It's all about the answers!

Ask a question

ImmutablePropertyException while setting target iteration

Melanie Finke (7731520) | asked Apr 25 '12, 10:33 a.m.

i try to set the target iteration through plain java API. the method.

workItem.setTarget(IIterationHandle i) throws the ImmutablePropertyException. I get the IIterationHandle through this code:

IDevelopmentLine developmentLine = (IDevelopmentLine) getCompleteItem(developmentLineHandle);

for (IIterationHandle iterationHandle : developmentLine
.getIterations()) {

IIteration iteration = (IIteration) getCompleteItem(iterationHandle);

if (resultIteration != null) {

return resultIteration;


The Exception is thrown, when I try to set the target.

The stackTrace is:

Exception in thread "main"
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at $Proxy18.setTarget(Unknown Source)

Does someone know how to get rid of this exeption and set the target?

Accepted answer

permanent link
Michele Pegoraro (1.8k14118103) | answered Apr 26 '12, 5:10 a.m.
I think you have to use a working copy of your work-item in order to set the iteration (as other attributes).

Best regards,
Melanie Finke selected this answer as the correct answer

2 other answers

permanent link
Melanie Finke (7731520) | answered Apr 26 '12, 7:01 a.m.
Thank you, that was the mistake.


permanent link
Bruno Fazoli (856) | answered Jun 23 '15, 12:57 p.m.

Could you share the code fixed?

thank you

Your answer

Register or 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.