Re: check for a base64 encoded string

2011-04-22 Thread Raymond Camden
Dave Watts [mailto:dwa...@figleaf.com] > Sent: April-22-11 9:37 AM > To: cf-talk > Subject: Re: check for a base64 encoded string > > >> Reason being that throwing exceptions are expensive and also an ugly >> way of programming an evaluation. IMHO.. > > Throwing

Re: check for a base64 encoded string

2011-04-22 Thread John M Bliss
age- > From: Dave Watts [mailto:dwa...@figleaf.com] > Sent: April-22-11 9:37 AM > To: cf-talk > Subject: Re: check for a base64 encoded string > > > > Reason being that throwing exceptions are expensive and also an ugly > > way of programming an evaluation. IMHO.. > &

RE: check for a base64 encoded string

2011-04-22 Thread Brook Davies
: Re: check for a base64 encoded string > Reason being that throwing exceptions are expensive and also an ugly > way of programming an evaluation. IMHO.. Throwing exceptions isn't especially expensive, compared to whatever conditional logic they might otherwise replace. The ugliness th

Re: check for a base64 encoded string

2011-04-22 Thread John M Bliss
Right...and, if you make it into a function, the aesthetic problem gets "hidden" and your code reads: isbase64() On Fri, Apr 22, 2011 at 11:36 AM, Dave Watts wrote: > > > Reason being that throwing exceptions are expensive and also an ugly way > of > > programming an evaluation. IMHO.. > > Th

Re: check for a base64 encoded string

2011-04-22 Thread Dave Watts
> Reason being that throwing exceptions are expensive and also an ugly way of > programming an evaluation. IMHO.. Throwing exceptions isn't especially expensive, compared to whatever conditional logic they might otherwise replace. The ugliness thing is more a matter of the eye of the beholder, bu

RE: check for a base64 encoded string

2011-04-22 Thread Brook Davies
8:19 AM To: cf-talk Subject: Re: check for a base64 encoded string Why not just make the "attempting toBinary() in a try/catch" logic into a function? http://help.adobe.com/en_US/ColdFusion/9.0/Developing/WSc3ff6d0ea77859461172 e0811cbec22c24-7ff3.html On Fri, Apr 22, 2011 at 9:25 AM,

Re: check for a base64 encoded string

2011-04-22 Thread John M Bliss
Why not just make the "attempting toBinary() in a try/catch" logic into a function? http://help.adobe.com/en_US/ColdFusion/9.0/Developing/WSc3ff6d0ea77859461172e0811cbec22c24-7ff3.html On Fri, Apr 22, 2011 at 9:25 AM, Brook Davies wrote: > > Short of attempting toBinary() in a try/catch, does a