<< A Groovy AST Viewer | Home | Groovy in GroovyEclipse >>

Groovy is NOT a scripting language

I just finished reading this article and related responses: Groovy or stuck in the groove?
It seems that people still don't get it: Groovy is not a scripting language. It is a first class replacement for Java when its features make it the appropriate language for the job.

Here is a little challenge:
class AProperClass {
void showMessage() { println "Don't call me scripting!" }
}
I compile this to a class file using groovyc or I just let the GroovyEclipse builder do it. And now I place the class in a Jar.

That is it, I simply add it to my Eclipse project library path (and of course, the Groovy runtime jar too), and use it in some Java code:
AProperClass instance = new AProperClass();
instance.showMessage();
So what is the challenge? Someone, anyone, create a jar that I can drop into Eclipse and use as above. Do it using either BeanShell, Scala, Kawa, Rhino, Jython, JRuby. And of course, no tricks allowed (e.g. funny Jython comments). Hmm, what about the Nice language? I haven't checked on that one.

I looked far and wide for an alternative to Java. So far I only found that alternative in Groovy. Please correct me if wrong - more tools, more fun.

And as far as Groovy losing its groove? There are days I think about the subscribers to the lists for some of the above listed languages and think how lucky they are not to be confronted with 50-100 daily messages that are divided over the Groovy and Grails lists.


Re: Groovy is NOT a scripting language

I have been calling Groovy a Very High Level Language (VHLL). Would you consider this an appropriate way to categorize it?

Re: Groovy is NOT a scripting language

You can use your groovy-code without compilation.
The groovy classloader will load *.groovy file and compile it in-memory (like any scripting language processor ).
It`s like Python: you can run *.py script or you can compile it into *.pyc object.

Add a comment Send a TrackBack