Search code examples
springroo

@RooJavaBean annotation - How to ignore service fields?


This is more an utility question, i just dont like messy code and it doesn't matter if it is in main file or associated onces.

Is there a way to tell ROO to ignore services @Autowired fields in file ? Roo seems to generate every field declared in my class. Assuming that im using it for keeping controllers clean from accesssor methods. I don't want to have to commit or run roo just to create accessor methods for my services.

Controllers are not Entities - transient shouldn't work ? Ideas ?


Solution

  • It seems that currently there is no simple solution to the problem. It was reported multiple times. Custom way can be creating own annotation to mark fields as "Do not generate accessors for me".