Skip to content

Instantly share code, notes, and snippets.

@ifedotov
Created February 26, 2011 01:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ifedotov/844819 to your computer and use it in GitHub Desktop.
Save ifedotov/844819 to your computer and use it in GitHub Desktop.
<cfscript>
paths = [];
loader = '';
//paths[1] is path to bin-groovy forlder where eclipse puts Groovy .class files
paths[1] = "C:\...\bin-groovy";
//this is where Groovy .jar files are, again you might have different paths
paths[2] = "C:\groovy\groovy-1.6-RC-2\lib\groovy-1.6-RC-2.jar";
paths[3] = "C:\groovy\groovy-1.6-RC-2\lib\asm-2.2.3.jar";
//create the loader
loader = createObject("component", "javaloader.JavaLoader").init(paths);
//intanciate your Groovy classes
instanceOfYourClass = loader.create("YourClass");
instanceOfYourClass.init();
</cfscript>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment