tags:

views:

17

answers:

1

i've added a plugin called Image tool plugin for image resizeing... but when i called an instance of it

def imageTool = new ImageTool()

it gives me compilation error cause it can't resolve ImageTool class . i've tried to put import import org.grails.plugins.imagetools.ImageTool

as a suggestion from a site .. but it didn't work .. so what is the real path to the imageTool so i can import it?? any help please:)

+1  A: 

You can't access a class from the default package in a class that's in a package, and ImageTool is in the default package. The easiest thing to do is move that class into a subfolder, e.g. src/imagetool and add "package imagetool" to the source. You'll need to do this for each developer.

The plugin has moved to http://github.com/ricardojmendez/grails-imagetools/ and this has been fixed in that code, but I don't know if they have done a new release.

Burt Beckwith
do you mean sir that i need to get the ImageTool.groovy from src/groovy/org/grails/plugin into my main project folder ??
Mohamed Emad Hegab
no, keep it in the plugin's src/groovy folder, just move it into a package and corresponding subfolder so you can import it
Burt Beckwith