Cars Example

Real applications combine many of the concepts presented in this chapter. Our cars example demonstrates using a stateful and stateless session bean to model an automobile dealer and a prospective buyer. Of course, this example does not illustrate all of the required information and steps in purchasing a real car, but it does illustrate a typical design of a larger application.

The automobile dealer presents a purchasing service to the potential customer. Users need to be able to query the automobile dealer to look for cars in the dealer's stock that match their criteria. Then, the customer may make an offer on a particular car. If the dealer accepts the offer, the car is sold and removed from the dealer's stock.

Because the dealer ...

Get J2EE™ Applications and BEA™ WebLogic Server™ now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.