Persisting Data to a Database

With the file system-backed data persistence of the Artisan Application under our belt, it's time to turn our attention to their equivalents on the Central Office side of the system. We'll be reusing the BaseDataObject ABC that was defined previously to ensure that all data object functionality can be called in the same way (for example, using the get method to read the data and save to write it, for example), but because the underlying data storage process is significantly different in its implementation, that is where most of the similarities will end. We'll still have to decide which of the database options we're going to use, as well.

This chapter will cover the following topics:

  • Analyzing database options in depth and selecting a database engine for data object persistence
  • Defining a data access strategy for the code that's expected to run at the Central Office
  • Designing and implementing some supporting classes for the data access and persistence that are required
  • Implementing the concrete data objects required at the Central Office:
    • Artisan
    • Product

There are also some data access considerations that will postpone at least some of the concrete implementations, and those will be discussed in detail.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.140.249.104