11.3. Associations between entities

Although it is quite clear than entity EJBs will have persistent data elements—the Customer EJB has persistent name, address, and credit card details, for example— closer inspection reveals that it is not only the data that is persistent. The problem is that entity EJBs have associations with other entity EJBs, and these associations will themselves be persistent.

In this section, we discuss associations in general, followed by typical schemes for implementing them.

11.3.1. What are associations?

The real power of object-oriented development comes from the expressiveness of object interactions. Objects can be associated [5] (related) in a number of ways and interact along those associations. Of course, a ...

Get Applied Enterprise JavaBeans™ Technology now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.