One of the most requested features in CFEclipse is to have insight into CFC’s to have method completion. I thought I would detail some of the problems that are involved in this task from an editor. I am putting this together so that when people ask me why not, I can point them to this, and of course, if they come up with some good answers, they can post them here!
1) What CFC are we calling?
The simplest way to call a CFC is to do the following:
</code>
In this case, and similar cases, it would be VERY hard to find out what myComp actually is! If the "APPLICATION.MyComponent" is set in Application.cfc for example or anywhere else (in the many different ways of setting an application variable, that I am not even going to go into here!) it would be impossible to find out what myComp is.
3) What is the returned object?
The above code is probably something you wont do a lot, but how about something like:
</code>
And the function is defined as:
</cffunction>
</code>
How would the editor know what the object, and thus what funtions it had, is? This is very much like what happens in ColdSpring so unless we write CFEclipse so it actually does everything a CF server does (and even then, that is dangerous at runtime!) it wont be able to know what is happening!
So, how would you get round these problems? (put aside that its in Eclipse, try writing a parser in CF that just reads text files and let me know how you get on!)
Tweet
comments powered by Disqus