Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aspectj Problem #56

Closed
yiliuyan161 opened this issue Nov 23, 2011 · 4 comments
Closed

aspectj Problem #56

yiliuyan161 opened this issue Nov 23, 2011 · 4 comments

Comments

@yiliuyan161
Copy link

I use it in my project based on springroo, it can not generate the QXX.java files, because the Entity annotation was declared in .aj
files.

first I think was the maven phase's reason, I changed the phase to compile, test,even install,I'am sure the apt:process was
execute after the aspectj:compile

@aappddeevv
Copy link

I ran into this. google for GenericExporter querydsl to see the ticket that was opened as part of this issue. You can write a small program (script or java) to use GenericExporter to export your Q* classes. There is even (not sure which release) a way to set the output package, etc. So....you can make a sub-project in your project to build and run a small 4-5 line program to generate them. I did not find a way to use APT because of the source file separation, so a separate small program is needed.

@aappddeevv
Copy link

This is what I did. In 2.2.5 there are options for controlling the output path. You should have the "one" jar from querydsl as well as your project's jars on the classpath.

    public static void main(String[] args) {
        GenericExporter ge = new GenericExporter();
        ge.setTargetFolder(new File("src/main/java"));
        ge.setEntityAnnotation(Entity.class);
        Package p = YourDomainClass.class.getPackage();
        ge.export(p);
    }

@timowest
Copy link
Member

Yes, the related ticket is this one : #43

Did the output work?

@yiliuyan161
Copy link
Author

thank you , It works. very helpful. aappddeevv and timowest .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants