Skip to end of metadata
Go to start of metadata

There are a number of ways to mix Groovy and Clojure. You can access Clojure classes from Groovy and vice versa by pre-compiling.

You can access via Java 6's scripting API: JSR-223 access to other JVM languages

You can also get access to Clojure's classes from Groovy, e.g. (for Groovy 1.7 snapshot):

Or interact via creating a new Process (again for Groovy 1.7 snapshot):

Another option is to use the Clojure API like this:

There is also a Clojure plugin for Grails which provides easy access to execute clojure code from any Grails artifact (controllers, taglibs, services etc...): http://grails.org/plugin/clojure
Not to be left behind Griffon also sports a clojure plugin, based on the Grails one: http://griffon.codehaus.org/Clojure+Plugin. Among it's features you'll find: script loading at runtime (like Grails), class generation using clojure's macros and a repl.

  • No labels