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.

Bug 78766

Summary: Source code is not updated after applying design pattern to class
Product: uml Reporter: bugbridge <bugbridge>
Component: Design CenterAssignee: Craig Conover <conover>
Status: VERIFIED FIXED    
Severity: blocker CC: sj-nb
Priority: P1    
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description bugbridge 2006-06-21 12:58:17 UTC
Steps to reproduce:
- Create Java class.
- Choose it in model tree ( or on diagram ).
- Apply to it some design pattern ( this class should be used as participant) .
As result - model element has right structure that was created in design pattern (
all methods and attributes declared in template ) , but source code was not changed.
//
Only hierarchy is propagated in source code ( implements , extends ).
--- 10/19/04 14:20 GMT
reproducible with coke060619
generate code do not correct source (may be a bug in generate code).
----: 2006-06-21 15:23:42
Comment 1 Trey Spiva 2006-10-05 21:04:29 UTC
This is fixed in a mannor of speaking, since we no longer support live round trip.  Now you will have to 
use the code generation action when you are ready to generate source code.
Comment 2 Sergey Petrov 2006-10-10 14:13:35 UTC
It's still valid in 061010 because Apply Design Pattern process has its own code
generation.
Comment 3 Trey Spiva 2006-10-10 18:14:22 UTC
Ok, we then need to dispable to autocode generation.
Comment 4 Craig Conover 2006-10-16 23:13:51 UTC
We have decided to disable this feature. When a Design Pattern is applied, there
will not be an option to Generate Code. So now just Generate Code for the newly
created elements from the applied DP.
Comment 5 Craig Conover 2006-10-16 23:32:06 UTC
The dialog to Generate Code after applying a design pattern is no longer displayed.
Comment 6 Sergey Petrov 2006-10-17 13:59:36 UTC
Now there is a Regression:
UML|Design Pattern|Design Pattern Catalog|Generate Code After Applying Pattern
option has no effect.
I think current fix is incomplete because generate code isn't removed from all
places but I can file separate issue on the option if it's more appropriate for you.
Comment 7 Craig Conover 2006-10-17 17:51:24 UTC
Are you saying that the remaining issue is that the global preference still
remains? If so, I can use this issue to track it.
Comment 8 Sergey Petrov 2006-10-17 21:16:47 UTC
yes, you got it.
I think global option(preference) should be removed at the same time as
functionality
we already have some obsolete preferences which wasn't removed at proper time
and seems will remains in options for a long time
Comment 9 Craig Conover 2006-10-17 21:22:53 UTC
Removed the preferences from the UML Options
Comment 10 Sergey Petrov 2006-10-18 13:18:30 UTC
verfied with 061018_27