Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 334168

Summary: Don't specify Entity name when same as default
Product: [WebTools] Dali JPA Tools Reporter: Shaun Smith <shaun.smith>
Component: Diagram EditorAssignee: Petya Sabeva <petya.sabeva>
Status: VERIFIED FIXED QA Contact: Stefan Dimov <stefan.dimov>
Severity: minor    
Priority: P3 CC: jolene.moffitt
Version: 0.5   
Target Milestone: 3.0 M6   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
patch stefan.dimov: iplog+

Description Shaun Smith CLA 2011-01-12 16:43:10 EST
In the JPA Diagram Editor, changing the default name of an Entity created in the editor results in the refactoring of the class and addition of a name property on the @Entity annotation that matches the default which is the class short name.  E.g.,

@Entity(name = "Foo")
public class Foo {

Mapping values should only be specified when they are non-default unless explicitly set by the user.
Comment 1 Petya Sabeva CLA 2011-01-26 07:51:46 EST
Created attachment 187631 [details]
patch
Comment 2 Stefan Dimov CLA 2011-01-26 09:27:54 EST
Patch committed ...
Comment 3 Stefan Dimov CLA 2011-02-08 10:18:36 EST
The fix was submitted in the timeframe of M5, but the JPA Diagram Editor wasn't integrated in PDE build of WTP before the M5 release date, so I'm retargeting this bug to M6.
Comment 4 Jolene Moffitt CLA 2011-04-19 20:24:42 EDT
Verified in Build I-3.3.0-20110414085808

Verified when you rename the entity that after refactor the entity name and public class names are not both created.  See the link to view test steps
for verification. http://wiki.eclipse.org/Dali_3.0_M6