cfcFlexplorer 0.1 Released

Posted By : todd sharp Posted At : November 6, 2006 5:25 AM Posted In: Flex, cfcFlexplorer

38

I'm very happy to announce the release of my latest project, cfcFlexplorer. This project was inspired by Ray Camden's friday puzzler from September in which he proposed that someone take on the challenge of creating a cfc tester. cfcFlexplorer is a Flex based tool which does that, and a little more.

With cfcFlexplorer you simply modify an xml file which contains two variables: the server root directory and the directory from which to begin crawling for CFCs. Once the application recurses the directories, it returns all CFCs (except application.cfc's and anything under cfide) into a navigation tree. From there you can navigate through the tree, selecting any component that you would like to see further information on. When a component is selected, the 'methods' grid is populated with all of the methods within that component. When a method is selected, all of the associated parameters for that method are populated into the 'parameters' grid. The parameters grid contains an addional editable column called 'value' which allows you to populate test values and invoke the component. When invoked, the application opens a new window which will dump the results of the call (if applicable). If your component has an init constructor, a checkbox is automatically populated and the init() function is called prior to invoking your component so that any necessary instance data is available to your call. (Note: If your constructor requires parameters, populate those in the param grid prior to calling your function). You can either download cfcFlexplorer below, or check it out at RIAForge. There are definitely some enhancements/changes I'd like to make in the future, but I really wanted to get this out there since I think it's a tool that many will find helpful. Currently cfcFlexplorer does not handle passing complex objects (structs, arrays, queries, etc) as parameters so if your method requires these you will not be able to test them. If anyone would like to help out with the project, drop me a line and let me know. I plan on doing a more detailed write up later this week summarizing my first experiences with Flex. Overall, the project took me about 12 hours so far. That may sound a little high for a simple project, but I did get tripped up here and there a bit on the syntax, etc with Flex. I honestly do feel incredibly comfortable with the MXML and AS3 so far. Perhaps a year of hacking Flash Forms to bits taught me more than I thought it did! View cfcFlexplorer Demo

Comments (38)

Ryan Everhart's Gravatar Let me be the first to say... wow! I'm trying it right now!

Ryan

fro's Gravatar Looks pretty cool. Going to test it out now.

Pete Freitag's Gravatar Awesome! Great Job Todd.

Russ Johnson's Gravatar Nice work! One thing you may want to be aware of though, it seems harmless but you have a method in one of your test components in the demo that allows people to get dumps of your hard-drive contents... Its just dumps so noone could really do anything with it but I thought it was funny that you have a billybob folder in your images directory ;o)

todd sharp's Gravatar Russ: I'm on a shared server, so you're likely seeing someone else's billybob folder!

Obviously, the tool is probably best kept on a test server to avoid exposing your methods to the public!

todd sharp's Gravatar Nevermind, I see what you're seeing....Hey, you gotta have some fun sometimes, right?

Andrew's Gravatar Very impressive. I have a lot of CFCs on my company's website and this will help me test them before they're deployed. Thanks!!

Raymond Camden's Gravatar Nice work Todd. I've posted some pings to your RIAForge forums. (And yes - I need to get it working such that when someone posts to your conference, you get emails.)

Tariq CFLEX Ahmed's Gravatar I'm flaberghasted!!!!

Russ Johnson's Gravatar Todd,

Your right! You do have to have fun sometime!! I think its definately a cool application, you've inspired me to finally take the leap into Flex 2 and put a flex interface on one of the apps that Im currently working on.

Great Job!!

Claude's Gravatar Nice job!

When are you planning on populating the SVN repo? It's empty!

todd sharp's Gravatar Hopefully within the next few days Claude. Ray, will the RIAForge SVN browser allow for uploads? To be honest, I've never used SVN before.... :(

Andrew's Gravatar Can anyone help me out. I'm getting the following error when I tried to run the app:
SecurityError: Error #2148: SWF file file:///C|/Inetpub/wwwroot/afmetrics/cfcFlexplorer/Flex/bin/cfcFlexplorer.swf cannot access local resource file:///C|/Inetpub/wwwroot/afmetrics/cfcFlexplorer/Flex/bin/settings.xml. Only local-with-filesystem and trusted local SWF files may access local resources.
   at flash.net::URLStream/load()
   at flash.net::URLLoader/load()
   at flash.net::URLLoader$iinit()
   at cfcFlexplorer/::initApp()
   at cfcFlexplorer/___Application1_creationComplete()
   at flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
   at flash.events::EventDispatcher/dispatchEvent()
   at mx.core::UIComponent/set initialized()
   at mx.managers::LayoutManager/::doPhasedInstantiation()
   at Function/http://adobe.com/AS3/2006/builtin::apply()
   at mx.core::UIComponent/::callLaterDispatcher2()
   at mx.core::UIComponent/::callLaterDispatcher()

I'm running the app locally and have access to all resources. Thanks.

todd sharp's Gravatar I'm not sure if this will fix it Andrew, but the application is designed to run at your root directory. Otherwise you'd have to change the mxml and as files to point to the correct cfc folders. That doesn't sound like your problem though, are you running cf 7.0.2 with the Flex extensions?

todd sharp's Gravatar Also Andrew, make sure you edit the settings.xml under bin - not the one under flex. A few glitches that I forgot to mention ;)

I plan on cleaning up the zip when I get a chance to better organize it and get rid of the redundant files.

Andrew's Gravatar Todd. Thanks for your assistance. I am running ColdFusion 7.0.2 with flex extensions. Do I extract the zip folder to c:\CFusionmx7\wwroot or c:\inetpub\wwroot?

Critter's Gravatar I get this as an error when I run it...

Location: C:\inetpub\wwwroot\cfcflexplorer\

Error:
faultCode:Client.Error.MessageSend
faultString:'Send failed'
faultDetail:'Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed'

Andrew's Gravatar When I load the app, I get a busy cursor that never goes away, and no results come back. I have it in the webroot of one of my sites. We use a folder outside of the webroot for the cfcs. How should my settings file look? Let's say the path to the site's web root from the server is E:\cfwebroot\foo and that the path the cfc folder from the server's perspective is E:\cfwebroot\foo_cfc. Can this be done? Are there certain items that must exist in the CFC for it to be recognized?

Tariq CFLEX Ahmed's Gravatar It takes awhile for it to analyze your directory structure. Eg our code base is 160 000 lines of code, so it took a good 10mins.

Todd, I was about to start making enhancements to it - want to collaborate? Wouldn't want to do something that you're already working on.

I think the first thing to do is:
- Have a script which generates an XML file that contains the cfc tree and details; as opposed to trying to analyze it real time, that would speed things up dramatically.
- Allow for multiple roots. E.g
Root1 CFCs
Root 2 CFCs
Etc...

This tool has huge potential!

todd sharp's Gravatar Tariq: Absolutely. I plan on checking the project into SVN - I'll try to do that tonight. I really need to clean up the project (IE, many of the Flex project files really shouldn't be there, just the mxml and as files really are the only necessary ones - you can always create a project locally and compile). I've made a few updates locally over the last few nights, so I'll get a copy of the most recent up in SVN. I'll email you tonight and make sure you have the latest. I agree there is great potential and would really appreciate the collaboration. I think I've just scratched the surface on what could be done.

estetik's Gravatar at the moment, my program has it, and one other panel, inside a window. it is position so that it overlaps the corner of the other panel. the BackColor property is set to transparent, and its Border to FixedSingle. i can see though it perfectly over the window (which has a tiled BackGroundImage), but i can’t see the other panel through the part that it overlaps. i can only see the window (its parent) through it.

how can i create transparent/semi-transparent control that can overlap more than other control?

efesearch's Gravatar You do have to have fun sometime!! I think its definately a cool application, you've inspired me to finally take the leap into Flex 2 and put a flex interface on one of the apps that Im currently working on.

Thanks

Rüya Tabirleri's Gravatar Very impressive.Thanks!!

Plus Tc's Gravatar Good work.Good blog.Thanks man..

Banka Şubeleri's Gravatar Great Tutorial

great Job

Thanx!!!

Bankalar's Gravatar That doesn't sound like your problem though, are you running cf 7.0.2 with the Flex extensions?

Antalya's Gravatar I'll email you tonight and make sure you have the latest.

I agree there is great potential and would really appreciate the collaboration.

Disney Pictures's Gravatar stupid tihng

Football Caricatures's Gravatar great

cappadocia balloon's Gravatar thanks

Celebrity wallpapers's Gravatar anyway

Seo Danışmanı's Gravatar right

Disney dining plan's Gravatar going on

Cappadocia's Gravatar lol

estetik's Gravatar I think its definately a cool application, you've inspired me to finally take the leap into Flex 2 and put a flex interface on one of the apps that Im currently working on.

Estetik's Gravatar My only real problem with google analytics is that it doesn’t work very well with a lot of ASP pages, which a lot of clients use nowadays. It can also get kind of hairy when trying to get it to understand what a conversion is. Instead of just any click, it needs to be one specific click haha.

Estetik's Gravatar thanks for you.

iş makinaları's Gravatar this information most important for me.
thanks...