• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

design question in JSF framework

 
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a page that displays a table with dynamic number of columns. I am using Tomahawk's datatable for this. I bound the table to a backing bean property so I can capture the rows and do some validations across columns for each row. The validation also involves some business logic. Is it okay to have some business logic in a backing bean? I had no other option since the datatable and the rows can be captured only there. For example, I have to check if each row is a valid combination or not.
I would like to get experts' advice on the general design issues and guidelines while using JSF framework.
Also I am interested to know if the 'Complete Reference' book covers topics like these.

Thanks in advance.
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If the data is captured in the backing bean, I see no reason you can't pass that information to some business classes. With that being said, I don't think having a minimal amount of business logic, so long as it pertains to building the view correctly, in the backing bean is a problem. It helps though to think of the backing bean as the controller in the MVC pattern. So it should more or less direct traffic and hand off business logic to helper classes when possible. My opinion anyway.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic