There are a number of projects to help you here.  If you want to use
Jena/ARQ to pull in Linked Data into a gralis app, I would recommend
GroovySparql.  if you want something comparable to DataSource/JdbcTemplate
style Spring programming, the Spring Jena provides Spring-aware beans for
working with Jena.

GroovySparql - abstracts out Jena/ARQ for idiomatic Groovy.  Grails plugin
in progress.
https://github.com/AlBaker/GroovySparql
Quick instructions:
http://linkedjava.blogspot.com/2013/02/groovysparql-06-released.html

Spring Jena - provides Spring managed beans (e.g. configure in
conf/resources.xml or conf/resources.groovy in Grails
https://github.com/AlBaker/SpringJena

I also did similar projects for the Stardog database, with Jena support:
Stardog-groovy:https://github.com/clarkparsia/stardog-groovy
Stardog-spring: https://github.com/clarkparsia/stardog-spring

Enjoy!

Al Baker




On Wed, Apr 3, 2013 at 9:01 PM, Shichao Dong <[email protected]> wrote:

> Hi James,
> Here is the link
>
> http://stackoverflow.com/questions/2090710/how-to-use-existing-java-class-from-grails
>
> I suppose you can put some APIs that you often used in the java class, and
> then use them in groovy.
>
> I hope it would be helpful.
>
> Cheers,
> Dom
>

Reply via email to