问题
I create sample application of gwtupload
. https://code.google.com/p/gwtupload/ Its working fine with the .jar
I downloaded from project home.
But for my custom requirement I downloaded project from git
https://github.com/manolo/gwtupload and made changes as per my requirement and created .jar
file. Then I imported it to my project and included in classpath. Even eclipse is not giving any error in editor mode. But when I debug and open URL its giving me following error.
[ERROR] [uploadtest] - Line 3: The import gwtupload cannot be resolved
[ERROR] [uploadtest] - Line 53: SingleUploader cannot be resolved to a type
[ERROR] [uploadtest] - Line 54: IUploader cannot be resolved to a type
Tried stackoverflow thread Eclipse error: "The import XXX cannot be resolved" but didn't help me out.
Do I need to create .jar
file with other parameters than creating .jar
using Export in eclipse?
回答1:
You should export the .jar with "Java source files and resources".
回答2:
Gwtupload is a maven project, so the easiest way to produce the .jar is just open a command-line session, change to the gwt-upload/core folder and run:
mvn clean package
来源:https://stackoverflow.com/questions/19064038/the-import-gwtupload-cannot-be-resolved