Community
Participate
Working Groups
Hi, Using the MoDisco Java Discoverer, I encountered a null pointer exception after deleting a field in the java model. To reproduce, simply create an "Hello World" java project, discover the source code with the MoDisco Java Discoverer. Once the MoDisco Model Browser is opened, delete a field in a method declaration for example. The field dissapears, according to the correct behaviour. Close the browser and try to open it again, you got the NullPointerException Once the exception is raised, it is impossible to open the javaxmi, even after discovering it again, which led to the same exception Regards
I cannot reproduce the error. Could you please attach a model on which it happens, and tell me exactly which steps lead to the error? A stacktrace could be helpful too.
Scratch that! I misunderstood you, I thought you meant the error happened when you deleted a FieldDeclaration. But it in fact happens when you delete an attribute.
What happened is that when you deleted an attribute in the model browser, it in fact deleted the EAttribute from the metamodel (in the EPackage.Registry). This of course causes problems (both this bug and bug 319016). I fixed it in revision 2667 by making sure elements from the EPackage.Registry cannot be deleted.
Bug fixed.