File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSF and the fly likes Still need Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Still need "glue" to connect JSF and Entities ?" Watch "Still need "glue" to connect JSF and Entities ?" New topic

Still need "glue" to connect JSF and Entities ?

paul docker

Joined: Feb 23, 2011
Posts: 1
Dear all Java EE users,
in the last few years I have been using JBoss Seam to avoid writing boilerplate code, for example if I need to save some form data I'd prefer
referencing directly the Entity objects, instead of writing Managed Beans, just to transport the form data.

I'd like to know if it's possible with Java EE 6 to perform the same thing, and thus use a portable approach.

Thanks a lot
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 17410

Welcome to the JavaRanch, Paul!

I never have gotten as deeply into Seam as I should, but the main reason why you shouldn't bind Domain Model objects directly as JSF backing beans is that it's too inflexible. If you're only going to use the entity as a single, immutable reference, it works, but when you start talking updating - or worse yet, switching the backing bean to a different instance of the same entity - things start going downhill in a hurry.

J2EE is not really designed for cheap monolithic development. That's what ASP and PHP are for. J2EE works better when you have a large, complex design and you want to implement it in small, easily manageable pieces. Lots and lots of pieces, sometimes, but the important part is that they're all relatively simple, so when you dump them on the next trainee, he/she won't have to spend a week figuring out what all the ramifications are.

An IDE is no substitute for an Intelligent Developer.
I agree. Here's the link:
subject: Still need "glue" to connect JSF and Entities ?
It's not a secret anymore!