CNET has just published a new article that I wrote for them. This one is on using the State pattern with ColdFusion Components. I'm not sure how many folks keep up with TechRepublic or Builder.com so I thought I'd blog it and post a link in case anyone is interested in reading it:
http://articles.techrepublic.com.com/5100-3513_11-6167539.html
Feel free to comment at TechRepublic or post here and let me know what you think! Thanks.
Comments (6) |
del.icio.us
|
Digg It!
|
Linking Blogs
| 3233 Views


# Posted By Bruce | 3/15/07 4:13 PM
Thank you for publishing an excellent example of using the State pattern in CF. Your explanation and code were easy to follow. I just finished reading Head First’s book on Design Patterns, so it’s great to find CF examples of these patterns.
I hope you’ll do more articles like this one. I appreciate your work.
# Posted By Paul Marcotte | 3/17/07 9:33 PM
Hi Brian,
Another excellent article. One question. In listing E, for the method createStateNameMappings(), you create var local = structNew(), but do not refer to local again within the method. Can you explain why the local struct is created?
# Posted By Brian Kotek | 3/18/07 9:33 PM
Paul, nice catch. I actually use a CFEclipse snippet to generate the basic cffunction tag sets and that snippet also has the creation of the var-scoped local struct. I just forgot to remove it since that method doesn't actually need it.
# Posted By Paul Marcotte | 3/19/07 12:52 AM
Ahh, good. I was worried I was missing something...
# Posted By santshos | 4/9/07 11:02 AM
Hi, Brian!
Thank you for publishing an excellent example of using the State pattern in CF. Your explanation and code were easy to follow. I just finished reading Head First’s book on Design Patterns, so it’s great to find CF examples of these patterns.
# Posted By sanyo denki | 8/12/07 10:04 AM
Thank you for publishing an excellent example of using the State pattern in CF. Your explanation and code were easy to follow. I just finished reading Head First’s book on Design Patterns, so it’s great to find CF examples of these patterns.