|
Hi, I’m building my first OO app and I have a question regarding inherited classes and how they correspond to DAO’s.
Here’s my situation:
I’m building a pageManager application that basically stores different types of “pages” of a course. Currently there are two types of pages: Lecture and Activity.
This is how they break down:
A generic page has pageID INT pageTitle string courseID INT pageLanguage INT pageDescription string pageType INT
a Lecture is a child of page with lectureID INT lectureNumber INT faculty(s) Array(1) of faculty objects
and Activity is a child of Page with activityID INT activityContent text
I’m really confused as to how to design DAO’s for this. I want to be able to have a pageManager cfc that takes a pageID as a field and returns either a lecture or activity object.
Do I build multiple DAO’s that corresponds to each different subclass (ie: a lectureDAO and an activityDAO)? Do I build one pageDAO that has in its CRUD logic that handles what databases to work with based on the class?
Boson Au Web Content Developer Center for Teaching and Learning with Technology Johns Hopkins University Bloomberg School of Health 410-223-1671
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com). An archive of the CFCDev list is available at www.mail-archive.com/[email protected] |
- [CFCDev] New to OO, question about inheritance an... Boson Au
- RE: [CFCDev] New to OO, question about inher... Nando
- RE: [CFCDev] New to OO, question about inher... Nando
- RE: [CFCDev] New to OO, question about i... Boson Au
- Re: [CFCDev] New to OO, question abo... Adrocknaphobia
- RE: [CFCDev] New to OO, question... Boson Au
- RE: [CFCDev] New to OO, question abo... Nando
- RE: [CFCDev] New to OO, question about inher... Billings, Brian J. (SMG)
