This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Steps to reproduce: - Create a Java-Platform Model UML project - Add a package with scoped Class diagram - Put a Class element on the diagram and name It - Generate code for the UML project The source code is generated: ----------------------------------------------------------- Begin processing Generate Code: 1 items Code Generation selected options: Exporting sources to folder: C:/Documents and Settings/andromeda/test/re/05\UMLProject1SourceCode\src Processing element 1 of 1: Class pack::MyClass ================================ Task Successful (total time: 1 seconds) ----------------------------------------------------------- - Remove the Class element from the model - Generate code for the UML project 'Error' dialog appears: 'No elements found' The generated java class is not removed.
This is as designed. The Gen Code action does not proactively remove elements from the target source folder, it only regenerates existing sources and generates elements that don't have existing sources. This may be addressed for FCS.