|
|
Re: [Texo] No Dao class is generated for abstract class [message #869953 is a reply to message #869329] |
Sat, 05 May 2012 05:23 |
Martin Taal Messages: 5468 Registered: July 2009 |
Senior Member |
|
|
Hi Oliver,
I published a new build.
gr. Martin
On 05/03/2012 10:32 AM, Martin Taal wrote:
> Hi Oliver,
> Yes makes sense what you say. I changed it and am doing a new build. Will post here after I published it.
>
> gr. Martin
>
> On 05/03/2012 04:35 AM, Oliver Zhou wrote:
>> Hi Martin,
>>
>> Recently I noticed that dao class is not generated for abstract class.
>> I don't know why. To me, such dao classes should be generated because it is allowed to pass a abstract class to
>> EntityManager.find to get all the instances of one class hierarchy.
>>
>> What do you think?
>
>
--
With Regards, Martin Taal
Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@xxxxxxxx - mtaal@xxxxxxxx
Web: www.springsite.com - www.elver.org
|
|
|
|
Re: [Texo] No Dao class is generated for abstract class [message #870130 is a reply to message #869990] |
Sun, 06 May 2012 21:04 |
Martin Taal Messages: 5468 Registered: July 2009 |
Senior Member |
|
|
Hi Oliver,
Yes you are right, I am developing some other features so I don't have a working (local) build at the moment, but will
rebuild asap, will be a few days probably..
gr. Martin
On 05/05/2012 05:05 PM, Oliver Zhou wrote:
> Hi Martin,
>
> Thanks for fix, I tested the build, but it seems the problem still exists.
> I debugged into the code and I found maybe the following logic in ModelEClassAnnotator.setAnnotationFeatures causes the
> problem:
>
> if (!GenUtils.isDocumentRoot(eClass) && !eClass.isInterface() && !eClass.isAbstract() && !ModelUtils.isEMap(eClass)
> && GeneratorUtils.isEmptyOrNull(annotation.getDaoQualifiedClassName())) {
> final EPackageModelGenAnnotation ePackageModelGenAnnotation = getEPackageModelGenAnnotation(eClass.getEPackage());
> final String packagePath = ePackageModelGenAnnotation.getDaoClassesPackagePath();
> annotation.setDaoQualifiedClassName(packagePath + GenConstants.DOT + annotation.getSimpleClassName()
> + getDaoPatternName(ePackageModelGenAnnotation));
> } else {
> // prevent dao generation
> annotation.setDaoQualifiedClassName(null);
> }
>
> Could you verify it again?
--
With Regards, Martin Taal
Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@xxxxxxxx - mtaal@xxxxxxxx
Web: www.springsite.com - www.elver.org
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03776 seconds