I personally separate the logic of processing from the bean itself. To me,
the methods for processing should not be in the bean class itself. I think
having methods for processing in a bean violates the definition of bean.
But I digress.  I use the following structure:
com.Xcomp.projX.beans.FooBean           <-- the FooBean for projX
com.Xcomp.projX.handlers.FooHandler     <-- methods using FooBean of projX

Of course the getter/setter methods still exist in FooBean, otherwise it's
not a bean, right :)

---------
Eric Kelm
Developer, VSG Worldwide LLC


->-----Original Message-----
->From: David Haynes [mailto:[EMAIL PROTECTED]
->Sent: Wednesday, August 10, 2005 10:41 AM
->To: [email protected]
->Subject: Recommended directory layout?
->
->In poking around with various JSF tutorials/articles, I have seen a
->number of different directory layouts used to contain the backing beans,
->controllers, etc. Is there a 'best practices' consensus for a layout?
->
->I have seen the controllers separated from the backing beans with each
->in its own directory (i.e. for bean 'foo', there is a fooBean.java in
->directory model, and a fooController.java in directory controller) and
->backing beans and controllers together under a bean directory. (i.e. in
->directory foo, there will be fooBean.java and fooController.java). I
->have also seen everything smooshed together but I am not a fan of this
->approach.
->
->Ideas/Suggestions? Did I miss any documentation already discussing this?
->
->Thanks!
->-david-
->
->


Reply via email to