Well the type wouldn't technically be of the same type as your object, so it's logically wrong. In a system that let you actually throw exception objects, your exception would need to extend or implement a base exception class, which your object would not. The exception type would be DataManagerException or some other such construct.
Roland -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Bryant Sent: Tuesday, May 24, 2005 3:54 PM To: [email protected] Subject: [CFCDev] Throwing Errors From CFCs Probably a bad idea, but I can't figure out why: I was thinking of using a type equal to the name of my component for any error thrown by my component. For example, any error thrown by my DataMgr component would have <cfthrow type="DataMgr"...> I would still need to document the possible values of errorcode, of course, but this seems like it could help my try/catch blocks. (Incidentally, any good information on how to document error codes for CFCs would be great as well). What possible issues could this cause? Thanks, Steve Bryant. Bryant Web Consulting LLC http://www.BryantWebConsulting.com/ http://steve.coldfusionjournal.com/ ---------------------------------------------------------- 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]
