No problem. Learn to Love the Factory Method Pattern http://www.clearsoftware.net/client/index.cfm?mode=entry&entry=89F69AD3-E081 -2BAC-695BECE0066A7203
-Boson [EMAIL PROTECTED] 410-223-1671 > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Billings, > Brian J. (SMG) > Sent: Thursday, November 03, 2005 3:39 PM > To: [email protected] > Subject: RE: [CFCDev] New to OO, question about inheritance and DAO's > > > Boson, > > Can you send a link to the article you are reading on Factory > Patterns? > > -Brian > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Boson Au > Sent: Thursday, November 03, 2005 11:37 AM > To: [email protected] > Subject: RE: [CFCDev] New to OO, question about inheritance and DAO's > > > > > I really shouldn't be offering any helpful advice to > > RockVegas hater but... > > > I'm sorry but the traffic in that area seriously gave me ulcers. > > > The only issue I see with what you are trying to achieve is > > that your pageManager / page factory must be aware of all all > > the page types. I'm thinking you may want to create your > > pageType and pass that to your pageManager. > > > > Like so: > > > > pageTypeObj = createObject('component', > > 'edu.jhsph.page.type.activity').init(pageID); > > > > pageObj = createObject('component', > > 'edu.jhsph.page.manager').init(pageTypeObj); > > > > I kind of see what you're getting at: basically have a factory object > that > takes a pageType and returns the appropriate object so I can > run init on > it. > > I am reading an article joe rinehart wrote about the factory > pattern and > it > looks like I should have separate DAO's made for these different > subclasses. > > > > It's more of a management perspective though. If Wendy wants > > to create a new page type all she has to do is create a new > > type component that meets a few standard criteria (must have > > certain methods, etc.). She doesn't have to edit the > > pageManager.cfc to update it with a new pageType. (Which may > > effect all courses that use that object). > > > > -Adam > > > > > > ---------------------------------------------------------- > > 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] > > > > > ---------------------------------------------------------- > 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] > > > > > ******* Confidentiality Notice ******* > This email, its electronic document attachments, and the > contents of its website linkages may contain confidential > health information. This information is intended solely for > use by the individual or entity to whom it is addressed. If > you have received this information in error, please notify > the sender immediately and arrange for the prompt destruction > of the material and any accompanying attachments. > > > > > > ---------------------------------------------------------- > 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] > ---------------------------------------------------------- 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]
