the problem is that you need a solution that works for all data types, not just dates - so you wind up with a NullDate.cfc, NullString.cfc, etc. If you want nullifyable objects, then Kerry's proposed setNull() method looks like the way to go (IMHO)
/t >-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED] On Behalf Of Patrick McElhaney >Sent: Wednesday, September 21, 2005 5:51 PM >To: [email protected] >Subject: Re: [CFCDev] Default for Dates in a Transfer object > >Maybe you could have two different objects: a value object and a null >object. For example, you could have a Date object that always has a >value, and a NullDate that extends Date and doesn't have a value. > >- You don't skip the init method. (Bill's concern.) > >- An object can't simultaneously have a value and represent null. >(Tanguy's concern.) > >- The object can be immutable. (My concern.) > >How does that sound? > >Patrick > >-- >Patrick McElhaney >704.560.9117 >http://pmcelhaney.weblogs.us > > >---------------------------------------------------------- >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). > >CFCDev is supported by New Atlanta, makers of BlueDragon >http://www.newatlanta.com/products/bluedragon/index.cfm > >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). CFCDev is supported by New Atlanta, makers of BlueDragon http://www.newatlanta.com/products/bluedragon/index.cfm An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
