Skip to main content Accessibility help
×
Hostname: page-component-cd9895bd7-jn8rn Total loading time: 0 Render date: 2024-12-22T20:50:47.602Z Has data issue: false hasContentIssue false

Chapter 10 - Making Your Objects Persistent—Object-Orientation and Databases

from Part III - OBJECT-ORIENTED CONSTRUCTION

Published online by Cambridge University Press:  07 September 2010

Scott W. Ambler
Affiliation:
AmbySoft Inc., Toronto
Get access

Summary

What We'll Learn in This Chapter

Why your persistence strategy is important for successful application development.

What terminology is commonly used with respect to persistence.

How to map objects to flat files.

How to map objects to relational databases, concentrating on several critical topics: the impedance mismatch; mapping objects to tables; implementing object relationships; inheritance mapping strategies; and mapping success factors.

How to use object-oriented databases and object/relational databases as your persistence mechanism.

Persistence deals with the issue of how one ensures that the objects that he or she works with last, or persist, between invocations of object-oriented applications. In other words, persistence addresses one's strategy for saving objects to permanent storage. There are four common mechanisms used to store objects: flat files, relational databases, object-oriented databases, and object/relational databases. Although you may have heard that mapping objects into a relational database is a nightmare, and it can be if you make a mistake, we'll see in this chapter that using relational databases to store your objects is a very viable approach to persistence.

The vast majority of business objects must be persistent, or in other words they need to be saved to permanent storage so that you can work with them in the future. Fortunately or unfortunately depending on your point of view, we have several mechanisms that we can use to make our objects persistent: flat files, relational databases, object-oriented databases, and object/relational databases. We will cover each of these mechanisms in detail, discussing the issues for how to use them to make your objects persistent.

Type
Chapter
Information
Building Object Applications that Work
Your Step-by-Step Handbook for Developing Robust Systems with Object Technology
, pp. 291 - 342
Publisher: Cambridge University Press
Print publication year: 1997

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Save book to Kindle

To save this book to your Kindle, first ensure [email protected] is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

Available formats
×