Design architecture problem. -- Java Beans / Controllers

C

chrismiles

At the moment my system is split into the usual 3 layers -
presentation, business and data.

Presentation layer is composed of JSP and Servlets. My business layer
is session beans, and my data layer is entity beans.

Now take this scenario for example.

I have my servlet which invokes getAccount(accountId) on my session
bean, which in return locates a Account session bean.

It has been advised to me previously that is bad practise to let your
client (my presentation layer) get direct access to the entity beans.

Now how can I pass my information back to the presentation layer
without actually passing a entity bean? Am I best getting all the
information from the entity bean within my session bean and then
encapsulating in another standard class which I will then pass to the
presentation?

I know it is a design/arch issue but its really boiling me.

any help much apreciated. thanks in advance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top