Figure 4:
Three classes for database access.