So, first, let me make it clear I got permission from MACR to state this. I wanted to get this out at the Birds of a Feather but I forgot to ask in time.
Two nice bugs related to CFCs are fixed in Blackstone:
-
Right now if you duplicate or WDDX a CFC, you get... something. What you get, however, is not really a CFC (or serialized CFC). This can definitely lead to confusion on the developer's part. In Blackstone, you now get an error when you duplicate/WDDX a CFC. While it would be nice if these functions actually worked, I'm very happy MACR made the functions throw an error. Also note that you can very easily add a duplicate/serialize/deserialize method to your CFCs.
-
There is a bug in CFMX 6.1 with CFCs and cfinclude. If you cfinclude your method code, all variables that were var scoped are copied to the Variables scope. Obviously this kinda sucks. Right now you can avoid this by not using cfinclude. If your method code is so long that it is hard to parse within the rest of the CFC, it may be time for refactoring. The good news, though , is that this is fixed in Blackstone.
Archived Comments
It's not looking good for Interfaces, is it :(
And ofcourse Macromedia will patch CFMX6.1 also .. at least that should be the case :)
Any word from your discussions with MACR if true serialization via WDDX or new function will make it to CFMX7?
I know Ben Forta stated publicly that this was "planned, but not guaranteed" functionality.
Alex, all I can say is what I said in the post. Anything else would be under NDA.
yes, Ben did publicly state that serializing CFCs is possibly in Blackstone - by that he meant that in a J2EE cluster the application server can serialize them in the session scope. No, I can't comment on whether it's actually in Blackstone or not. I also thought I'd mention that thought you can't WDDX a CFC, you can use a technique I wrote about in this month's CFDJ to serialize them. The technique is based on the Hash DTO design pattern. If you don't get CFDJ (what's wrong with you?) you can view that article online at http://www.sys-con.com/stor....