> whether a CFC has already been instantiated?
I think Larry might be looking for something like...
//instanciate in variables scope... so
if(Not structKeyExists(variables, "myClass"))
variables.myClass = createObject("Component", "YourClassThatDoesX").init();
----- Original Message -----
From: "Jim Davis" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Tuesday, April 19, 2005 10:30 PM
Subject: RE: [CFCDev] Brain blockage - detecting whether a cfc is already
been instantiated
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf
> > Of Lyons, Larry
> > Sent: Tuesday, April 19, 2005 12:49 PM
> > To: '[email protected]'
> > Subject: [CFCDev] Brain blockage - detecting whether a cfc is already
been
> > instantiated
> >
> > Hi,
> >
> > I must be suffering from a brain block here, but is there any way to
tell
> > whether a CFC has already been instantiated?
>
> Do you mean that the "init()" method is run?
>
> I extend a root CFC with all my CFCs - it sets a variable called "DPInit"
to
> "false" in the pseudo constructor and then, in the real constructor I set
> this to "true". Of course the extended components must call the
super.init
> as well.
>
> I can then do "cfif instance.DPInit" anyplace I want to to determine if
the
> init() method has run.
>
> Jim Davis
>
>
>
>
>
> ----------------------------------------------------------
> 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]