|Save operation corrupts diagram file [message #991781]
||Thu, 20 December 2012 07:30
| sowmya Mising name
Registered: July 2009
I have a scenario in which if an element is added to the gmf editor then when that element is being added and written to the model , automatically some of its child elements also must get added to editor and written to model. For this I have created threads inside the command to create main element creation, to automatically create the child elements.
But my problem is if the user clicks on save before all the child elements are completely created , then the save operation interrupts the child creation thread and stops it. The model file is in corrupted state as some of the child elements are left partially created. The child creation thread is in synchronized block but still gets interrupted by save. I have been trying to prevent this by trying thread priority , interrupt exceptions and various other thread properties , but have not yet been able to do so.
Can anybody please suggest how to control this save thread. Any information in this context would also be really helpful
Powered by FUDForum
. Page generated in 0.08214 seconds