I like to keep my entities clean.  Just get/set/toString/equals/hashcode.  So 
I'd put the @Factory on a method in your controller/action/manager Bean.  If 
you need some heavyweight resources that you'd like to clean up, you can use 
the manager pattern and the @Unwrap annotation.  In the case of the manager 
pattern you have an additional bean dedicated to managing this contextual 
variable.

For the most part though, if I'm simply going to initialize a variable that 
I'll use later within a controller's action method, putting the @Factory on a 
method within the controller is the way I go.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4039403#4039403

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4039403
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to