views:

37

answers:

1

Hi I am using Spring Roo to create a service to access the data base, just that. so, when I try to export to a jar using eclipse, the jar not contain one java class, but these files:
Contact.class
Contact_Roo_Configurable.class
Contact_Roo_Entity.class
Contact_Roo_ToString.class
Contact_Roo_JavaBean.class
I know these was AspectJ files but why are not compiled into one file.

A: 

Roo uses AspectJ behind the scenes to manage all of the glue that are not part of the business logic. Inside of Eclipse, these files exist, but are hidden. The fact that these files are separate (and that they produce separate class files) should have no real affect on the operation of your program.

However, if you do want to get rid of these files, you can do a push in refactoring to remove all of the roo artifacts. Just note that this is a one way transformation. Once pushed-in, it is not possible for roo to manage your project any more.

Andrew Eisenberg
I want to continue using Spring Roo. Is there no other way to do?
TulioPa
No. You can't have both. Roo requires these files to do its code generation. If you push them into the java file, Roo has no more context to work with.
Andrew Eisenberg