Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 369931 - [Texo] ORM Annotation -> Basic -> Enumerated : wrong JPA generation result
Summary: [Texo] ORM Annotation -> Basic -> Enumerated : wrong JPA generation result
Status: RESOLVED FIXED
Alias: None
Product: EMFT
Classification: Modeling
Component: Texo (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Martin Taal CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-27 09:54 EST by Benoit Cantin CLA
Modified: 2012-01-30 06:40 EST (History)
0 users

See Also:


Attachments
Use case (17.69 KB, application/zip)
2012-01-27 09:56 EST, Benoit Cantin CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benoit Cantin CLA 2012-01-27 09:54:56 EST
Build Identifier: Version: 3.7.0 Build id: I20110613-1736

The use case is the following. In my .ecore, I have created an EEnum called YY, and an EClass called XX, having an EAttribute ZZ of type YY.

My purpose is to generate the JPA annotated model code so that the attribute ZZ in class XX is annotated @Enumerated(EnumType.STRING).

To do that I have created a .annotationsmodel with an Annotated EClass XX, with inside an Annotated EAttribute ZZ and inside a child Basic. In this 'Basic', I set the property Enumerated to String.

The code generated is almost correct :
@Enumerated(EnumeratedType.STRING)

Except that EnumeratedType does not exists in the JPA 2 spec. It should be instead EnumType.

My Texo version is 0.1.0.v201112171308

Reproducible: Always
Comment 1 Benoit Cantin CLA 2012-01-27 09:56:04 EST
Created attachment 210186 [details]
Use case
Comment 2 Benoit Cantin CLA 2012-01-27 09:58:32 EST
Comment on attachment 210186 [details]
Use case

Attachement where (compared to the bug description) :
YY is FormulaType
XX is Formula
ZZ is Formula.formulaType
Comment 3 Martin Taal CLA 2012-01-30 04:36:40 EST
Fix committed to git, will be in next build.
Comment 4 Martin Taal CLA 2012-01-30 06:40:18 EST
Build is done and published