O'Reilly logo

J2EE™ Applications and BEA™ WebLogic Server™ by Sandra L. Emerson, Rob Woollen, Michael Girdley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using Java Beans as Value Objects

Even when using the facade pattern, the EJB programmer must be careful to avoid exposing the entity beans directly to the client or Web tier. For example, a Web application displays a list of current orders for a given customer. The Web tier displays the information, and the EJB layer accesses the persistent store with an Order entity bean. With the facade pattern, the Web tier accesses a stateless session bean that finds the appropriate Order entity beans. The stateless session bean returns a Collection of Order entity objects to the Web tier. The Web tier can then call getXXX methods on the Order references and display the information to the user.

While this approach makes sense intuitively, it represents a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required