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 154381 - uncompilable code generated for lifecycle methods
Summary: uncompilable code generated for lifecycle methods
Status: CLOSED FIXED
Alias: None
Product: webservices
Classification: Unclassified
Component: REST (show other bugs)
Version: 6.x
Hardware: All Windows Vista
: P3 blocker (vote)
Assignee: Denis Anisimov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-12-02 16:59 UTC by Lukas Jungmann
Modified: 2010-11-02 12:09 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
sample project (58.94 KB, application/octet-stream)
2008-12-02 17:00 UTC, Lukas Jungmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lukas Jungmann 2008-12-02 16:59:50 UTC
see Customer* in attached project

for:
    @PostPersist
    public void postCreate (){
        System.out.println("Customer::postCreate:");
    }
    
    @PostRemove
    public void ejbRemove() {
        System.out.println("Customer::postRemove");
    }

we generate uncompilable:
    @XmlElement
    public void getPostCreate() {
        return (expandLevel > 0) ? entity.getPostCreate() : null;
    }

    @XmlElement
    public void getEjbRemove() {
        return (expandLevel > 0) ? entity.getEjbRemove() : null;
    }
Comment 1 Lukas Jungmann 2008-12-02 17:00:25 UTC
Created attachment 74435 [details]
sample project
Comment 2 Denis Anisimov 2010-10-05 13:33:06 UTC
There is one additional problem with generated CustomerConverter class.
It doesn't have import for Address entity.
It has Subscription import . Probably import addition for Subscription entity 
somehow overrides import for Address entity.
This issue should be fixed also.
Comment 3 Denis Anisimov 2010-10-06 08:00:40 UTC
changeset:   178801:649b6f16123e
user:        Denis Anisimov <ads@netbeans.org>
date:        Wed Oct 06 11:58:09 2010 +0400
summary:     Fix for BZ#154381 -  uncompilable code generated for lifecycle methods
Comment 4 Quality Engineering 2010-10-07 03:15:47 UTC
Integrated into 'main-golden', will be available in build *201010070000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/649b6f16123e
User: Denis Anisimov <ads@netbeans.org>
Log: Fix for BZ#154381 -  uncompilable code generated for lifecycle methods
Comment 5 Lukas Jungmann 2010-11-02 12:09:49 UTC
v. in 5e6add243b4b