aspose file tools*
The moose likes JSF and the fly likes Generate or override getter method Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Generate or override getter method" Watch "Generate or override getter method" New topic
Author

Generate or override getter method

tehackio teha
Greenhorn

Joined: Dec 08, 2011
Posts: 3
I have many java classes for querying database. These classes are injected by CDI Weld on managed bean.
Is there any way(cdi, cglib, javassist...) which do not need write this method "get?AsMyObject" all time?
All classes looks like this below:



My web application uses: jboss7, seam 3.1;
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16228
    
  21

Welcome to the JavaRanch, Tehackio!

I have not studied Weld in detail, but in JSF, you normally would not be coding a lot of "get" method calls to set variables, because JSF is based on Inversion of Control and so JSF itself sets the variables (properties) by invoking the backing bean's "set" methods.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Generate or override getter method