I am looking at the following article by Rob Brooks-Bilson: http://www.oreillynet.com/pub/a/javascript/2003/09/24/coldfusion_tips.html
I know it is an old article, so it may not be up to date with "best practices." Anyways, I thought I had it down until I was introduced to the psuedo-constructor and instantiation. I thought I could just create arguements in my cfc's with the cfargument tag, and then pass the cfc's the arguments when invoking them. While that is an option, it seems to be the very basic of basic uses of CFC's and I am trying to leverage OOP development the best I can in ColdFusion. I still don't really understand when I should create a static component and when I should create an instance-based component. The CFWACK book is very vaque, and documentation is sparce. Now that you guys are clearifying how to pass an instance component arguments, I am begining to rethink my entire approach to writing methods and properties. I really hate learning the wrong way to do things first, and then learning how to do it right. Any help is very appreciated! -Aaron On 2/16/06, Alan Rother <[EMAIL PROTECTED]> wrote: > I'm sorry, are you asking if you should use the variables scope in the CFC > itself? > > If so, I don't recommend it. using variables. anything makes that variable > available to all of the other methods in the cfc and basically trashes the > thread safeness of the cfc, that is if you are using the cfc in a persistent > scope. If you are instantiating the cfc evertime you use it, then it's ok, > but under load it can really start to take a performance hit if you are > invoking on every hit to the page. > -- > Alan Rother > Macromedia Certified Advanced ColdFusion MX 7 Developer > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232657 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

